Reaktor taskwarrior: touch if no taskrc exists
This commit is contained in:
parent
70e8c4b0a4
commit
d6df7ae483
|
@ -143,9 +143,15 @@ rec {
|
||||||
|
|
||||||
taskwarrior = buildSimpleReaktorPlugin "task" {
|
taskwarrior = buildSimpleReaktorPlugin "task" {
|
||||||
pattern = "^task: (?P<args>.*)$$";
|
pattern = "^task: (?P<args>.*)$$";
|
||||||
script = pkgs.writeDash "task-wrapper" ''
|
script = let
|
||||||
${pkgs.taskwarrior}/bin/task "$*"
|
taskrc = "$HOME/.taskrc";
|
||||||
'';
|
in
|
||||||
|
pkgs.writeDash "task-wrapper" ''
|
||||||
|
if [ -f ${taskrc} ] ; then
|
||||||
|
touch ${taskrc}
|
||||||
|
fi
|
||||||
|
${pkgs.taskwarrior}/bin/task "$*"
|
||||||
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
todo = name: {
|
todo = name: {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user