From b27075882c700440a8ea4d1726ce77ad1c1c974f Mon Sep 17 00:00:00 2001 From: Claudia Date: Wed, 7 Aug 2024 23:36:04 +0200 Subject: [PATCH 1/3] feat: add script --- .github/workflows/artifacts-build.yml | 38 +++++++++++++++++++++++++++ artifacts/package.json | 2 +- 2 files changed, 39 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/artifacts-build.yml diff --git a/.github/workflows/artifacts-build.yml b/.github/workflows/artifacts-build.yml new file mode 100644 index 00000000..07c83de1 --- /dev/null +++ b/.github/workflows/artifacts-build.yml @@ -0,0 +1,38 @@ +name: Artifacts build + +on: + push: + branches: + - main + - develop + pull_request: + paths: + - 'artifacts/**' + - '.github/workflows/artifacts-*.yml' + workflow_dispatch: + workflow_call: + +jobs: + formatting-linting: + uses: ./.github/workflows/formatting-linting.yml + tests: + runs-on: 'ubuntu-latest' + defaults: + run: + working-directory: artifacts + steps: + - name: 'Check out the repo' + uses: 'actions/checkout@v3' + + - name: 'Install Node.js' + uses: 'actions/setup-node@v3' + with: + cache: 'yarn' + node-version: 18 + + - name: 'Install the dependencies' + run: 'yarn install --frozen-lockfile' + + - name: 'Build the artifacts' + run: 'yarn build' +s \ No newline at end of file diff --git a/artifacts/package.json b/artifacts/package.json index 294d44c9..6146b5dc 100644 --- a/artifacts/package.json +++ b/artifacts/package.json @@ -13,7 +13,7 @@ "access": "public" }, "scripts": { - "build": "tsc", + "build": "tsc -p tsconfig.json", "generate": "sh generateAbis.sh" }, "engines": { From 433ac748b808460a879cad63811e8f85eb3cb60b Mon Sep 17 00:00:00 2001 From: Claudia Date: Wed, 7 Aug 2024 23:38:00 +0200 Subject: [PATCH 2/3] fix typo --- .github/workflows/artifacts-build.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/artifacts-build.yml b/.github/workflows/artifacts-build.yml index 07c83de1..055ce612 100644 --- a/.github/workflows/artifacts-build.yml +++ b/.github/workflows/artifacts-build.yml @@ -35,4 +35,3 @@ jobs: - name: 'Build the artifacts' run: 'yarn build' -s \ No newline at end of file From cf1b94481cee6047417e1b99746196525421f637 Mon Sep 17 00:00:00 2001 From: Claudia Date: Wed, 7 Aug 2024 23:53:44 +0200 Subject: [PATCH 3/3] fix: remove package name from the version --- .github/workflows/reusable-check-tag.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/reusable-check-tag.yml b/.github/workflows/reusable-check-tag.yml index 8f459dd7..2ad17b63 100644 --- a/.github/workflows/reusable-check-tag.yml +++ b/.github/workflows/reusable-check-tag.yml @@ -31,7 +31,7 @@ jobs: run: | GITHUB_REF="${{ inputs.ref }}" TAG=${GITHUB_REF##*/} - VERSION=$(echo "$TAG" | sed -E 's/-(sdk|subgraph|contracts|configs)//') + VERSION=$(echo "$TAG" | sed -E 's/-(sdk|subgraph|contracts|configs|artifacts)//') PACKAGE=${TAG##*-} echo "package=$PACKAGE" >> $GITHUB_OUTPUT echo "version=$VERSION" >> $GITHUB_OUTPUT