pimutils / todoman Goto Github PK
View Code? Open in Web Editor NEW✅ A simple, standards-based, cli todo (aka: task) manager.
Home Page: https://todoman.readthedocs.io
License: ISC License
✅ A simple, standards-based, cli todo (aka: task) manager.
Home Page: https://todoman.readthedocs.io
License: ISC License
We currently don't test anything from the interactive UI because it's too hard. But it would be interesting what testing would look like. See #94 for a very recent example of where this became a problem
This issue was moved from the issue tracker at GitLab.
Increment the sequence number every time the file is modified/save.
SEQUENCE
LAST-MODIFIED
This issue was moved from the issue tracker at GitLab.
todoman should show the CATEGORIES assigned to a task.
i.e. the following task contains the "Online" category:
$ cat 9fe6d194-24e2-46cf-a600-faad711f9f20.ics
BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//Mozilla.org/NONSGML Mozilla Calendar V1.1//EN
BEGIN:VTIMEZONE
TZID:Europe/Berlin
X-LIC-LOCATION:Europe/Berlin
BEGIN:DAYLIGHT
TZOFFSETFROM:+0100
TZOFFSETTO:+0200
TZNAME:CEST
DTSTART:19700329T020000
RRULE:FREQ=YEARLY;BYDAY=-1SU;BYMONTH=3
END:DAYLIGHT
BEGIN:STANDARD
TZOFFSETFROM:+0200
TZOFFSETTO:+0100
TZNAME:CET
DTSTART:19701025T030000
RRULE:FREQ=YEARLY;BYDAY=-1SU;BYMONTH=10
END:STANDARD
END:VTIMEZONE
BEGIN:VTODO
CREATED:20150414T065645Z
LAST-MODIFIED:20150414T065820Z
DTSTAMP:20150414T065820Z
UID:9fe6d194-24e2-46cf-a600-faad711f9f20
SUMMARY:Todoman Testtask
PRIORITY:1
STATUS:NEEDS-ACTION
CATEGORIES:Online
X-MOZ-LASTACK:20150414T065807Z
DTSTART;TZID=Europe/Berlin:20150414T090000
DUE;TZID=Europe/Berlin:20150428T090000
LOCATION:Location
PERCENT-COMPLETE:20
DESCRIPTION:Description \n\nHello World
SEQUENCE:1
X-MOZ-GENERATION:3
X-MOZ-SNOOZE-TIME:20150415T065807Z
BEGIN:VALARM
ACTION:DISPLAY
TRIGGER;VALUE=DURATION:-PT15M
DESCRIPTION:Default Mozilla Description
END:VALARM
END:VTODO
END:VCALENDAR
but todoman doesn't show it:
$ todo show 22
Todoman Testtask
Due: 2015-04-28 Urgent
Description
Hello World
Was setting up todoman and reading through the documentation which suggests to use
# A glob expression which matches all directories relevant.
path = ~/.local/share/calendars/*
Using the glob expression results in no available lists, removing the star helps.
For eg.: if I run todo new "Go to Zeba's Birthday Party
, it throws up an error saying:
Usage: todo new [OPTIONS] [SUMMARY]...
Error: Invalid value for "--list" / "-l": Personal. Available lists are:
There are no lists available, do I need to create it manually?
If there's no configuration file, offer to help create one:
Save show the configuration file, and confirm save/not save.
There is no sample configuration file in configure.rst though there is an heading for the former!
This issue was moved from the issue tracker at GitLab.
When I use todoman to mark repeating reminders "done", the repeating reminders disappear entirely, and are not rescheduled.
I am using todoman version 1.5.2.
This issue was moved from the issue tracker at GitLab.
Todoman currently has no way of emitting warnings, and a possibility to turn those warnings on and off. Warnings will probably be required for reporting invalid items (the current behavior is basically to ignore those, because logging handlers are not set up properly)
I'd like to rip out some code from vdirsyncer and pallets/click#278, and make a third-party package on click-contrib to provide such things. I think I'll have to wait for Click 5.0 before implementing this though.
Hi
I think you should change the terminal output by the command "todo new" from
Usage: todo new [options] [summary]
to
Usage: todo new [options: --list [list number]] [summary]
``
setuptools_scm
is listed in requirements.txt
.
This usually is just a build dependency, but due to being listed there, it is needed at runtime. Is this correct? If not, please remove it, or mark it build-only if that's possible.
time_format
configuration parameter that, if non-empty, is additionally used to format due datetimes. It should be omitted if DUE
does not have a time component.%H
, %Mand so on in
date_format` (I'm currently doing that)%Y
etc in time_format
I don't really see the need for having this option in the editor too, since the CLI has this option already.
Use a cache for:
id
s to showSince dates are stored as strings in sqlite, timezones aren't taking properly accounted for when comparing datetimes. (this was revealed by df24af8)
I'd like to evaluate humanizing all date times (probably with humanize).
-h/--humanize
flag.We'd have to look at pitfalls, and potential issues that may be a bit non-obvious.
This issue was moved from the issue tracker at GitLab.
todo list
should be able to filter a timerange, i.e.:
todo list --start="before 2015-10-12"
todo list --due="before 2015-10-16"
like thunderbird lightning, pre-configured timerange filters would be handy:
todo list --timerange=current
todo list --timerange=today
todo list --timerange=7days
todo list --timerange=overdue
todo list --timerange=not_started
i don't know if it's better to implement a special timerange filter, or a more generic filter that can be preconfigured, which could filter by other things as well like lighning:
todo list filter=completed
todo list filter=incomplete
customizing those filters would be supreme :D
Since an edited todo is removed from the cache and re-inserted, it's id changes (but we never have id re-use). Maybe we should avoid this (if possible).
Actual behavior
When running for the first time or when there are no lists, the todo
command outputs nothing. This is very counter-intuitive and may confuse the users.
Expected behavior
When there are no lists, a warning should be displayed saying the same and a suggestion to display help should be shown.
I would like to work on this issue. Can I send a PR?
When a todo expires today, or tomorrow, show "today" or "tomorrow" respectively instead of the actual date.
This issue was moved from the issue tracker at GitLab.
todo list
should be able to filter by priority, i.e.:
todo list --priority=high,medium
or
todo list --priority=!low
todo list --urgent
partially covers this. Further support requires supporting more granular priorities.
Install, copy or print a sample configuration. Or maybe link to the docs in case of a missing one? Open an editor?
todo list
still shows old tasklistsI'll have to figure out what's going on there.
v1.6.0 was broken and pulled back. Master has been fixed, and v1.6.1 needs to be published.
Publishing v1.6.1 failed due to a pypi error, reported here.
While working on #30, I saw that todoman just passes the raw configparser through the CLI. I think it would be better if there was a dedicated Config type that has all valid params as properties (which raise if somebody tries to set an invalid value).
khal uses ConfigObj for this.
I just cloned the repo and run the tests and flake8 is failing on https://github.com/pimutils/todoman/blob/master/todoman/model.py#L476
My terminal shows the following:
flake8 installed: appdirs==1.4.0,configparser==3.5.0,enum34==1.1.6,flake8==3.3.0,flake8-import-order==0.12,mccabe==0.6.1,packaging==16.8,pycodestyle==2.3.1,pyflakes==1.5.0,pyparsing==2.1.10,six==1.10.0,todoman==2.1.0.post13+ng96016ff
flake8 runtests: PYTHONHASHSEED='2330703630'
flake8 runtests: commands[0] | flake8
./todoman/model.py:476:42: E999 SyntaxError: invalid syntax
ERROR: InvocationError: '/Users/mkaur/Sites/todoman/.tox/flake8/bin/flake8'
I installed todoman
yesterday (version 1.6.0); after getting it to read my vdir
the list
command fails to list my todos; it throws
Traceback (most recent call last):
File "/usr/local/bin/todo", line 11, in <module>
sys.exit(cli())
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 716, in __call__
return self.main(*args, **kwargs)
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 696, in main
rv = self.invoke(ctx)
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 1037, in invoke
return Command.invoke(self, ctx)
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 889, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 534, in invoke
return callback(*args, **kwargs)
File "/usr/local/lib/python3.4/dist-packages/click/decorators.py", line 17, in new_func
return f(get_current_context(), *args, **kwargs)
File "/usr/local/lib/python3.4/dist-packages/todoman/cli.py", line 64, in cli
ctx.invoke(cli.commands["list"])
File "/usr/local/lib/python3.4/dist-packages/click/core.py", line 534, in invoke
return callback(*args, **kwargs)
File "/usr/local/lib/python3.4/dist-packages/click/decorators.py", line 17, in new_func
return f(get_current_context(), *args, **kwargs)
File "/usr/local/lib/python3.4/dist-packages/todoman/cli.py", line 232, in list
reverse=reverse
TypeError: other argument must be K instance
By printing the value of rv
(main.py#L82) we get
[0, False, inf, <functools.KeyWrapper object at 0x7fd9f2cd1970>]
[0, False, inf, <functools.KeyWrapper object at 0x7fd9f2cd18f0>]
...
[<functools.KeyWrapper object at 0x7fd9f2cd19b0>, False, inf, <functools.KeyWrapper object at 0x7fd9f2cd1990>]
which causes the comparison to fail when the first and last todos are compared, since the first element is of a different type. The first element is for the priority
field (main.py#L40); because it is a "negative" field it enters the main.py#L73 condition. I believe the fix should be to change the condition to if neg
, in order to allow the comparison to occur. I've PR'd in #25, please check it and see if I'm understanding this correctly. Tell me if you need any sample data or more info.
And thank you very much for developing and maintaining todoman
, I was looking for a CLI todo manager for a while!
This issue was moved from the issue tracker at GitLab.
This fork may offer a fix for this.
It would be nice if todoman could support checklists.
I know them from the android app OpenTasks. Here is (how i understand) they work:
I hope this makes at least a little sense...
here is an example of todomans display for all my issues ;)
Summary: todoman issues
Description: [x] delete todos
[ ] support checklists
[x] interactive keybindings
Location:
Due:
Completed: [ ]
Urgent: [ ]
< Cancel > < Save >
and here how it could look like:
Summary: todoman issues
Description:
Checklist: [x] delete todos
[ ] support checklists
[x] interactive keybindings
[ ] <new>
Location:
Due:
Completed: [ ]
Urgent: [ ]
< Cancel > < Save >
where a checklist item is delete when no text remains and a new one is added when hitting in the textfield
I have no experience in urwid (or whatever you're using) so I am not sure this works at all
P.S: Interesting how gitlab 'sees' those items and shows a status in the overview of the issue ;)
I created some todos on iOS and synced them with vdirsyncer.
I configured todoman to look in the appropriate directory, and when I trace the process, I see that it stats the .ics files.
However, todo list
does not show any of them.
.cache/todoman/ids
just consists of one line: []
Let me know if you need one of the todos as example.
Currently, todo list | cat
outputs colors. I think it shouldn't, and also should get a --color
option (see khal).
Opinions?
This issue was moved from the issue tracker at GitLab.
I am trying creating a todo and then syncing it with darwin calendar server.
That fails with following error from darwin calendar server:
2016-04-15 02:55:17+0300 [-] [caldav-1] [-] [twistedcaldav.method.put_common#error] Invalid calendar data: Calendar data had unfixable problems:
2016-04-15 02:55:17+0300 [-] [caldav-1] [VTODO] Missing or too many required property: DTSTAMP
What I did:
Resulting file (and file with same summary, but created from android "tasks" application, that syncs successfully are attached.
fail.ics
success.ics
The successful one does contain DTSTAMP field.
I just upgraded todoman (current version: 2.0.1). When I edit a todo, I get this error:
Traceback (most recent call last):
File "/home/pawel/.local/bin/todo", line 11, in <module>
sys.exit(cli())
File "/home/pawel/.local/lib/python3.5/site-packages/click/core.py", line 722, in __call__
return self.main(*args, **kwargs)
File "/home/pawel/.local/lib/python3.5/site-packages/click/core.py", line 697, in main
rv = self.invoke(ctx)
File "/home/pawel/.local/lib/python3.5/site-packages/click/core.py", line 1066, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/home/pawel/.local/lib/python3.5/site-packages/click/core.py", line 895, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/home/pawel/.local/lib/python3.5/site-packages/click/core.py", line 535, in invoke
return callback(*args, **kwargs)
File "/home/pawel/.local/lib/python3.5/site-packages/click/decorators.py", line 17, in new_func
return f(get_current_context(), *args, **kwargs)
File "/home/pawel/.local/lib/python3.5/site-packages/todoman/cli.py", line 62, in command_wrap
return command(*a, **kw)
File "/home/pawel/.local/lib/python3.5/site-packages/todoman/cli.py", line 192, in edit
click.echo(ctx.obj['formatter'].detailed(todo, database))
TypeError: detailed() takes 2 positional arguments but 3 were given
The error occurs when I click 'Save'. The todo is edited anyway (in my case I was removing the due date), so I guess it's not an urgent problem. Still, showing an error after a correctly finished operation is something that could be fixed :)
I also noticed that the new version of todoman displays the todos with unordered ids (it used to be 1, 2, 3, ...
, now it is 2, 30, 15, ...
). Also, the ids do not change if I display just one of the lists (they used to start with 1 regardless if I displayed one list or all of them). Was this change intentional of is it another bug? It seems reasonable, but I want to make sure.
Being standards-complaint, todo
is compatible with lots of other apps (I hope!). I'd like to document and mention them, so users can know ahead of time if it's useful for them (mostly for nice PR really).
Currently, I know we're compatible with the iOS reminders app, and that's really the end of my list. Fastmail's calendar doesn't have reminders. :(
It would be nice to have a picture or even smaller audio-less demos in the README. Latter could be recorded with http://asciinema.org/
I remember you mentioned the enum I used for the delete option requires python 3.4 while you'd like to keep 3.3 compat. I didn't realize enums are that new, we could also use some simple int constants and use them, so python 3.3 should work.
Hi,
In the last update in Archlinux (updating from 2.0.2-1 to 2.1.0-1) I got the following failure while performing the test test_default_due2
________________________________________________ test_default_due2 _________________________________________________
tmpdir = local('/tmp/pytest-of-XXXXXX/pytest-9/test_default_due20')
runner = <click.testing.CliRunner object at 0x7f9b9d3f4f60>
create = <function create.<locals>.inner at 0x7f9ba0de31e0>
default_database = <todoman.model.Database object at 0x7f9b9d3f4b00>
@freeze_time(datetime.datetime.now())
def test_default_due2(tmpdir, runner, create, default_database):
cfg = tmpdir.join('config')
cfg.write('default_due = 24\n', 'a')
r = runner.invoke(cli, ['new', '-ldefault', '-dtomorrow', 'aaa'])
> assert not r.exception
E assert not InvalidArgsError(<class 'icu.SimpleDateFormat'>, 'format', (FakeDatetime(2003, 10, 30, 11, 45),))
E + where InvalidArgsError(<class 'icu.SimpleDateFormat'>, 'format', (FakeDatetime(2003, 10, 30, 11, 45),)) = <Result InvalidArgsError(<class 'icu.SimpleDateFormat'>, 'format', (FakeDatetime(2003, 10, 30, 11, 45),))>.exception
tests/test_basic.py:225: AssertionError
================================== 1 failed, 45 passed, 3 xfailed in 2.71 seconds ==================================
I'm not sure what's going wrong, maybe this can be helpful for you.
This issue was moved from the issue tracker at GitLab.
todoman should show the LOCATION assigned to a task.
i.e. the following task contains the "Location" LOCATION:
$ cat 9fe6d194-24e2-46cf-a600-faad711f9f20.ics
BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//Mozilla.org/NONSGML Mozilla Calendar V1.1//EN
BEGIN:VTIMEZONE
TZID:Europe/Berlin
X-LIC-LOCATION:Europe/Berlin
BEGIN:DAYLIGHT
TZOFFSETFROM:+0100
TZOFFSETTO:+0200
TZNAME:CEST
DTSTART:19700329T020000
RRULE:FREQ=YEARLY;BYDAY=-1SU;BYMONTH=3
END:DAYLIGHT
BEGIN:STANDARD
TZOFFSETFROM:+0200
TZOFFSETTO:+0100
TZNAME:CET
DTSTART:19701025T030000
RRULE:FREQ=YEARLY;BYDAY=-1SU;BYMONTH=10
END:STANDARD
END:VTIMEZONE
BEGIN:VTODO
CREATED:20150414T065645Z
LAST-MODIFIED:20150414T065820Z
DTSTAMP:20150414T065820Z
UID:9fe6d194-24e2-46cf-a600-faad711f9f20
SUMMARY:Todoman Testtask
PRIORITY:1
STATUS:NEEDS-ACTION
CATEGORIES:Online
X-MOZ-LASTACK:20150414T065807Z
DTSTART;TZID=Europe/Berlin:20150414T090000
DUE;TZID=Europe/Berlin:20150428T090000
LOCATION:Location
PERCENT-COMPLETE:20
DESCRIPTION:Description \n\nHello World
SEQUENCE:1
X-MOZ-GENERATION:3
X-MOZ-SNOOZE-TIME:20150415T065807Z
BEGIN:VALARM
ACTION:DISPLAY
TRIGGER;VALUE=DURATION:-PT15M
DESCRIPTION:Default Mozilla Description
END:VALARM
END:VTODO
END:VCALENDAR
but todoman doesn't show it:
$ todo show 22
Todoman Testtask
Due: 2015-04-28 Urgent
Description
Hello World
I just started using todoman. I noticed that when I create a new task, it has a due date set automatically to now + 24h. Is there an option to disable this feature (other than editing each task and removing the due date manually)?
todo new
crashes:
$ todo new
Traceback (most recent call last):
File "/usr/bin/todo", line 11, in <module>
load_entry_point('todoman==2.0.2', 'console_scripts', 'todo')()
File "/usr/lib/python3.6/site-packages/click/core.py", line 722, in __call__
return self.main(*args, **kwargs)
File "/usr/lib/python3.6/site-packages/click/core.py", line 697, in main
rv = self.invoke(ctx)
File "/usr/lib/python3.6/site-packages/click/core.py", line 1066, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/usr/lib/python3.6/site-packages/click/core.py", line 895, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/lib/python3.6/site-packages/click/core.py", line 535, in invoke
return callback(*args, **kwargs)
File "/usr/lib/python3.6/site-packages/todoman/cli.py", line 62, in command_wrap
return command(*a, **kw)
File "/usr/lib/python3.6/site-packages/click/decorators.py", line 17, in new_func
return f(get_current_context(), *args, **kwargs)
File "/usr/lib/python3.6/site-packages/todoman/cli.py", line 150, in new
ui = TodoEditor(todo, ctx.obj['db'].values(), ctx.obj['formatter'])
AttributeError: 'Database' object has no attribute 'values'
todoman
is not purely usable either via cli or the curses interface. We need to fill the missing bits to support both options properly.
When I use todo list
I get a very long list of all my tasks. I know I can filter by lists, but is it possible to filter by "this week", "today", "overdue"? I'd like to have a short list of today's (and overdue) tasks so I get a good feeling when I've done all for today :-)
Right now, when we do a todo list -a
to list every task (including the done
ones) they are sorted by priority
first, then by status
:
1 [X] Trivial task I've already done @personal (100%)
2 [X] 2016-01-19 Another trivial task I took care of @personal (100%)
3 [ ] Trivial todo, waiting me to stop procrastinating @personal
4 [ ] Another trivial todo task I have to do @personal
5 [X] ! 2016-04-09 This was important, but I've already done this @personal (100%)
6 [X] ! 2016-04-05 This was important as well, but I done it yesterday @personal (100%)
7 [ ] ! This is important and I have to do this @personal
8 [ ] ! This is important as well and is waiting for me @personal
IMHO it makes more sense to list them sorted by status
, then by priority
, so we get to see the tasks that still need action (both not important
and important
) closer to the bottom of the output, even though some of them are not as important as some done
tasks.
1 [X] Trivial task I've already done @personal (100%)
2 [X] 2016-01-19 Another trivial task I took care of @personal (100%)
3 [X] ! 2016-04-09 This was important, but I've already done this @personal (100%)
4 [X] ! 2016-04-05 This was important as well, but I done it yesterday @personal (100%)
5 [ ] Trivial todo, waiting me to stop procrastinating @personal
6 [ ] Another trivial todo task I have to do @personal
7 [ ] ! This is important and I have to do this @personal
8 [ ] ! This is important as well and is waiting for me @personal
The fix for this is to simply swap the main.py#L40-41 lines, but since I believe this is a matter of preference I'm raising a "question" issue in order to see what you think.
If you feel this makes sense ping me and I'll submit the PR.
This issue was moved from the issue tracker at GitLab.
Now that we support multiple vdirs, we need the editor to support picking one for new todos (and possibly existing ones too).
Could you please add todoman
to Homebrew?
Homebrew has kinda become the de facto package manager for macOS. I'd add it myself but I don't know how....
I have been looking into building a full-fledged curses-based interface for todoman. I have a working prototype that supports several lists, changing between them and marking tasks completed and incomplete.
Are you looking for something like this? Should I open a pull request to show and discuss what I have? Or is the full curses-based route not the direction in which you wish to move Todoman?
If I edit a task, enter something completely ridiculous into the due-field and hit save, todoman will silently discard all changes I've made.
Please include a NEWS file into the distribution, so packagers (and users) can easily see what the important changes in the release were.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.