-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: On workflow_dispatch, update py-shiny module and deploy to gh-pag…
…es (#122) * Add `submodules-pull-shiny` target for Makefile * Add script to manually commit to main with the latest py-shiny version on GitHub * debug * update permissions to token * Pull latest posit-dev/py-shiny@9570af4 * Revert "Pull latest posit-dev/py-shiny@9570af4" This reverts commit ad155d9. * Add workflow_run trigger to main job (that deploys to gh-pages) * Pull latest posit-dev/py-shiny@9570af4 * Revert "Pull latest posit-dev/py-shiny@9570af4" This reverts commit 133d07a. * Update test branch to `main` * Use `setup-python@v5` to avoid warning in GHA
- Loading branch information
Showing
3 changed files
with
50 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
name: Update py-shiny submodule | ||
|
||
on: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
update-shiny: | ||
name: Update py-shiny submodule | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Set up Python 3.11 | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: "3.11" | ||
|
||
- name: Upgrade pip | ||
run: python -m pip install --upgrade pip | ||
|
||
- name: Check out submodules | ||
run: | | ||
make submodules | ||
- name: Pull latest py-shiny | ||
run: | | ||
make submodules-pull | ||
- name: Build shinylive | ||
run: | | ||
make all | ||
- name: Set up git within GHA | ||
uses: actions4git/setup-git@v1 | ||
|
||
- name: Commit and push changes | ||
run: | | ||
PY_SHINY_SHA=$(git -C packages/py-shiny rev-parse --short HEAD) | ||
git add packages/py-shiny shinylive_lock.json && \ | ||
git commit --message "Pull latest posit-dev/py-shiny@$PY_SHINY_SHA" && \ | ||
git push origin HEAD:main |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters