Skip to content

Commit bd6f36a

Browse files
mikekgfbmalfet
authored andcommitted
code refactor of documentation CI for advanced.md (#780)
* code refactor * typos
1 parent 07053a8 commit bd6f36a

File tree

2 files changed

+20
-20
lines changed

2 files changed

+20
-20
lines changed

.ci/scripts/run-docs

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -55,13 +55,23 @@ if [ "$1" == "gguf" ]; then
5555
echo "*******************************************"
5656
bash -x ./run-gguf.sh
5757
echo "::endgroup::"
58-
<<<<<<< HEAD
5958
fi
6059

6160

6261
if [ "$1" == "advanced" ]; then
62+
echo "::group::Create script to run advanced"
63+
python3 scripts/updown.py --file docs/ADVANCED-USERS.md --replace 'llama3:stories15M,-l 3:-l 2,meta-llama/Meta-Llama-3-8B-Instruct:stories15M' --suppress huggingface-cli,HF_TOKEN > ./run-advanced.sh
64+
# for good measure, if something happened to updown processor,
65+
# and it did not error out, fail with an exit 1
66+
echo "exit 1" >> ./run-advanced.sh
67+
echo "::endgroup::"
68+
69+
echo "::group::Run advanced"
70+
echo "*******************************************"
71+
cat ./run-advanced.sh
72+
echo "*******************************************"
73+
bash -x ./run-advanced.sh
74+
echo "::endgroup::"
6375
echo "TBD"
6476
fi
65-
=======
66-
fi
67-
>>>>>>> e3db2486f80b71b3143945a44f58d50c02488c90
77+

.github/workflows/run-readme-pr.yml

Lines changed: 6 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,7 @@ jobs:
154154
echo "*******************************************"
155155
echo "::endgroup::"
156156
157+
157158
test-advanced-any:
158159
uses: pytorch/test-infra/.github/workflows/linux_job.yml@main
159160
secrets: inherit
@@ -173,27 +174,15 @@ jobs:
173174
export PATH=/opt/rh/devtoolset-10/root/usr/bin/:$PATH
174175
echo "::endgroup::"
175176
176-
echo "::group::Create script to run advanced"
177-
python3 scripts/updown.py --file docs/ADVANCED-USERS.md --replace 'llama3:stories15M,-l 3:-l 2,meta-llama/Meta-Llama-3-8B-Instruct:stories15M' --suppress huggingface-cli,HF_TOKEN > ./run-advanced.sh
178-
# for good measure, if something happened to updown processor,
179-
# and it did not error out, fail with an exit 1
180-
echo "exit 1" >> ./run-advanced.sh
181-
echo "::endgroup::"
182-
183-
echo "::group::Run advanced"
184-
echo "*******************************************"
185-
cat ./run-advanced.sh
186-
echo "*******************************************"
187-
bash -x ./run-advanced.sh
188-
=======
177+
.ci/scripts/run-docs advanced
189178
190179
echo "::group::Completion"
191180
echo "tests complete"
192181
echo "*******************************************"
193-
>>>>>>> e3db2486f80b71b3143945a44f58d50c02488c90
194182
echo "::endgroup::"
195183
196-
test-gguf-cpu:
184+
185+
test-advanced-cpu:
197186
uses: pytorch/test-infra/.github/workflows/linux_job.yml@main
198187
secrets: inherit
199188
with:
@@ -212,9 +201,10 @@ jobs:
212201
export PATH=/opt/rh/devtoolset-10/root/usr/bin/:$PATH
213202
echo "::endgroup::"
214203
215-
TORCHCHAT_DEVICE=cpu .ci/scripts/run-docs gguf
204+
TORCHCHAT_DEVICE=cpu .ci/scripts/run-docs advanced
216205
217206
echo "::group::Completion"
218207
echo "tests complete"
219208
echo "*******************************************"
220209
echo "::endgroup::"
210+

0 commit comments

Comments
 (0)