djacu is releasing a new version of the branding npm package #1
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 NixOS Branding npm package | |
| run-name: ${{ github.actor }} is releasing a new version of the branding npm package | |
| on: | |
| workflow_call: | |
| workflow_dispatch: | |
| jobs: | |
| build-npm-package: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| packages: write | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: "latest" | |
| registry-url: "https://npm.pkg.github.com" | |
| scope: "@octocat" | |
| - name: Install Nix | |
| uses: cachix/install-nix-action@v31 | |
| - name: Build npm package | |
| run: | | |
| nix build .\#nixos-branding.npm-package \ | |
| --print-build-logs \ | |
| --out-link result-npm-package | |
| mkdir --parents ./build | |
| cp --recursive --dereference ./result-npm-package/* ./build | |
| - name: Publish npm package | |
| run: npm publish | |
| working-directory: ./build | |
| env: | |
| NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} |