-
Notifications
You must be signed in to change notification settings - Fork 187
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c181a5f
commit fef4069
Showing
2 changed files
with
49 additions
and
3 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
name: CI Docs | ||
|
||
on: | ||
push: # Run on pushes to the default branch | ||
branches: [main, docs_job] | ||
pull_request_target: # Also run on pull requests originated from forks | ||
branches: [main, docs_job] | ||
release: | ||
types: ['published'] | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
|
||
Deploy-Pages: | ||
permissions: | ||
contents: write | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ github.event.pull_request.head.sha || github.ref }} | ||
|
||
- uses: actions/setup-python@v5 | ||
with: | ||
python-version: "3.12" | ||
architecture: "x64" | ||
|
||
- name: Install packages and dependencies | ||
run: pip install hatch | ||
|
||
- name: Deploy Docs | ||
run: | | ||
git config user.name "OSS Integration Bot" | ||
git config user.email "[email protected]" | ||
git fetch origin gh-pages --depth=1 | ||
if [[ $GITHUB_EVENT_NAME == "release" && $GITHUB_EVENT_ACTION == "published" ]]; then | ||
hatch run docs:gh-release | ||
else | ||
hatch run docs:gh-deploy | ||
fi |
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