-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
action.yml
84 lines (70 loc) · 2.88 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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
name: "Python Lockfile Update"
description: "This action uses pip-tools to update a project's lockfiles via a Pull Request."
branding:
icon: "arrow-up-circle"
color: "purple"
inputs:
deploy_key:
description: "A deploy key with write access to the repository. This is required if you wish the PR to trigger workflows, as commits made with the Github Token will not. It is recommended to use a repository locked deploy key."
required: false
pr_body_text:
description: "The Pull Request comment for Pull Requests opened by this action."
required: true
default: "This Automated PR updates the requirements.txt files to the latest versions. As this is automated it should be reviewed for errors before merging."
pr_title:
description: "The Pull Request title for pull requests opened by this action."
required: true
default: "Automated Requirements File Updates"
github_username:
description: "The username to use for commits from this action."
required: false
default: ${{ github.actor }}
branch_prefix:
description: "A prefix used for generating branch names for the Pull Requests generated by this action."
required: true
default: "pip-update"
pip_extras:
description: "A list, separated by spaces, of `extra` packages to install. For example `dev arm` to build lockfiles for dev and arm extras."
required: false
default: ""
commit_message:
description: "The commit message used when committing updates to git."
required: true
default: "Automated Requirements File Updates"
allow_prerelease:
description: "If set to `true` this will allow prelease versions to be included."
required: false
default: ""
index_url:
description: "A repository index to use rather than PyPI. This is useful if you are using a private registry."
required: false
default: ""
pip_args:
description: "Arguments to be passed through to PIP."
required: false
default: ""
resolver:
description: "The dependency resolver to use. Defaults to the new backtracking algorithm- set to `legacy` for old behavior."
required: true
default: "backtracking"
runs:
using: "composite"
steps:
- name: Install pip-tools
run: python -m pip install pip-tools
shell: bash
- name: Update and Push
run: bash ${{ github.action_path }}/scripts/update.sh
shell: bash
env:
PR_BODY_TEXT: ${{ inputs.pr_body_text }}
PR_TITLE: ${{ inputs.pr_title }}
DEPLOY_KEY: ${{ inputs.deploy_key }}
BRANCH_PREFIX: ${{ inputs.branch_prefix }}
PIP_EXTRAS: ${{ inputs.pip_extras }}
COMMIT_MESSAGE: ${{ inputs.commit_message }}
GITHUB_USERNAME: ${{ inputs.github_username }}
ALLOW_PRERELEASE: ${{ inputs.allow_prerelease }}
INDEX_URL: ${{ inputs.index_url }}
PIP_ARGS: ${{ inputs.pip_args }}
RESOLVER: ${{ inputs.resolver }}