Skip to content

Commit 28ad5df

Browse files
authored
Merge pull request #8 from techman83/improve_releases
Improve Releases
2 parents 71ec36f + dd1ad74 commit 28ad5df

File tree

2 files changed

+9
-28
lines changed

2 files changed

+9
-28
lines changed

.github/workflows/release.yml

+8-27
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,21 @@
1+
---
12
name: Release Version
23

34
on:
45
push:
5-
branches:
6-
- main
7-
paths:
8-
- filament_scale_enhanced/fse_version.py
6+
tags:
7+
- "v*"
98

109
jobs:
11-
tag:
10+
generate-release:
1211
runs-on: ubuntu-latest
13-
outputs:
14-
version: ${{ steps.output_version.outputs.version }}
1512
steps:
1613
- uses: actions/checkout@v2
17-
- name: collect_tag_version
14+
- name: Set package version
1815
run: |
19-
echo VERSION=$(cat filament_scale_enhanced/fse_version.py | awk '{ print $3 }' | sed 's/"//g') >> $GITHUB_ENV
20-
- name: Push tag
21-
uses: mathieudutour/[email protected]
22-
with:
23-
github_token: ${{ secrets.GITHUB_TOKEN }}
24-
custom_tag: ${{ env.VERSION }}
25-
tag_prefix: v
26-
- name: Output Version
27-
id: output_version
28-
run: echo "::set-output name=version::${{ env.VERSION }}"
29-
30-
release:
31-
runs-on: ubuntu-latest
32-
needs: tag
33-
steps:
34-
- uses: actions/checkout@v2
35-
with:
36-
ref: "v${{ needs.tag.outputs.version }}"
16+
export VERSION=$(echo $GITHUB_REF | sed 's/refs\/tags\/v//')
17+
echo "VERSION set to $VERSION"
18+
echo VERSION = \'$VERSION\' > filament_scale_enhanced/fse_version.py
3719
- name: Setup Python
3820
uses: actions/setup-python@v2
3921
with:
@@ -53,7 +35,6 @@ jobs:
5335
repo_token: "${{ secrets.GITHUB_TOKEN }}"
5436
prerelease: false
5537
draft: false
56-
automatic_release_tag: "v${{ needs.tag.outputs.version }}"
5738
files: |
5839
LICENSE.txt
5940
dist/Filament_Scale_Enhanced.zip
+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
VERSION = "0.2.7"
1+
VERSION = "0.0.0"

0 commit comments

Comments
 (0)