From 3cc8cda5f795deee20b27ead340efe886fab55af Mon Sep 17 00:00:00 2001 From: Andrew Williams Date: Wed, 28 Dec 2022 13:39:35 +0000 Subject: [PATCH] Matrix build the plugins --- .github/workflows/build.yml | 46 ++++++++++++++++++++++++++----------- 1 file changed, 33 insertions(+), 13 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 7000271..64693c4 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -5,19 +5,39 @@ on: branches: - main jobs: + find-extensions: + name: Find Extensions + runs-on: ubuntu-latest + outputs: + folders: ${{ steps.jobs.outputs.folders }} + steps: + - uses: actions/checkout@v1 + - id: extensions + uses: philips-labs/list-folders-action@v1 + with: + path: ./src + build-extensions: runs-on: ubuntu-latest + needs: + - find-jobs + defaults: + run: + working-directory: ${{ matrix.folder }} + strategy: + matrix: + folder: ${{ fromJson(needs.find-jobs.outputs.folders )}} steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 16 - - name: Run 'make build' - run: make build - shell: bash - - name: Upload plugins - uses: actions/upload-artifact@v3 - with: - name: dist-without-markdown - path: | - dist/* \ No newline at end of file + - uses: actions/checkout@v3 + - uses: actions/setup-node@v3 + with: + node-version: 16 + cache: npm + - name: Run 'make build' + run: npm run --prefix build ../dist + shell: bash + - name: Upload plugins + uses: actions/upload-artifact@v3 + with: + path: | + dist/${{ matrix.folder }}*.tgz \ No newline at end of file