17 stdenv.mkDerivation rec {
18 pname = "taskwarrior";
20 src = fetchFromGitHub {
21 owner = "GothenburgBitFactory";
24 hash = "sha256-iKpOExj1xM9rU/rIcOLLKMrZrAfz7y9X2kt2CjfMOOQ=";
25 fetchSubmodules = true;
29 substituteInPlace src/commands/CmdNews.cpp \
30 --replace "xdg-open" "${lib.getBin xdg-utils}/bin/xdg-open"
42 rustPlatform.cargoSetupHook
44 ++ lib.optionals stdenv.hostPlatform.isDarwin [
46 darwin.apple_sdk.frameworks.Security
47 darwin.apple_sdk.frameworks.SystemConfiguration
51 checkTarget = "build_tests";
53 cargoDeps = rustPlatform.fetchCargoTarball {
54 name = "${pname}-${version}-cargo-deps";
56 sourceRoot = src.name;
57 hash = "sha256-L+hYYKXSOG4XYdexLMG3wdA7st+A9Wk9muzipSNjxrA=";
61 export CMAKE_PREFIX_PATH="${corrosion}:$CMAKE_PREFIX_PATH"
65 # ZSH is installed automatically from some reason, only bash and fish need
67 installShellCompletion --cmd task \
68 --bash $out/share/doc/task/scripts/bash/task.sh \
69 --fish $out/share/doc/task/scripts/fish/task.fish
70 rm -r $out/share/doc/task/scripts/bash
71 rm -r $out/share/doc/task/scripts/fish
72 # Install vim and neovim plugin
73 mkdir -p $out/share/vim-plugins
74 mv $out/share/doc/task/scripts/vim $out/share/vim-plugins/task
75 mkdir -p $out/share/nvim
76 ln -s $out/share/vim-plugins/task $out/share/nvim/site
79 passthru.tests.nixos = nixosTests.taskchampion-sync-server;
82 changelog = "https://github.com/GothenburgBitFactory/taskwarrior/blob/${src.rev}/ChangeLog";
83 description = "Highly flexible command-line tool to manage TODO lists";
84 homepage = "https://taskwarrior.org";
85 license = lib.licenses.mit;
86 maintainers = with lib.maintainers; [
93 platforms = lib.platforms.unix;