mirror of
https://github.com/openshift/openshift-docs.git
synced 2026-02-05 12:46:18 +01:00
fix script to run in alpine container
This commit is contained in:
committed by
openshift-cherrypick-robot
parent
2ee749ece8
commit
9d2f1c63af
@@ -17,7 +17,7 @@ check_updated_assemblies () {
|
||||
if [ "${MODULES}" ]
|
||||
then
|
||||
# $UPDATED_ASSEMBLIES is the list of assemblies that contains changed modules
|
||||
UPDATED_ASSEMBLIES=$(grep -rnwl "$REPO_PATH" --include=\*.adoc --exclude-dir={snippets,modules} -e "$MODULES")
|
||||
UPDATED_ASSEMBLIES=$(grep -rnwl "$REPO_PATH" --exclude-dir={snippets,modules} -e "$MODULES" -- "*.adoc")
|
||||
# Exit 0 if there are no modified assemblies
|
||||
if [[ -z "${UPDATED_ASSEMBLIES}" ]]
|
||||
then
|
||||
@@ -38,7 +38,7 @@ check_updated_assemblies () {
|
||||
# search for files only, not folders
|
||||
PAGE="File: $(basename "$ASSEMBLY" .adoc)"
|
||||
# don't validate the assembly if it is not in a topic map
|
||||
if grep -rq "$PAGE" --include "*.yml" _topic_maps ; then
|
||||
if grep -rq "$PAGE" _topic_maps/*.yml; then
|
||||
# validate the assembly
|
||||
echo "Validating $ASSEMBLY ... 🚨"
|
||||
RED='\033[0;31m'
|
||||
|
||||
@@ -15,7 +15,7 @@ MODULES=$(echo "$FILES" | awk '/modules\/(.*)\.adoc/')
|
||||
if [ "${MODULES}" ]
|
||||
then
|
||||
# $UPDATED_ASSEMBLIES is the list of assemblies that contains changed modules
|
||||
UPDATED_ASSEMBLIES=$(grep -rnwL "$REPO_PATH" --exclude-dir={snippets,modules} -e "$MODULES" -- "*.adoc")
|
||||
UPDATED_ASSEMBLIES=$(grep -rnwl "$REPO_PATH" --exclude-dir={snippets,modules} -e "$MODULES" -- "*.adoc")
|
||||
|
||||
# Exit 0 if there are no modified assemblies
|
||||
if [[ -z "${UPDATED_ASSEMBLIES}" ]]
|
||||
|
||||
Reference in New Issue
Block a user