diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b8b9467..318ff6b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -22,35 +22,3 @@ jobs: - name: Build run: yarn build - - deploy-page: - needs: build - runs-on: ubuntu-latest - - environment: - name: github-pages - url: ${{ steps.deployment.outputs.page_url }} - - defaults: - run: - working-directory: gh-pages - - permissions: - contents: read - pages: write - id-token: write - - steps: - - uses: actions/checkout@v4 - - - name: Install + Build - run: docker-compose up page-build - - - name: Upload artifact - uses: actions/upload-pages-artifact@v1 - with: - path: gh-pages/out - - - name: Deploy to GitHub Pages - id: deployment - uses: actions/deploy-pages@v2 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 3ec5bbd..146b050 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -91,14 +91,26 @@ jobs: steps: - uses: actions/checkout@v4 + - name: Wait for npm package to be available + run: | + PACKAGE_NAME="@ifrc-go/icons" + PACKAGE_VERSION=$(cat package.json | grep version | grep -oP "(\d+\.)?(\d+\.)?(\*|\d+)") + + # Loop until the package is available in the registry + while [[ -z $(npm show "$PACKAGE_NAME@$PACKAGE_VERSION" version) ]]; do + echo "Waiting for npm package to be available..." + sleep 20 # Adjust the interval as needed + done + echo "npm package is available!" + - name: Install + Build run: docker-compose up page-build - name: Upload artifact - uses: actions/upload-pages-artifact@v1 + uses: actions/upload-pages-artifact@v3 with: path: gh-pages/out - name: Deploy to GitHub Pages id: deployment - uses: actions/deploy-pages@v2 + uses: actions/deploy-pages@v4 diff --git a/gh-pages/package.json b/gh-pages/package.json index a18be78..cdd9242 100644 --- a/gh-pages/package.json +++ b/gh-pages/package.json @@ -10,7 +10,7 @@ "lint": "next lint" }, "dependencies": { - "@ifrc-go/icons": "^1.3.1", + "@ifrc-go/icons": "^1.3.2", "@types/node": "20.2.5", "@types/react": "18.2.7", "@types/react-dom": "18.2.4", diff --git a/package.json b/package.json index 967202b..a42ea0a 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@ifrc-go/icons", - "version": "1.3.1", + "version": "1.3.2", "description": "IFRC-GO icons library for React.", "keywords": [ "ifrc-go",