Make own package for better adaptability #15
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: Publish package to GitHub Packages | |
| on: | |
| push: | |
| branches: | |
| - feat/make-artemis-compatible | |
| jobs: | |
| build: | |
| runs-on: ubuntu-22.04 | |
| permissions: | |
| contents: read | |
| packages: write | |
| steps: | |
| - uses: actions/checkout@v4 | |
| # Setup .npmrc file to publish to GitHub Packages | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| registry-url: 'https://npm.pkg.github.com' | |
| - uses: actions/setup-python@v4 | |
| with: | |
| python-version: '3.11' | |
| - name: Set up .npmrc for publishing | |
| run: | | |
| echo "registry=https://npm.pkg.github.com/" > ~/.npmrc | |
| echo "//npm.pkg.github.com/:_authToken=${NODE_AUTH_TOKEN}" >> ~/.npmrc | |
| echo "@robertjndw:registry=https://npm.pkg.github.com/" >> ~/.npmrc | |
| env: | |
| NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Install root dependencies | |
| run: | | |
| npm install -g node-gyp | |
| npm ci | |
| - name: Build packages | |
| run: | | |
| cd packages/plugin-ext | |
| npm run build | |
| - name: Publish plugin-ext package | |
| run: | | |
| cd packages/plugin-ext | |
| npm publish | |
| env: | |
| NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} |