diff options
| author | Benedikt Peetz <benedikt.peetz@b-peetz.de> | 2026-08-22 21:09:14 +0200 |
|---|---|---|
| committer | Benedikt Peetz <benedikt.peetz@b-peetz.de> | 2026-08-22 21:09:14 +0200 |
| commit | 2507bb0a7713d7d534a18812e2ed4247cff43325 (patch) | |
| tree | 6596ae9d9904b9caa19f69db866cdd5aaedfd1ac /nix/package.nix | |
| parent | feat: Finalize design for fish-shell integration (diff) | |
| download | atuin-2507bb0a7713d7d534a18812e2ed4247cff43325.zip | |
fix(nix): Update all references and switch build to crane
Diffstat (limited to '')
| -rw-r--r-- | nix/package.nix | 28 |
1 files changed, 16 insertions, 12 deletions
diff --git a/nix/package.nix b/nix/package.nix index 3fd24aee..1f4d5498 100644 --- a/nix/package.nix +++ b/nix/package.nix @@ -8,11 +8,11 @@ lib, stdenv, installShellFiles, - rustPlatform, libiconv, + craneLib, }: -rustPlatform.buildRustPackage { - name = "turtle"; +craneLib.buildPackage { + pname = "turtle"; version = "19.0.0"; src = lib.cleanSourceWith { @@ -36,21 +36,25 @@ rustPlatform.buildRustPackage { || (lib.strings.hasSuffix ".sql" (builtins.baseNameOf name)); }; - cargoLock = { - lockFile = ../Cargo.lock; - # Allow dependencies to be fetched from git and avoid having to set the outputHashes manually - allowBuiltinFetchGit = true; + env = { + CARGO_PROFILE = "dev"; }; + # cargoLock = { + # lockFile = ../Cargo.lock; + # # Allow dependencies to be fetched from git and avoid having to set the outputHashes manually + # allowBuiltinFetchGit = true; + # }; + nativeBuildInputs = [installShellFiles]; buildInputs = lib.optionals stdenv.isDarwin [libiconv]; postInstall = '' - installShellCompletion --cmd atuin \ - --bash <($out/bin/atuin gen-completions -s bash) \ - --fish <($out/bin/atuin gen-completions -s fish) \ - --zsh <($out/bin/atuin gen-completions -s zsh) + installShellCompletion --cmd turtle \ + --bash <($out/bin/turtle gen-completions -s bash) \ + --fish <($out/bin/turtle gen-completions -s fish) \ + --zsh <($out/bin/turtle gen-completions -s zsh) ''; doCheck = false; @@ -59,6 +63,6 @@ rustPlatform.buildRustPackage { description = "Replacement for a shell history which records additional commands context with optional encrypted synchronization between machines"; homepage = "https://github.com/atuinsh/atuin"; license = licenses.mit; - mainProgram = "atuin"; + mainProgram = "turtle"; }; } |
