Skip to content

Commit 47c8a57

Browse files
authored
Merge pull request #358 from github/lcartey/fix-upgrade-dependencies-workflow
Fix the script reference in "Upgrade CodeQL dependencies" workflow
2 parents 7c50f5b + 1ed7676 commit 47c8a57

File tree

1 file changed

+11
-8
lines changed

1 file changed

+11
-8
lines changed

.github/workflows/upgrade_codeql_dependencies.yml

+11-8
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ env:
1212
XARGS_MAX_PROCS: 4
1313

1414
jobs:
15-
say_hello:
15+
upgrade_codeql_dependencies:
1616
env:
1717
CODEQL_CLI_VERSION: ${{ github.event.inputs.codeql_cli_version }}
1818
runs-on: ubuntu-22.04
@@ -33,26 +33,29 @@ jobs:
3333
GITHUB_TOKEN: ${{ github.token }}
3434
CODEQL_CLI_VERSION: ${{ github.event.inputs.codeql_cli_version }}
3535
run: |
36-
scripts/upgrade-codeql-dependencies/upgrade_codeql_dependencies.py --cli-version "$CODEQL_CLI_VERSION"
36+
python3 scripts/upgrade-codeql-dependencies/upgrade-codeql-dependencies.py --cli-version "$CODEQL_CLI_VERSION"
3737
3838
- name: Fetch CodeQL
3939
env:
4040
GITHUB_TOKEN: ${{ github.token }}
41+
RUNNER_TEMP: ${{ runner.temp }}
4142
run: |
43+
cd $RUNNER_TEMP
4244
gh release download "v${CODEQL_CLI_VERSION}" --repo https://github.com/github/codeql-cli-binaries --pattern codeql-linux64.zip
4345
unzip -q codeql-linux64.zip
4446
4547
- name: Update CodeQL formatting based on new CLI version
48+
env:
49+
RUNNER_TEMP: ${{ runner.temp }}
4650
run: |
47-
find cpp -name '*.ql' -or -name '*.qll' | xargs --max-procs "$XARGS_MAX_PROCS" --max-args 1 codeql/codeql query format --in-place
48-
find c -name '*.ql' -or -name '*.qll' | xargs --max-procs "$XARGS_MAX_PROCS" --max-args 1 codeql/codeql query format --in-place
51+
find cpp \( -name '*.ql' -or -name '*.qll' \) -print0 | xargs -0 --max-procs "$XARGS_MAX_PROCS" $RUNNER_TEMP/codeql/codeql query format --in-place
52+
find c \( -name '*.ql' -or -name '*.qll' \) -print0 | xargs -0 --max-procs "$XARGS_MAX_PROCS" $RUNNER_TEMP/codeql/codeql query format --in-place
4953
5054
- name: Create Pull Request
5155
uses: peter-evans/create-pull-request@v3
5256
with:
53-
title: "Upgrading `github/codeql` dependency to ${{ github.event.inputs.codeql_standard_library_commit }}"
54-
body: "This PR upgrades the CodeQL CLI version to ${{ github.event.inputs.codeql_cli_version }} and the `github/codeql` version to ${{ github.event.inputs.codeql_standard_library_commit }}."
55-
commit-message: "Upgrading `github/codeql` dependency to ${{ github.event.inputs.codeql_standard_library_commit }}"
56-
team-reviewers: github/codeql-coding-standards
57+
title: "Upgrading `github/codeql` dependency to ${{ github.event.inputs.codeql_cli_version }}"
58+
body: "This PR upgrades the CodeQL CLI version to ${{ github.event.inputs.codeql_cli_version }}."
59+
commit-message: "Upgrading `github/codeql` dependency to ${{ github.event.inputs.codeql_cli_version }}"
5760
delete-branch: true
5861
branch: "codeql/upgrade-to-${{ github.event.inputs.codeql_cli_version }}"

0 commit comments

Comments
 (0)