Merge pull request #519 from sm1990/icons1 #226
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # ------------------------------------------------------------------------------------- | |
| # | |
| # Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com). | |
| # | |
| # WSO2 LLC. licenses this file to you under the Apache License, | |
| # Version 2.0 (the "License"); you may not use this file except | |
| # in compliance with the License. | |
| # You may obtain a copy of the License at | |
| # | |
| # http://www.apache.org/licenses/LICENSE-2.0 | |
| # | |
| # Unless required by applicable law or agreed to in writing, | |
| # software distributed under the License is distributed on an | |
| # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | |
| # KIND, either express or implied. See the License for the | |
| # specific language governing permissions and limitations | |
| # under the License. | |
| # | |
| # -------------------------------------------------------------------------------------- | |
| # This workflow will release the packages. | |
| name: π Release | |
| on: | |
| push: | |
| branches: [main] | |
| paths-ignore: | |
| - 'LICENSE' | |
| workflow_dispatch: | |
| # Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages | |
| permissions: | |
| contents: read | |
| pages: write | |
| id-token: write | |
| concurrency: ${{ github.workflow }}-${{ github.ref }} | |
| env: | |
| GH_TOKEN: ${{ secrets.UI_BOT_TOKEN }} | |
| NPM_TOKEN: ${{ secrets.WSO2_NPM_TOKEN }} | |
| jobs: | |
| release: | |
| name: π¦ Release | |
| if: "!contains(github.event.head_commit.message, 'ci skip') && !contains(github.event.head_commit.message, 'skip ci')" | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| node-version: [lts/*] | |
| pnpm-version: [latest] | |
| steps: | |
| - name: β¬οΈ Checkout | |
| id: checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| token: ${{ env.GH_TOKEN }} | |
| - name: π₯‘ Setup pnpm | |
| uses: pnpm/action-setup@v4 | |
| with: | |
| version: ${{ matrix.pnpm-version }} | |
| run_install: false | |
| cache: true | |
| cache-dependency-path: pnpm-lock.yaml | |
| - name: π’ Setup node | |
| id: setup-node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: ${{ matrix.node-version }} | |
| cache: 'pnpm' | |
| - name: π§© Install Dependencies | |
| id: install-dependencies | |
| run: pnpm install --frozen-lockfile | |
| - name: ποΈ Build | |
| id: build | |
| run: pnpm build | |
| - name: π£ Create Release Pull Request or Publish to npm | |
| id: changesets | |
| uses: changesets/action@v1.4.9 | |
| with: | |
| title: '[Release] [GitHub Action] Update package versions' | |
| publish: pnpm publish:packages | |
| version: pnpm version:packages | |
| commit: "[WSO2 Release] [GitHub Action] [Release] [${{ github.ref_name }}] [skip ci] update package versions" | |
| env: | |
| NPM_TOKEN: ${{ env.NPM_TOKEN }} | |
| GITHUB_TOKEN: ${{ env.GH_TOKEN }} | |
| - name: βοΈ Setup Pages to Deploy Documentation | |
| if: steps.changesets.outputs.published == 'true' | |
| id: setup-pages | |
| uses: actions/configure-pages@v5 | |
| - name: π© Upload Documentation Artifact | |
| if: steps.changesets.outputs.published == 'true' | |
| id: upload-artifact | |
| uses: actions/upload-pages-artifact@v3 | |
| with: | |
| path: ./packages/oxygen-ui-docs/dist | |
| - name: π₯ Deploy to GitHub Pages | |
| if: steps.changesets.outputs.published == 'true' | |
| id: deploy-gh-pages | |
| uses: actions/deploy-pages@v4 |