-
Notifications
You must be signed in to change notification settings - Fork 149
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: add a fake version of tag.yml workflow
This fake version of the tag.yml workflow is used to verify as much as possible that the changes in tag.yml are going to work as expected.
- Loading branch information
1 parent
75975fe
commit 1dc2e2e
Showing
1 changed file
with
94 additions
and
0 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,94 @@ | ||
name: Fake Application Release | ||
|
||
# This is a simplified copy of tag.yml, only there for testing during PR. | ||
# It does not create any release or upload any assets: publishing steps are replaced | ||
# by a call to `ls` showing which assets are available. | ||
|
||
on: | ||
pull_request: | ||
|
||
jobs: | ||
build_release_assets: | ||
uses: .github/workflows/build_release_assets.yml | ||
secrets: inherit | ||
|
||
push_to_pypi: | ||
needs: build_release_assets | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Set up Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.x' | ||
|
||
- name: Download packages | ||
uses: actions/download-artifact@v4 | ||
with: | ||
name: packages | ||
|
||
- name: List downloaded artifacts | ||
run: | | ||
ls packages | ||
ls dist | ||
release: | ||
runs-on: ubuntu-latest | ||
needs: build_release_assets | ||
continue-on-error: true | ||
|
||
# This is required for `gh release create` to work | ||
permissions: | ||
contents: write | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Read info | ||
id: tags | ||
shell: bash | ||
run: | | ||
echo "tag=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_OUTPUT | ||
- name: Download packages | ||
uses: actions/download-artifact@v4 | ||
with: | ||
name: packages | ||
|
||
- name: Download standalone binaries | ||
uses: actions/download-artifact@v4 | ||
with: | ||
pattern: standalone-binaries-* | ||
path: standalone-binaries | ||
merge-multiple: true | ||
|
||
- name: List downloaded artifacts | ||
run: | | ||
ls \ | ||
packages/ggshield-*.pyz \ | ||
packages/ggshield_*.deb \ | ||
packages/ggshield-*.rpm \ | ||
standalone-binaries/ggshield-*.pkg | ||
push_to_cloudsmith: | ||
needs: build_release_assets | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Download packages | ||
uses: actions/download-artifact@v4 | ||
with: | ||
name: packages | ||
|
||
- name: Install Cloudsmith CLI | ||
run: pip install cloudsmith-cli | ||
|
||
- name: List downloaded artifacts | ||
run: | | ||
ls packages | ||
ls dist |