File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -25,6 +25,10 @@ inputs:
25
25
metadata :
26
26
required : false
27
27
description : ' User provided map of max 8 key/value pairs of metadata to include with the snapshot e.g. {"lastModified": "12-31-2022"}'
28
+ force :
29
+ required : false
30
+ default : false
31
+ description : If true, dependencies are submitted even if the source repository contains a committed Package.resolved file.
28
32
29
33
runs :
30
34
using : composite
@@ -38,13 +42,15 @@ runs:
38
42
CORRELATOR : ${{ github.workflow_ref }}-${{ github.job }}-${{ github.action }}-${{ runner.os }}
39
43
REPO_SPEC : ${{ inputs.repository || github.repository }}
40
44
TOKEN : ${{ inputs.token || github.token }}
45
+ FORCE : ${{ inputs.force }}
41
46
shell : bash
42
47
run : |
43
48
# If there's a preexisting Package.resolved, Git knows about it, and it's unmodified,
44
49
# this action has nothing to do; a correct Dependabot configuration will already
45
50
# process that file.
46
51
if [[ -f "${PROJ}/Package.resolved" && \
47
- -z "$(git -C "${PROJ}" status --porcelain -uall --ignored -- Package.resolved)" ]]; then
52
+ -z "$(git -C "${PROJ}" status --porcelain -uall --ignored -- Package.resolved)" && \
53
+ "${FORCE}" != 'true' ]]; then
48
54
echo "Dependencies are autodetected when Package.resolved is committed, exiting."
49
55
exit 0
50
56
elif [[ -f "${PROJ}/Package.resolved" ]]; then
You can’t perform that action at this time.
0 commit comments