Skip to content

Commit

Permalink
add publish workflow, and instructions in readme
Browse files Browse the repository at this point in the history
  • Loading branch information
tsmbland committed Oct 24, 2023
1 parent 2054740 commit 60c1c13
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Test

on: [push, pull_request, release]
on: [push, pull_request, workflow_call]

jobs:
qa:
Expand Down
27 changes: 27 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
on: [release]

jobs:
test:
uses: ./.github/workflows/ci.yml

publish:
runs-on: ubuntu-latest
needs: test
# Uncomment the following steps to build a Docker image and publish to the GitHub container registry on release. Alternatively, can replace with other publising steps (ie. publishing to PyPI, deploying documentation etc.)
# steps:
# - name: Login to GitHub Container Registry
# uses: docker/login-action@v3
# with:
# registry: ghcr.io
# username: ${{ github.actor }}
# password: ${{ secrets.GITHUB_TOKEN }}
# - name: Get image metadata
# id: meta
# uses: docker/metadata-action@v5
# with:
# images: ghcr.io/${{ github.repository }}
# - name: Build and push Docker image
# uses: docker/build-push-action@v5
# with:
# push: true
# tags: ${{ steps.meta.outputs.tags }}
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,3 +80,8 @@ for this are:
- Note that `pre-commit.ci` is an external service and free for open source repos. For private repos uncomment the commented portion of the `pre-commit_autoupdate.yml` workflow.

[`pip-tools`]: https://pip-tools.readthedocs.io/en/latest/


### Publishing

The GitHub workflow includes an action to publish on release (`publish.yml`). Add steps where indicated to publish a Docker image, PyPI package, documentation, etc.

0 comments on commit 60c1c13

Please sign in to comment.