1- name : Other branches
1+ name : Push to other branches
22
33on :
44 push :
@@ -12,34 +12,38 @@ jobs:
1212 runs-on : ubuntu-latest
1313 steps :
1414 - name : Checkout repository
15- uses : actions/checkout@v2
15+ uses : actions/checkout@v2.3.4
1616
1717 - name : Update labels - dry run
18- uses : crazy-max/ghaction-github-labeler@v1
18+ uses : crazy-max/ghaction-github-labeler@v3.1.1
1919 with :
20- dry_run : true
21- env :
22- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
20+ github-token : ${{ secrets.GITHUB_TOKEN }}
21+ dry-run : true
2322
2423 lint :
2524 name : Run linters
2625 runs-on : ubuntu-latest
2726 steps :
2827 - name : Checkout repository
29- uses : actions/checkout@v2
28+ uses : actions/checkout@v2.3.4
3029
3130 - name : Docker Lint
32- uses : luke142367/Docker-Lint-Action@v1.0.0
31+ uses : luke142367/Docker-Lint-Action@v1.1.1
3332 env :
3433 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
3534
35+ - name : Haskell Dockerfile Linter (Hadolint)
36+ 37+ with :
38+ dockerfile : Dockerfile
39+
3640 build :
3741 name : Build image
3842 needs : lint
3943 runs-on : ubuntu-latest
4044 steps :
4145 - name : Checkout repository
42- uses : actions/checkout@v2
46+ uses : actions/checkout@v2.3.4
4347
4448 - name : Build Docker image
4549 env :
@@ -51,30 +55,38 @@ jobs:
5155 runs-on : ubuntu-latest
5256 steps :
5357 - name : Checkout repository
54- uses : actions/checkout@v2
58+ 59+ with :
60+ fetch-depth : 0
61+
62+ - name : Create pull request - bugfix (conditional)
63+ if : startsWith(github.ref, 'refs/heads/bugfix')
64+ uses : devops-infra/action-pull-request@master
65+ with :
66+ github_token : ${{ secrets.GITHUB_TOKEN }}
67+ assignee : ${{ github.actor }}
68+ label : bugfix
69+ template : .github/PULL_REQUEST_TEMPLATE.md
70+ get_diff : true
5571
5672 - name : Create pull request - dependency (conditional)
5773 if : startsWith(github.ref, 'refs/heads/dependency')
5874 uses : devops-infra/action-pull-request@master
5975 with :
6076 github_token : ${{ secrets.GITHUB_TOKEN }}
6177 assignee : ${{ github.actor }}
62- label : automatic,dependency
63- template : .github/PULL_REQUEST_TEMPLATE/DEPENDENCY.md
64- old_string : " <!-- Write you description here -->"
65- new_string : ${{ github.event.commits[0].message }}
78+ label : dependency
79+ template : .github/PULL_REQUEST_TEMPLATE.md
6680 get_diff : true
6781
68- - name : Create pull request - bugfix (conditional)
69- if : startsWith(github.ref, 'refs/heads/bugfix ')
82+ - name : Create pull request - documentation (conditional)
83+ if : startsWith(github.ref, 'refs/heads/documentation ')
7084 uses : devops-infra/action-pull-request@master
7185 with :
7286 github_token : ${{ secrets.GITHUB_TOKEN }}
7387 assignee : ${{ github.actor }}
74- label : automatic,bugfix
75- template : .github/PULL_REQUEST_TEMPLATE/BUGFIX.md
76- old_string : " <!-- Write you description here -->"
77- new_string : ${{ github.event.commits[0].message }}
88+ label : documentation
89+ template : .github/PULL_REQUEST_TEMPLATE.md
7890 get_diff : true
7991
8092 - name : Create pull request - feature (conditional)
@@ -83,32 +95,28 @@ jobs:
8395 with :
8496 github_token : ${{ secrets.GITHUB_TOKEN }}
8597 assignee : ${{ github.actor }}
86- label : automatic,feature
87- template : .github/PULL_REQUEST_TEMPLATE/FEATURE.md
88- old_string : " <!-- Write you description here -->"
89- new_string : ${{ github.event.commits[0].message }}
98+ label : feature
99+ template : .github/PULL_REQUEST_TEMPLATE.md
90100 get_diff : true
91101
92- - name : Create pull request - documentation (conditional)
93- if : startsWith(github.ref, 'refs/heads/documentation ')
102+ - name : Create pull request - test (conditional)
103+ if : startsWith(github.ref, 'refs/heads/test ')
94104 uses : devops-infra/action-pull-request@master
95105 with :
96106 github_token : ${{ secrets.GITHUB_TOKEN }}
97107 assignee : ${{ github.actor }}
98- label : automatic,documentation
99- template : .github/PULL_REQUEST_TEMPLATE/DOCUMENTATION.md
100- old_string : " <!-- Write you description here --> "
101- new_string : ${{ github.event.commits[0].message }}
108+ reviewer : ${{ github.actor }}
109+ label : test
110+ template : .github/PULL_REQUEST_TEMPLATE.md
111+ draft : true
102112 get_diff : true
103113
104114 - name : Create pull request - other (conditional)
105- if : startsWith(github.ref, '! refs/heads/dependency ') && startsWith(github.ref, '! refs/heads/bugfix ') && startsWith(github.ref, '! refs/heads/feature') && startsWith(github.ref, '! refs/heads/documentation')
115+ if : " ! startsWith(github.ref, 'refs/heads/bugfix ') && ! startsWith(github.ref, 'refs/heads/dependabot') && !startsWith(github.ref, ' refs/heads/dependency ') && ! startsWith(github.ref, 'refs/heads/documentation') && !startsWith(github.ref, ' refs/heads/feature') && ! startsWith(github.ref, 'refs/heads/test') "
106116 uses : devops-infra/action-pull-request@master
107117 with :
108118 github_token : ${{ secrets.GITHUB_TOKEN }}
109119 assignee : ${{ github.actor }}
110- label : automatic,feature
111- template : .github/PULL_REQUEST_TEMPLATE/FEATURE.md
112- old_string : " <!-- Write you description here -->"
113- new_string : ${{ github.event.commits[0].message }}
120+ label : feature
121+ template : .github/PULL_REQUEST_TEMPLATE.md
114122 get_diff : true
0 commit comments