fix(deps): update dependency @npmcli/arborist to v9.1.3 #119
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Fix pnpm-lock after renovate | |
on: | |
push: | |
branches: | |
- 'renovate/*' | |
paths: | |
- 'pnpm-lock.yaml' | |
# https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/controlling-permissions-for-github_token | |
permissions: {} | |
jobs: | |
fix-lock: | |
permissions: | |
pull-requests: write | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
with: | |
ref: ${{ github.head_ref }} | |
token: ${{ secrets.WORKFLOW_TOKEN }} | |
- name: Fix & comment | |
run: | | |
read -a array <<< "$COMMIT_MESSAGE" | |
if [ "${array[2]}" = "dependency" ]; then | |
corepack pnpm i --no-frozen-lockfile | |
node bin/cdxgen.js --exclude test/\*\* -t js --deep | |
echo "Output of \`pnpm why ${array[3]}\`:" > _tree.txt | |
echo "\`\`\`" >> _tree.txt | |
corepack pnpm why ${array[3]} >> _tree.txt | |
echo "\`\`\`" >> _tree.txt | |
echo "Output of \`jq\` on components:" >> _tree.txt | |
echo "\`\`\`" >> _tree.txt | |
jq --arg dep "${array[3]}" '.components[] | select(."bom-ref" | test($dep))' bom.json >> _tree.txt | |
echo "\`\`\`" >> _tree.txt | |
echo "Output of \`jq\` on dependencies:" >> _tree.txt | |
echo "\`\`\`" >> _tree.txt | |
jq --arg dep "${array[3]}" '.dependencies[] | select(.ref | test($dep))' bom.json >> _tree.txt | |
jq --arg dep "${array[3]}" '.dependencies[] | select(.dependsOn | any(test($dep)))' bom.json >> _tree.txt | |
echo "\`\`\`" >> _tree.txt | |
fi | |
env: | |
COMMIT_MESSAGE: ${{ github.event.head_commit.message }} | |
FETCH_LICENSE: true | |
- uses: mshick/add-pr-comment@b8f338c590a895d50bcbfa6c5859251edc8952fc # v2.8.2 | |
if: hashFiles('_tree.txt') | |
with: | |
message-path: _tree.txt | |
- uses: EndBug/add-and-commit@a94899bca583c204427a224a7af87c02f9b325d5 # v9.1.4 | |
with: | |
add: 'pnpm-lock.yaml' | |
commit: --signoff | |
default_author: github_actions | |
message: Fixed pnpm-lock after renovate update |