* added manpage.
* popup error dialog when .taskrc does not exist.
* added --debug.
- * supported version of taskwarrior is 2.2.0.
+ * supported versions of taskwarrior are 2.2.0 and 2.0.0.
* added taskwarrior version checking.
- * added .taskrc check (must exist).
+ * added support for taskwarrior 2.2.0 (avoid confirmation query).
v0.0.3
------
</li>\r
<li>\r
<p>\r
-supported version of taskwarrior is 2.2.0.\r
+supported versions of taskwarrior are 2.2.0 and 2.0.0.\r
</p>\r
</li>\r
<li>\r
</li>\r
<li>\r
<p>\r
-added .taskrc check (must exist).\r
+added support for taskwarrior 2.2.0 (avoid confirmation query).\r
</p>\r
</li>\r
</ul></div>\r
<div id="footnotes"><hr /></div>\r
<div id="footer">\r
<div id="footer-text">\r
-Last updated 2013-10-19 12:04:17 CEST\r
+Last updated 2013-10-19 15:48:52 CEST\r
</div>\r
</div>\r
</body>\r
Report bugs to <jeanfi@gmail.com>.
ptask home page: <http://wpitchoune.net/ptask>."
-ac_cs_config=""
+ac_cs_config="'--prefix=/tmp'"
ac_cs_version="\
ptask config.status 0.0.x
configured by ./configure, generated by GNU Autoconf 2.69,
fi
if $ac_cs_recheck; then
- set X /bin/bash './configure' $ac_configure_extra_args --no-create --no-recursion
+ set X /bin/bash './configure' '--prefix=/tmp' $ac_configure_extra_args --no-create --no-recursion
shift
$as_echo "running CONFIG_SHELL=/bin/bash $*" >&6
CONFIG_SHELL='/bin/bash'
S["sbindir"]="${exec_prefix}/sbin"
S["bindir"]="${exec_prefix}/bin"
S["program_transform_name"]="s,x,x,"
-S["prefix"]="/usr/local"
+S["prefix"]="/tmp"
S["exec_prefix"]="${prefix}"
S["PACKAGE_URL"]="http://wpitchoune.net/ptask"
S["PACKAGE_BUGREPORT"]="jeanfi@gmail.com"
top_srcdir = ..
-prefix = /usr/local
+prefix = /tmp
exec_prefix = ${prefix}
datarootdir = ${prefix}/share
datadir = ${datarootdir}
top_srcdir = ..
-prefix = /usr/local
+prefix = /tmp
exec_prefix = ${prefix}
datarootdir = ${prefix}/share
datadir = ${datarootdir}
GTK_BUTTONS_CLOSE,
_("Error loading tasks, verify "
"that a supported version of "
- "taskwarrior is installed "
- "and its configuration file "
- "exist."
- ));
+ "taskwarrior is installed "));
gtk_dialog_run(GTK_DIALOG(dialog));
gtk_widget_destroy(dialog);
}
#include <pstr.h>
#include "tw.h"
-
-static int has_taskrc()
-{
- char *home, *path;
- int ret;
- struct stat st;
-
- home = getenv("HOME");
-
- if (!home) {
- log_err("HOME environment variable not defined");
- return 0;
- }
-
- path = malloc(strlen(home) + 1 + strlen(".taskrc") + 1);
- sprintf(path, "%s/%s", home, ".taskrc");
-
- ret = lstat(path, &st);
-
- free(path);
-
- return ret == 0;
-}
-
static char *task_exec(char *opts)
{
FILE *f;
log_debug("task version: %s", ver);
- if (!strcmp(ver, "2.2.0"))
+ if (!strcmp(ver, "2.2.0") || !strcmp(ver, "2.0.0"))
return 1;
else
return 0;
static char *tw_exec(char *opts)
{
- if (!has_taskrc())
- return NULL;
+ char *opts2;
if (!task_check_version()) {
log_err("ptask is not compatible with the installed version of"
return NULL;
}
- return task_exec(opts);
+ opts2 = malloc(strlen("rc.confirmation:no ")
+ + strlen(opts)
+ + 1);
+ strcpy(opts2, "rc.confirmation:no ");
+ strcat(opts2, opts);
+
+ return task_exec(opts2);
}
static struct json_object *task_exec_json(char *opts)