Files
nixpkgs/pkgs/by-name/th/the-way/package.nix
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

48 lines
1.2 KiB
Nix

{
lib,
stdenv,
rustPlatform,
fetchFromGitHub,
installShellFiles,
}:
rustPlatform.buildRustPackage rec {
pname = "the-way";
version = "0.20.3";
src = fetchFromGitHub {
owner = "out-of-cheese-error";
repo = "the-way";
tag = "v${version}";
hash = "sha256-zsfk5APxbnssMKud9xGc70N+57LSc+vk6sSb2XzFUyA=";
};
cargoHash = "sha256-GBr0z2iJuk86xkgZd2sAz+ISTRfESDt99g6ssxXhzhI=";
nativeBuildInputs = [ installShellFiles ];
doCheck = !stdenv.hostPlatform.isDarwin;
useNextest = true;
postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
$out/bin/the-way config default tmp.toml
for shell in bash fish zsh; do
THE_WAY_CONFIG=tmp.toml $out/bin/the-way complete $shell > the-way.$shell
installShellCompletion the-way.$shell
done
'';
meta = {
description = "Terminal code snippets manager";
mainProgram = "the-way";
homepage = "https://github.com/out-of-cheese-error/the-way";
changelog = "https://github.com/out-of-cheese-error/the-way/blob/v${version}/CHANGELOG.md";
license = with lib.licenses; [ mit ];
platforms = lib.platforms.unix;
maintainers = with lib.maintainers; [
figsoda
numkem
];
};
}