Skip to content

Commit 6f3c807

Browse files
Merge pull request #28699 from vikram-redhat/master
restore netlify push
2 parents 70e56c3 + 64acc97 commit 6f3c807

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

scripts/push_to_netlify.sh

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -130,16 +130,15 @@ if [[ "$COMMENT_FOUND" = false ]]; then
130130
do
131131
#only do this for adoc files
132132
if [ "${i: -5}" == ".adoc" ] ; then
133-
#ignore adoc files which are modules or topics as final urls are for assemblies
133+
#ignore adoc files which are modules or topics
134134
if [[ ${i} != *"topic"* || ${i} != *"module"* ]] ; then
135135
FILE_NAME="${i::-5}"
136-
# this check is not strictly necessary for new content, and of course, needs to be versioned.
137-
# CHECK_DOCS_URL="https://docs.openshift.com/container-platform/3.9/$FILE_NAME.html"
138-
#if curl --output /dev/null --silent --head --fail "$CHECK_DOCS_URL"; then
139-
FINAL_URL="https://${PR_BRANCH}--ocpdocs.netlify.com/openshift-enterprise/latest/$FILE_NAME.html"
140-
#COMMENT_DATA2="- *$i*: ${COMMENT_DATA2}${FINAL_URL}\\n"
141-
echo "- *$i*: ${FINAL_URL}" >> comments.txt
142-
#fi
136+
CHECK_DOCS_URL="https://docs.openshift.com/container-platform/3.9/$FILE_NAME.html"
137+
if curl --output /dev/null --silent --head --fail "$CHECK_DOCS_URL"; then
138+
FINAL_URL="https://${PR_BRANCH}--ocpdocs.netlify.com/openshift-enterprise/latest/$FILE_NAME.html"
139+
#COMMENT_DATA2="- *$i*: ${COMMENT_DATA2}${FINAL_URL}\\n"
140+
echo "- *$i*: ${FINAL_URL}" >> comments.txt
141+
fi
143142
fi
144143
fi
145144
done

0 commit comments

Comments
 (0)