Skip to content
This repository was archived by the owner on Aug 28, 2025. It is now read-only.

Commit 8334f34

Browse files
committed
bash: use set -ex for early exit publication
1 parent 65710b9 commit 8334f34

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

.actions/assistant.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ class AssistantCLI:
154154
"lightning_examples": "Lightning-Examples",
155155
"flash_tutorials": "Kaggle",
156156
}
157-
_BASH_SCRIPT_BASE = ("#!/bin/bash", "set -e", "")
157+
_BASH_SCRIPT_BASE = ("#!/bin/bash", "set -ex", "")
158158
_EXT_ARCHIVE_ZIP = (".zip",)
159159
_EXT_ARCHIVE_TAR = (".tar", ".gz")
160160
_EXT_ARCHIVE = _EXT_ARCHIVE_ZIP + _EXT_ARCHIVE_TAR

.azure/ipynb-publish.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ jobs:
2424
printf "commit hash:\n $(COMMIT_HASH)\n"
2525
printf "commit message:\n $(COMMIT_MSG)\n"
2626
displayName: "Set Git user"
27+
timeoutInMinutes: "5"
2728
- bash: |
2829
set -e
2930
git fetch --all
@@ -59,8 +60,10 @@ jobs:
5960
git commit -m "prune: $(COMMIT_HASH)"
6061
condition: gt(variables['dropped.folders'], 0)
6162
displayName: "Prune notebook"
63+
timeoutInMinutes: "10"
6264
6365
- bash: |
66+
set -ex
6467
git status
6568
git push https://$(PAT_GHOST)@github.com/Lightning-AI/tutorials.git $(PUB_BRANCH)
6669
displayName: "Finish push"
@@ -118,6 +121,7 @@ jobs:
118121
printf "commit hash:\n $(COMMIT_HASH)\n"
119122
printf "commit message:\n $(COMMIT_MSG)\n"
120123
displayName: "Set Git user"
124+
timeoutInMinutes: "5"
121125
- bash: |
122126
set -e
123127
git fetch --all
@@ -128,6 +132,7 @@ jobs:
128132
git show-ref $(PUB_BRANCH)
129133
git pull
130134
displayName: "Git check & switch branch"
135+
timeoutInMinutes: "5"
131136
132137
- bash: |
133138
set -e
@@ -136,6 +141,7 @@ jobs:
136141
# todo: adjust torch ecosystem versions
137142
pip install -r requirements.txt -r _requirements/data.txt
138143
displayName: "Install dependencies"
144+
timeoutInMinutes: "15"
139145
140146
- bash: |
141147
set -e
@@ -146,6 +152,7 @@ jobs:
146152
147153
- bash: python .actions/assistant.py convert-ipynb $(notebook)
148154
displayName: "Generate notebook"
155+
timeoutInMinutes: "5"
149156

150157
- bash: |
151158
set -e
@@ -161,6 +168,7 @@ jobs:
161168
displayName: "Render notebook"
162169
163170
- bash: |
171+
set -ex
164172
git status
165173
git show-ref $(PUB_BRANCH)
166174
git push https://$(PAT_GHOST)@github.com/Lightning-AI/tutorials.git $(PUB_BRANCH)

0 commit comments

Comments
 (0)