diff options
author | xrelkd <46590321+xrelkd@users.noreply.github.com> | 2024-03-16 07:39:40 +0800 |
---|---|---|
committer | xrelkd <46590321+xrelkd@users.noreply.github.com> | 2024-03-16 07:39:40 +0800 |
commit | f2e13524e85a93331109b1ab0051bce57c48ac2f (patch) | |
tree | cbe7d37401be386ffdf2fcf313146ecff8987c21 /pkgs/by-name/jo | |
parent | bfaf0a1feb46a3ef8b17a195d52ee8d4c029e28a (diff) |
joshuto: migrate to by-name
Diffstat (limited to 'pkgs/by-name/jo')
-rw-r--r-- | pkgs/by-name/jo/joshuto/package.nix | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/pkgs/by-name/jo/joshuto/package.nix b/pkgs/by-name/jo/joshuto/package.nix new file mode 100644 index 0000000000000..f2bb672923060 --- /dev/null +++ b/pkgs/by-name/jo/joshuto/package.nix @@ -0,0 +1,43 @@ +{ lib +, rustPlatform +, fetchFromGitHub +, installShellFiles +, stdenv +, darwin +}: + +rustPlatform.buildRustPackage rec { + pname = "joshuto"; + version = "0.9.6"; + + src = fetchFromGitHub { + owner = "kamiyaa"; + repo = "joshuto"; + rev = "v${version}"; + hash = "sha256-d2r8xPGnH/299wjEijilgqy3u/xJgtRmwzJdHt0sA+o="; + }; + + cargoHash = "sha256-amgqoL7NYfl3WzTtgvDoBX46rsL9248rbCis6MHVQhE="; + + nativeBuildInputs = [ installShellFiles ]; + + buildInputs = lib.optionals stdenv.isDarwin [ + darwin.apple_sdk.frameworks.Foundation + ]; + + postInstall = '' + installShellCompletion --cmd joshuto \ + --bash <($out/bin/joshuto completions bash) \ + --zsh <($out/bin/joshuto completions zsh) \ + --fish <($out/bin/joshuto completions fish) + ''; + + meta = with lib; { + description = "Ranger-like terminal file manager written in Rust"; + homepage = "https://github.com/kamiyaa/joshuto"; + changelog = "https://github.com/kamiyaa/joshuto/releases/tag/${src.rev}"; + license = licenses.lgpl3Only; + maintainers = with maintainers; [ figsoda totoroot xrelkd ]; + mainProgram = "joshuto"; + }; +} |