Skip to content

Commit 7fe50b6

Browse files
committed
test WIPACrepo/wipac-dev-workflows/tag-and-release/worlflow.yml@vtag-and-release
1 parent 1b8d94f commit 7fe50b6

File tree

2 files changed

+20
-66
lines changed

2 files changed

+20
-66
lines changed

.github/workflows/cicd.yml

Lines changed: 19 additions & 66 deletions
Original file line numberDiff line numberDiff line change
@@ -92,76 +92,29 @@ jobs:
9292
# TESTS
9393
############################################################################
9494

95+
# :o)
96+
9597

9698
############################################################################
97-
# TAG NEW VERSION
99+
# TAG NEW VERSION & MAKE RELEASE
98100
############################################################################
99101

100102
tag-and-release:
101-
# only run on main/master/default
103+
# only run on main/default
102104
if: format('refs/heads/{0}', github.event.repository.default_branch) == github.ref
103-
needs: [
104-
py-versions,
105-
flake8,
106-
mypy,
107-
py-setup,
108-
py-dependencies
109-
]
110-
runs-on: ubuntu-latest
105+
needs:
106+
- py-versions
107+
- flake8
108+
- mypy
109+
- py-setup
110+
- py-dependencies
111111
concurrency: tag-and-release # prevent any possible race conditions
112-
steps:
113-
- uses: actions/checkout@v4
114-
with:
115-
fetch-depth: 0 # required to see tags and commits
116-
ref: ${{ github.sha }} # lock to triggered commit ('github.ref' is dynamic)
117-
- uses: actions/setup-python@v5 # needed for building project
118-
with:
119-
python-version: "${{ fromJSON(needs.py-versions.outputs.matrix)[0] }}"
120-
121-
# Get Next Version & Tag
122-
- uses: WIPACrepo/wipac-dev-next-version-action@v1.2
123-
id: next-version
124-
with:
125-
force-patch-if-no-commit-token: true
126-
ignore-paths: |
127-
**/README.md
128-
.github/**
129-
.gitignore
130-
dependencies-logs/**
131-
tests/**
132-
- if: steps.next-version.outputs.version != ''
133-
name: Tag New Version
134-
run: |
135-
set -euo pipefail; echo "now: $(date -u +"%Y-%m-%dT%H:%M:%S.%3N")"
136-
git tag v${{ steps.next-version.outputs.version }} # note: prepend 'v'
137-
git push origin --tags
138-
139-
# Build Python Package
140-
- if: steps.next-version.outputs.version != ''
141-
uses: WIPACrepo/wipac-dev-py-build-action@v1.1
142-
# -> uses the most recent git tag for versioning (aka the one made above)
143-
# -> creates 'dist/' files
144-
145-
# Grab artifacts created by 'WIPACrepo/wipac-dev-py-dependencies-action'
146-
- if: steps.next-version.outputs.version != ''
147-
uses: actions/download-artifact@v4
148-
with:
149-
name: py-dependencies-logs
150-
path: pydep-release-assets/
151-
152-
# GitHub Release
153-
- if: steps.next-version.outputs.version != ''
154-
uses: softprops/action-gh-release@v2
155-
with:
156-
files: |
157-
dist/*
158-
pydep-release-assets/**/*
159-
tag_name: v${{ steps.next-version.outputs.version }} # must match git tag above
160-
generate_release_notes: true
161-
162-
# PyPI Release
163-
- if: steps.next-version.outputs.version != ''
164-
uses: pypa/gh-action-pypi-publish@release/v1
165-
with:
166-
user: __token__
167-
password: ${{ secrets.PYPI_TOKEN }}
112+
uses: WIPACrepo/wipac-dev-workflows/tag-and-release/worlflow.yml@vtag-and-release
113+
with:
114+
python-version: "${{ fromJSON(needs.py-versions.outputs.matrix)[0] }}"
115+
release-artifacts: |
116+
py-dependencies-logs
117+
publish-to-pypi: true
118+
secrets:
119+
PERSONAL_ACCESS_TOKEN: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
120+
PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }}

resources/nested/file.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,4 @@ hello vesta
2424
hello moon
2525
hello phobos
2626
hello deimos
27+
hello risa

0 commit comments

Comments
 (0)