[Ml-yokadi] Using '_' as a shortcut to last task id

Sébastien Renard Sebastien.Renard at digitalfox.org
Wed Sep 16 19:21:32 CEST 2009


Le samedi 12 septembre 2009 12:49:02, Sébastien Renard a écrit :
> Le mardi 1 septembre 2009 16:45:20, Aurélien Gâteau a écrit :
> > Hi,
> >
> > Please find attached patches implementing '_' as a shortcut to last task
> > id. This means you can do:
> >
> >   yokadi> t_add home Buy chocolate
> >   Added task 'Buy chocolate' (id=1069)
> >
> >   yokadi> t_edit _
> >
> > To edit last task.
> >
> > It should work in all task-related commands (please report if you find a
> > missing command). I choose '_' because Python interpreter use the same
> > symbol for the same purpose.
> >
> > What do you think about this?
>
> Looks like perl ;-).
>
> Seriously, it is a good feature. Please push it.

Well, after reading your patch I have a concern about the global variable 
lastTaskId. As this information is tightly related to shell context, why don't 
simply add it as a YokadiCmd member ?
We already have some variable like this (I think to prompt).

-- 
Sébastien


More information about the Ml-yokadi mailing list