Skip to content

Commit

Permalink
Fix npm version not running
Browse files Browse the repository at this point in the history
  • Loading branch information
klarkc committed Jul 11, 2024
1 parent 99d7846 commit b726047
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@ jobs:
name: klarkc
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'
- run: |
nix build
nix build .#npm
mkdir -p dist
cp result/bin/purs-eval dist
cp result dist/purs-eval
if: ${{ steps.release.outputs.release_created }}
- uses: actions/setup-node@v4
if: ${{ steps.release.outputs.release_created }}
Expand Down
9 changes: 8 additions & 1 deletion flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -71,9 +71,16 @@
};

packages =
with ps;
{
default = app { inherit name; };
# npm version does not publish a nix-store path
npm = pkgs.runCommand
"purs-eval-npm"
{}
''
echo "#!/usr/bin/env node" > $out
tail -n +2 ${packages.default}/bin/purs-eval >> $out
'';
};

checks.test = test.check { };
Expand Down

0 comments on commit b726047

Please sign in to comment.