Android Version Code 1.0.1 (#114) #28
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
| name: Release | |
| on: | |
| push: | |
| branches: | |
| - main | |
| permissions: | |
| contents: write | |
| pull-requests: write | |
| id-token: write | |
| jobs: | |
| release: | |
| name: Release | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout Repo | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '24' | |
| registry-url: 'https://registry.npmjs.org' | |
| cache: 'npm' | |
| - name: Install Dependencies | |
| run: npm ci | |
| - name: Run Tests | |
| run: npm run test | |
| # This is requried to run before lint check in the ditto-chat-ui package | |
| # else lint will fail due to missing types from ditto-chat-core dist | |
| - name: Build Ditto Chat Core | |
| run: npm run build --workspace=sdks/js/ditto-chat-core | |
| - name: Run Linting | |
| run: npm run lint | |
| - name: Build Packages | |
| run: npm run build | |
| - name: Create Release Pull Request or Publish to NPM | |
| id: changesets | |
| uses: changesets/action@v1 | |
| with: | |
| publish: npm run release | |
| version: npm run version-packages | |
| commit: 'chore: npm packages version bump' | |
| title: 'chore: npm packages version bump' | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Publish Summary | |
| if: steps.changesets.outputs.published == 'true' | |
| run: | | |
| echo "## 📦 Published Packages" >> $GITHUB_STEP_SUMMARY | |
| echo "" >> $GITHUB_STEP_SUMMARY | |
| echo '${{ steps.changesets.outputs.publishedPackages }}' | jq -r '.[] | "- **\(.name)@\(.version)**"' >> $GITHUB_STEP_SUMMARY |