File tree Expand file tree Collapse file tree 1 file changed +14
-2
lines changed Expand file tree Collapse file tree 1 file changed +14
-2
lines changed Original file line number Diff line number Diff line change 8
8
type : string
9
9
required : true
10
10
default : " 0"
11
+ schedule :
12
+ # Run the second day of every month.
13
+ - cron : " 12 3 2 * *"
11
14
12
15
env :
13
16
# Change these for your project's URLs
@@ -28,10 +31,19 @@ jobs:
28
31
steps :
29
32
- name : Set date suffix
30
33
id : set-date
31
- run : echo "suffix=dev$(date +%Y%m%d)${{ github.event.inputs.iteration }}" >> $GITHUB_ENV
34
+ run : echo "suffix=dev$(date +%Y%m%d)" >> $GITHUB_ENV
35
+ - name : Determine Iteration Value
36
+ id : set-iteration
37
+ # If the action is running on a schedule, default iteration to 0
38
+ run : |
39
+ if [ "${{ github.event_name }}" == "workflow_dispatch" ]; then
40
+ echo "iteration=${{ github.event.inputs.iteration }}" >> $GITHUB_ENV
41
+ else
42
+ echo "iteration=0" >> $GITHUB_ENV
43
+ fi
32
44
- name : Output dev version
33
45
id : output-dev-version
34
- run : echo "dev_version=${{ env.suffix }}" >> "$GITHUB_OUTPUT"
46
+ run : echo "dev_version=${{ env.suffix }}${{ env.iteration }} " >> "$GITHUB_OUTPUT"
35
47
36
48
build :
37
49
name : Build distribution 📦
You can’t perform that action at this time.
0 commit comments