From bc9b7144f984e54319913b3c107fbfb4b4a02137 Mon Sep 17 00:00:00 2001 From: Brant Burnett Date: Mon, 27 Nov 2023 12:51:25 +0000 Subject: [PATCH] Collect artifacts on PRs --- .devcontainer/devcontainer.json | 1 + .github/workflows/build.yml | 16 +++++++++++++++- 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index a45a5d2..db2aab8 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -14,6 +14,7 @@ "extensions": [ "dbaeumer.vscode-eslint", "orta.vscode-jest", + "github.vscode-github-actions", "github.vscode-pull-request-github", "ms-azuretools.vscode-docker" ] diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index eb25e54..9b43bd3 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -67,4 +67,18 @@ jobs: pushd packages/couchbase-index-manager && npm publish && popd && pushd packages/couchbase-index-manager-cli && npm publish && popd env: - NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} \ No newline at end of file + NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} + + - name: Pack NPM + if: ${{!startsWith(github.ref, 'refs/tags/')}} # Only on non-tags + run: | + pushd packages/couchbase-index-manager && npm pack && popd && + pushd packages/couchbase-index-manager-cli && npm pack && popd + - name: Archive + if: ${{!startsWith(github.ref, 'refs/tags/')}} # Only on non-tags + uses: actions/upload-artifact@v3 + with: + name: npm-packages + path: | + packages/couchbase-index-manager/*.tgz + packages/couchbase-index-manager-cli/*.tgz