Skip to content

Commit 0f8a012

Browse files
authored
fix: updatecli workflows (#1012)
* fix: updatecli workflows Signed-off-by: Olivier Vernin <[email protected]> * chore: update remaining updatecli version Signed-off-by: Olivier Vernin <[email protected]> * fix: remove github_token Signed-off-by: Olivier Vernin <[email protected]> --------- Signed-off-by: Olivier Vernin <[email protected]>
1 parent 097f2d5 commit 0f8a012

File tree

5 files changed

+77
-81
lines changed

5 files changed

+77
-81
lines changed

.github/workflows/updatecli.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
- name: "Setup updatecli"
1717
uses: "updatecli/updatecli-action@5ca36367fadc6ad94d590984fd9c696e783ec635" # v2.96.0
1818
with:
19-
version: "v0.113.0-rc.1"
19+
version: "v0.113.0"
2020

2121
- name: "Run updatecli"
2222
run: updatecli compose apply --clean-git-branches=true --experimental

.github/workflows/updatecli_test.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,11 @@ jobs:
1616
- name: "Setup updatecli"
1717
uses: "updatecli/updatecli-action@5ca36367fadc6ad94d590984fd9c696e783ec635" # v2.96.0
1818
with:
19-
version: "v0.113.0-rc.1"
19+
version: "v0.113.0"
2020

2121
- name: "Test updatecli in dry-run mode"
2222
run: "updatecli compose diff"
2323
env:
2424
# This step is executed in untrusted context. We use a GitHub token with minimal permissions.
25-
GITHUB_ACTOR: ${{ github.actor }}
26-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
25+
UPDATECLI_GITHUB_USERNAME: ${{ github.actor }}
26+
UPDATECLI_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/updatecli_update.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
- name: "Setup updatecli"
1616
uses: "updatecli/updatecli-action@5ca36367fadc6ad94d590984fd9c696e783ec635" # v2.96.0
1717
with:
18-
version: "v0.113.0-rc.1"
18+
version: "v0.113.0"
1919

2020
- name: "Run updatecli only on existing pipelines"
2121
run: updatecli compose apply --clean-git-branches=true --existing-only=true --experimental
Lines changed: 69 additions & 72 deletions
Original file line numberDiff line numberDiff line change
@@ -1,81 +1,78 @@
11
name: "deps: bump updatecli version"
22
pipelineid: "updatecli_action_version"
33
actions:
4-
default:
5-
kind: "github/pullrequest"
6-
spec:
7-
title: 'deps: update updatecli version to {{ source "updatecli" }}'
8-
automerge: true
9-
mergemethod: "squash"
10-
usetitleforautomerge: true
11-
reviewers:
12-
- "updatecli/core"
13-
labels:
14-
- "dependencies"
15-
- "updatecli"
16-
scmid: "default"
4+
default:
5+
kind: "github/pullrequest"
6+
spec:
7+
title: 'deps: update updatecli version to {{ source "updatecli" }}'
8+
automerge: true
9+
mergemethod: "squash"
10+
usetitleforautomerge: true
11+
reviewers:
12+
- "updatecli/core"
13+
labels:
14+
- "dependencies"
15+
- "updatecli"
16+
scmid: "default"
1717
scms:
18-
default:
19-
kind: "github"
20-
spec:
21-
branch: '{{ .scm.branch }}'
22-
email: ' {{ .scm.email }}'
23-
owner: '{{ .scm.owner }}'
24-
repository: '{{ .scm.repository }}'
25-
token: '{{requiredEnv "GITHUB_TOKEN"}}'
26-
user: '{{ .scm.user }}'
27-
username: '{{ .scm.username }}'
28-
commitusingapi: true
29-
disabled: false
18+
default:
19+
kind: "github"
20+
spec:
21+
branch: "{{ .scm.branch }}"
22+
email: " {{ .scm.email }}"
23+
owner: "{{ .scm.owner }}"
24+
repository: "{{ .scm.repository }}"
25+
user: "{{ .scm.user }}"
26+
commitusingapi: true
27+
disabled: false
3028
sources:
31-
updatecli:
32-
name: "Get latest updatecli version"
33-
kind: "githubrelease"
34-
spec:
35-
owner: "updatecli"
36-
repository: "updatecli"
37-
token: '{{requiredEnv "GITHUB_TOKEN"}}'
38-
versionfilter:
39-
kind: "semver"
29+
updatecli:
30+
name: "Get latest updatecli version"
31+
kind: "githubrelease"
32+
spec:
33+
owner: "updatecli"
34+
repository: "updatecli"
35+
versionfilter:
36+
kind: "semver"
4037
targets:
41-
src-main:
42-
name: 'deps: bump updatecli version in src/main.js to {{ source "updatecli" }}'
43-
kind: "file"
44-
spec:
45-
file: "src/main.js"
46-
matchpattern: 'const DEFAULT_VERSION = (.+)'
47-
replacepattern: 'const DEFAULT_VERSION = `{{ source "updatecli" }}`'
48-
scmid: "default"
49-
sourceid: "updatecli"
38+
src-main:
39+
name: 'deps: bump updatecli version in src/main.js to {{ source "updatecli" }}'
40+
kind: "file"
41+
spec:
42+
file: "src/main.js"
43+
matchpattern: "const DEFAULT_VERSION = (.+)"
44+
replacepattern: 'const DEFAULT_VERSION = `{{ source "updatecli" }}`'
45+
scmid: "default"
46+
sourceid: "updatecli"
5047

51-
test-main:
52-
name: 'deps: bump updatecli version in tests/main.test.js to {{ source "updatecli" }}'
53-
kind: "file"
54-
spec:
55-
file: "tests/main.test.js"
56-
matchpattern: "const DEFAULT_VERSION = (.+)"
57-
replacepattern: 'const DEFAULT_VERSION = `{{ source "updatecli" }}`'
58-
scmid: "default"
59-
sourceid: "updatecli"
48+
test-main:
49+
name: 'deps: bump updatecli version in tests/main.test.js to {{ source "updatecli" }}'
50+
kind: "file"
51+
spec:
52+
file: "tests/main.test.js"
53+
matchpattern: "const DEFAULT_VERSION = (.+)"
54+
replacepattern: 'const DEFAULT_VERSION = `{{ source "updatecli" }}`'
55+
scmid: "default"
56+
sourceid: "updatecli"
6057

61-
dist:
62-
name: 'chore: rebuild the dist directory'
63-
dependson:
64-
- "src-main"
65-
- "test-main"
66-
disablesourceinput: true
67-
kind: shell
68-
scmid: "default"
58+
dist:
59+
name: "chore: rebuild the dist directory"
60+
dependson:
61+
- "src-main"
62+
- "test-main"
63+
disablesourceinput: true
64+
kind: shell
65+
scmid: "default"
66+
spec:
67+
command: |
68+
npm ci
69+
npm run prepare
70+
changedif:
71+
kind: file/checksum
6972
spec:
70-
command: |
71-
npm ci
72-
npm run prepare
73-
changedif:
74-
kind: file/checksum
75-
spec:
76-
files:
77-
- "dist/index.js"
78-
- "dist/index.js.map"
79-
environments:
80-
- name: "PATH"
81-
- name: "HOME"
73+
files:
74+
- "dist/index.js"
75+
- "dist/index.js.map"
76+
environments:
77+
- name: "PATH"
78+
- name: "HOME"

updatecli/values.d/scm.yaml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
scm:
22
enabled: true
3-
user: updatecli
4-
email: updatecli-[email protected]
3+
user: updateclibot
4+
55
owner: updatecli
6-
repository: updatecli-action
7-
username: "updatecli"
86
branch: v2
7+
repository: updatecli-action

0 commit comments

Comments
 (0)