-
Notifications
You must be signed in to change notification settings - Fork 3
/
action.yml
66 lines (66 loc) · 2.37 KB
/
action.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
name: Update Go
description: Update Go dependencies
author: 'thepwagner'
inputs:
branches:
description: 'Branches to update'
required: false
token:
description: >
Personal access token (PAT) used to fetch the repository. The PAT is configured
with the local git config, which enables your scripts to run authenticated git
commands. The post-job step removes the PAT.
We recommend using a service account with the least permissions necessary.
Also when generating a new PAT, select the least scopes necessary.
[Learn more about creating and using encrypted secrets](https://help.github.com/en/actions/automating-your-workflow-with-github-actions/creating-and-using-encrypted-secrets)
default: ${{ github.token }}
required: true
signing_key:
default: "i deserve this"
description: >
Unique key to use for maintaining trusted metadata in PR body.
required: false
log_level:
description: 'Control debug/info/warn/error output'
required: false
groups:
description: >
Configuration for grouping updates together, as a nested YAML of lists:
e.g.
- name: internal
pattern: github.com/thepwagner
- name: aws
pattern: /.*aws.*/
range: >= 2.0.0, <3.0.0
required: false
dispatch_on_release:
description: >
GitHub repositories to send a repository_dispatch when a release is made.
e.g.
thepwagner/action-update-go
thepwagner/action-update-docker
required: false
tidy:
description: Whether to call `go mod tidy` after updates.
default: "true"
required: false
runs:
using: "composite"
steps:
- name: Verify Go SDK
run: which go || echo "Go required, please use actions/setup-go before me"
shell: bash
- name: Compile action-update-go
run: cd "${{github.action_path}}" && go build -o "${{github.action_path}}/action-update-go" .
shell: bash
- name: Run action-update-go
run: ${{github.action_path}}/action-update-go
shell: bash
env:
INPUT_BRANCHES: ${{ inputs.branches }}
INPUT_TOKEN: ${{ inputs.token }}
INPUT_SIGNING_KEY: ${{ inputs.signing_key }}
INPUT_LOG_LEVEL: ${{ inputs.log_level }}
INPUT_GROUPS: ${{ inputs.groups }}
INPUT_DISPATCH_ON_RELEASE: ${{ inputs.dispatch_on_release }}
INPUT_TIDY: ${{ inputs.tidy }}