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
51 lines
1.3 KiB
Nix
51 lines
1.3 KiB
Nix
{
|
|
lib,
|
|
fetchFromGitHub,
|
|
installShellFiles,
|
|
php,
|
|
nix-update-script,
|
|
versionCheckHook,
|
|
}:
|
|
|
|
php.buildComposerProject2 (finalAttrs: {
|
|
pname = "castor";
|
|
version = "0.27.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "jolicode";
|
|
repo = "castor";
|
|
tag = "v${finalAttrs.version}";
|
|
hash = "sha256-ot4akuKhNtEXukiDSy69q75phx6EvkJsL0XHAN+el+M=";
|
|
};
|
|
|
|
vendorHash = "sha256-S5NCV3wd/EA282NA0Wbtj7gbZw9YU835cr5CmpAnapc=";
|
|
|
|
nativeBuildInputs = [ installShellFiles ];
|
|
|
|
# install shell completions
|
|
postInstall = ''
|
|
installShellCompletion --cmd castor \
|
|
--bash <(php $out/bin/castor completion bash) \
|
|
--fish <(php $out/bin/castor completion fish) \
|
|
--zsh <(php $out/bin/castor completion zsh)
|
|
'';
|
|
|
|
doInstallCheck = true;
|
|
nativeInstallCheckInputs = [ versionCheckHook ];
|
|
versionCheckProgramArg = "--version";
|
|
|
|
passthru = {
|
|
updateScript = nix-update-script { };
|
|
};
|
|
|
|
meta = {
|
|
broken = lib.versionOlder php.version "8.2";
|
|
changelog = "https://github.com/jolicode/castor/blob/v${finalAttrs.version}/CHANGELOG.md";
|
|
description = "DX oriented task runner and command launcher built with PHP";
|
|
homepage = "https://github.com/jolicode/castor";
|
|
license = lib.licenses.mit;
|
|
maintainers = with lib.maintainers; [ gaelreyrol ];
|
|
mainProgram = "castor";
|
|
};
|
|
})
|