Skip to content

Commit 0e1dedf

Browse files
Common release file (#22)
* copy build files to generic name * add link to latest release in readme
1 parent 0a48a45 commit 0e1dedf

File tree

2 files changed

+12
-10
lines changed

2 files changed

+12
-10
lines changed

.github/workflows/release.yml

+11-9
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,6 @@ jobs:
1818
- name: Parse version
1919
id: version
2020
run: echo ::set-output name=version::${GITHUB_REF/refs\/tags\/v}
21-
- name: Generate expected file names
22-
id: file_names
23-
run: |
24-
echo ::set-output name=tar_file::shot-${{ steps.version.outputs.version }}.tar.gz
25-
echo ::set-output name=wheel_file::shot-${{ steps.version.outputs.version }}-py3-none-any.whl
2621
- name: Install Poetry
2722
run: |
2823
python -m pip install --upgrade pip
@@ -31,6 +26,13 @@ jobs:
3126
run: poetry install
3227
- name: Build package
3328
run: poetry build
29+
- name: Copy build files to generic names
30+
id: file_names
31+
run: |
32+
cp shot-${{ steps.version.outputs.version }}.tar.gz shot.tar.gz
33+
cp shot-${{ steps.version.outputs.version }}-py3-none-any.whl shot-py3-none-any.whl
34+
echo ::set-output name=tar_file::shot.tar.gz
35+
echo ::set-output name=wheel_file::shot-py3-none-any.whl
3436
- name: Generate SHAs
3537
id: sha
3638
run: |
@@ -42,16 +44,16 @@ jobs:
4244
env:
4345
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4446
with:
45-
tag_name: ${{ github.ref }}
46-
release_name: Release ${{ github.ref }}
47+
tag_name: ${{ github.ref }}
48+
release_name: Release ${{ github.ref }}
4749
draft: true
4850
prerelease: true
4951
body: |
5052
SHA256 checksums
5153
- ${{ steps.sha.outputs.tar_sha }}
5254
- ${{ steps.sha.outputs.wheel_sha }}
5355
- name: Upload tar.gz to Release
54-
id: upload-tar
56+
id: upload-tar
5557
uses: actions/upload-release-asset@v1
5658
env:
5759
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -61,7 +63,7 @@ jobs:
6163
asset_name: ${{ steps.file_names.outputs.tar_file }}
6264
asset_content_type: application/tar+gz
6365
- name: Upload wheel to Release
64-
id: upload-wheel
66+
id: upload-wheel
6567
uses: actions/upload-release-asset@v1
6668
env:
6769
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ brew install conorsheehan1/conorsheehan1/shot
2020

2121
# option 2 github release
2222
# https://github.com/ConorSheehan1/shot/releases e.g.
23-
pip install https://github.com/ConorSheehan1/shot/releases/download/v0.1.2/shot-0.1.2.tar.gz
23+
pip install https://github.com/ConorSheehan1/shot/releases/download/latest/shot.tar.gz
2424

2525
# option 3 from source
2626
git clone git@github.com:ConorSheehan1/shot.git

0 commit comments

Comments
 (0)