File tree Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change 1
1
name : Create Prod Image
2
- on :
3
- release :
4
- types : [published]
2
+ on :
3
+ workflow_dispatch :
4
+ inputs :
5
+ image_tag :
6
+ description : ' Image tag'
7
+ required : true
5
8
6
9
jobs :
7
10
check-release :
16
19
17
20
- name : Set Image Tag
18
21
id : itag
19
- run : echo "itag=${{ github.event.release.tag_name }}" >> $GITHUB_OUTPUT
22
+ run : echo "itag=${{ github.event.inputs.image_tag }}" >> $GITHUB_OUTPUT
20
23
21
24
- name : Check Release Tag
22
25
run : |
28
31
29
32
- name : Check Cargo.toml Version
30
33
run : |
31
- CARGO_VERSION=$(grep '^ version =' Cargo.toml | sed 's/version = "\(.*\)"/\1/ ')
34
+ CARGO_VERSION=$(awk '/\[package\]/ {flag=1} flag && / version =/ {print $3; flag=0} ' Cargo.toml | sed 's/"//g ')
32
35
TAG_VERSION=${{ steps.itag.outputs.itag }}
33
36
TAG_VERSION=${TAG_VERSION#"v"} # Remove the leading 'v' from the tag
34
37
You can’t perform that action at this time.
0 commit comments