Skip to content

Commit c58db69

Browse files
authored
[ci] Fix check-licenses (#1208)
* [DNM] Debug check-licenses * fix gha * add permissions * add install * add debug * try one path * run for each repo * rm check d labels * run 3 in parallel * try fail-fast: false * fix gitlab pipeline
1 parent 41fb4cc commit c58db69

File tree

2 files changed

+16
-60
lines changed

2 files changed

+16
-60
lines changed

.github/workflows/check-D-labels.yml

Lines changed: 0 additions & 54 deletions
This file was deleted.

.github/workflows/check-licenses.yml

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,22 +3,32 @@ name: Check licenses
33
on:
44
pull_request:
55

6+
permissions:
7+
packages: read
8+
69
jobs:
710
check-licenses:
811
runs-on: ubuntu-22.04
12+
strategy:
13+
fail-fast: false
14+
matrix:
15+
repo: [polkadot, substrate, cumulus]
916
steps:
1017
- name: Checkout sources
1118
uses: actions/checkout@v3
1219
- uses: actions/[email protected]
1320
with:
14-
node-version: '18.x'
15-
registry-url: 'https://npm.pkg.github.com'
16-
scope: '@paritytech'
17-
- name: Check the licenses
21+
node-version: "18.x"
22+
registry-url: "https://npm.pkg.github.com"
23+
scope: "@paritytech"
24+
- name: Check the licenses for ${{ matrix.repo }}
1825
run: |
1926
shopt -s globstar
20-
21-
npx --yes https://github.com/paritytech/license-scanner scan \
27+
echo "install"
28+
npm install -g @paritytech/[email protected]
29+
echo "run for ${{ matrix.repo }}"
30+
cd ${{ matrix.repo }}
31+
npx @paritytech/license-scanner scan \
2232
--ensure-licenses=Apache-2.0 \
2333
--ensure-licenses=GPL-3.0-only \
2434
./**/*.rs

0 commit comments

Comments
 (0)