From 73567b5346b9af88655e2b0db24b1bd460c91fe1 Mon Sep 17 00:00:00 2001 From: Yigit Sever Date: Sat, 6 Apr 2019 16:11:35 +0300 Subject: Fix focus script task name length constraint --- .config/polybar/focus | 11 ++++++----- .taskrc | 6 ++++++ 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/.config/polybar/focus b/.config/polybar/focus index 0cccea4..8eeb92a 100755 --- a/.config/polybar/focus +++ b/.config/polybar/focus @@ -19,9 +19,9 @@ use strict; use warnings; use IO::CaptureOutput qw/capture_exec/; -my ($stdout, $stderr, $success, $exit_code) = capture_exec("task active"); +my ($stdout, $stderr, $success, $exit_code) = capture_exec("task custom_focus"); -#print("out: $stdout\nerr: $stderr\nexit_code: $exit_code\n"); +# print("out: $stdout\nerr: $stderr\nexit_code: $exit_code\n"); if ($stderr =~ /No matches\./) { system 'echo "What a beautiful day"'; @@ -37,6 +37,7 @@ my $task = $lines[2]; $task =~ s/^\s+|\s+$//g; $task =~ s/\s+/ /g; -if ($task =~ m/.*?next (.*)$/) { - print "$1"; -} +# if ($task =~ m/.*?next (.*)$/) { +# print "$1"; +# } +print $task; diff --git a/.taskrc b/.taskrc index c7a4112..f86bb63 100644 --- a/.taskrc +++ b/.taskrc @@ -58,6 +58,12 @@ report.todoConky.sort = due+ report.todoConky.filter = status:pending and due.after:now and due.before:later report.todoConky.dateformat = D-M-y H:N (A) +### report for focus script +report.custom_focus.columns = description +report.custom_focus.labels = Description +report.custom_focus.description = Task to feed to focus script +report.custom_focus.filter = status:pending and +ACTIVE + ### contexts context.home = +@home or +@online context.work = +@work or +@online -- cgit v1.2.3-70-g09d2