2022-10-25 18:15:42 +00:00
|
|
|
{ lib
|
|
|
|
, rustPlatform
|
|
|
|
, fetchFromGitHub
|
|
|
|
, installShellFiles
|
|
|
|
, stdenv
|
|
|
|
, darwin
|
|
|
|
}:
|
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "sagoin";
|
2023-07-31 20:52:46 +00:00
|
|
|
version = "0.2.3";
|
2022-10-25 18:15:42 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "figsoda";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2023-07-31 20:52:46 +00:00
|
|
|
hash = "sha256-/WNUDlJxxUGAtykX44A9EqMdBNwVKsGkPnq9pATmLEQ=";
|
2022-10-25 18:15:42 +00:00
|
|
|
};
|
|
|
|
|
2023-07-31 20:52:46 +00:00
|
|
|
cargoHash = "sha256-YGQZR5n71srD/8QrBUOoEe72nPm0cwgk5zrzoXy2Hx0=";
|
2022-10-25 18:15:42 +00:00
|
|
|
|
|
|
|
nativeBuildInputs = [ installShellFiles ];
|
|
|
|
|
|
|
|
buildInputs = lib.optionals stdenv.isDarwin [
|
2023-02-20 19:13:52 +00:00
|
|
|
darwin.apple_sdk.frameworks.CoreServices
|
2022-10-25 18:15:42 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
installManPage artifacts/sagoin.1
|
|
|
|
installShellCompletion artifacts/sagoin.{bash,fish} --zsh artifacts/_sagoin
|
|
|
|
'';
|
|
|
|
|
|
|
|
GEN_ARTIFACTS = "artifacts";
|
|
|
|
|
|
|
|
meta = with lib; {
|
2022-11-19 20:50:40 +00:00
|
|
|
description = "A command-line submission tool for the UMD CS Submit Server";
|
2022-10-25 18:15:42 +00:00
|
|
|
homepage = "https://github.com/figsoda/sagoin";
|
|
|
|
changelog = "https://github.com/figsoda/sagoin/blob/v${version}/CHANGELOG.md";
|
|
|
|
license = licenses.agpl3Plus;
|
|
|
|
maintainers = with maintainers; [ figsoda ];
|
2023-11-27 01:17:53 +00:00
|
|
|
mainProgram = "sagoin";
|
2022-10-25 18:15:42 +00:00
|
|
|
};
|
|
|
|
}
|