nixcfg/overlays/unstable/claude-code/update.sh
Harald Hoyer a4d34ea7d1 feat: add package-lock.json for claude-code
Introduced a new `package-lock.json` for the `claude-code` project. This ensures consistent dependency management and locks all required versions for reproducible builds.
2025-05-02 11:16:19 +02:00

16 lines
376 B
Bash
Executable file

#!/usr/bin/env nix-shell
#!nix-shell -i bash -p nodePackages.npm nix-update
set -euo pipefail
version=$(npm view @anthropic-ai/claude-code version)
# Generate updated lock file
cd "$(dirname "${BASH_SOURCE[0]}")"
npm i --package-lock-only @anthropic-ai/claude-code@"$version"
rm -f package.json
# Update version and hashes
cd -
nix-update claude-code --version "$version"