Skip to content

Commit 77a9999

Browse files
Main simplify release (#87)
* get full git history first * remove deprecated auth warning * use pnpm publish instead of npm * @instructure.ai/[email protected] * lint * @instructure.ai/[email protected] * Update .github/workflows/release-package.yml Co-authored-by: Copilot <[email protected]> * Update .github/workflows/release-package.yml Co-authored-by: Copilot <[email protected]> * update build script * properly invoke custom build script * simplify release script * exit early when no change in ./apps * easier PR prefix validation * use fetch-depth: 0 * robust git dif * use proper exit codes * use conditional yaml --------- Co-authored-by: Copilot <[email protected]>
1 parent 83f1eae commit 77a9999

File tree

1 file changed

+14
-4
lines changed

1 file changed

+14
-4
lines changed

.github/workflows/deploy-apps.yml

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,37 +26,47 @@ jobs:
2626
with:
2727
fetch-depth: 0
2828

29-
- name: Exit if no changes in ./apps
29+
- name: Check for changes in ./apps
30+
id: changes
3031
shell: bash
3132
run: |
3233
BEFORE_SHA="${{ github.event.before }}"
3334
AFTER_SHA="${{ github.sha }}"
34-
# Try diffing with BEFORE_SHA, fallback to HEAD~1 if not available
3535
if git cat-file -e "$BEFORE_SHA" 2>/dev/null; then
3636
DIFF_RANGE="$BEFORE_SHA $AFTER_SHA"
3737
else
3838
DIFF_RANGE="HEAD~1 HEAD"
3939
fi
40-
if ! git diff --name-only $DIFF_RANGE | grep '^apps/'; then
40+
if ! git diff --name-only $DIFF_RANGE | grep '^apps/' ; then
4141
echo "No changes in ./apps directory. Exiting early."
42-
exit 78
42+
echo "skip_steps=true" >> $GITHUB_OUTPUT
43+
else
44+
echo "skip_steps=false" >> $GITHUB_OUTPUT
4345
fi
46+
4447
- name: Set up Node
48+
if: steps.changes.outputs.skip_steps != 'true'
4549
uses: actions/setup-node@v4
4650
with:
4751
node-version: lts/*
4852
- name: Setup pnpm
53+
if: steps.changes.outputs.skip_steps != 'true'
4954
uses: pnpm/[email protected]
5055
- name: Install dependencies
56+
if: steps.changes.outputs.skip_steps != 'true'
5157
run: pnpm i
5258
- name: Build
59+
if: steps.changes.outputs.skip_steps != 'true'
5360
run: pnpm build apps
5461
- name: Setup Pages
62+
if: steps.changes.outputs.skip_steps != 'true'
5563
uses: actions/configure-pages@v5
5664
- name: Upload artifact
65+
if: steps.changes.outputs.skip_steps != 'true'
5766
uses: actions/upload-pages-artifact@v3
5867
with:
5968
path: './dist'
6069
- name: Deploy to GitHub Pages
70+
if: steps.changes.outputs.skip_steps != 'true'
6171
id: deployment
6272
uses: actions/deploy-pages@v4

0 commit comments

Comments
 (0)