You are not logged in.
Lifehacker posted about this link to t, which is exactly the kind of python scripted task list I want to run in Arch. I grabbed it off his site, but have run into troubles when running it. I e-mailed him a couple times about the problem, but feel ready to post it on here and get some feedback.
-the e-mails-
print p + task['text']
^
I tried replacing p with the full string only to get the same error.
------------------------------------------
do you happen to be using Arch Linux? Arch recently make Python
3 the default system Python, and t isn't written for Python 3 (the print
statement is one of the things that has changed).
If so, you should be able to switch the first line of the script to:
#!/usr/bin/env python2
and that should make it use Python 2.x.
------------------------------
Yes, I am on Arch. Thanks for the reply! I changed the first line of t.py to use python2 and now get some new errors.
$t workplease
Traceback (most recent call last):
File "/home/stopbot/.config/t/t.py", line 289, in <module>
_main()
File "/home/stopbot/.config/t/t.py", line 278, in _main
td.write(options.delete)
File "/home/stopbot/.config/t/t.py", line 219, in write
with open(path, 'w') as tfile:
IOError: [Errno 20] Not a directory: '/home/stopbot/tasks/today'My bash alias is
alias t='python $XDG_CONFIG_HOME/t/t.py --task-dir ~/tasks --list today'
It does not exist. I mapped (and created) tasks directory to ~/documents/tasks. Should I try creating the actual list txt files as well (today). I'm executing
alias t='python $XDG_CONFIG_HOME/t/t.py --task-dir ~/documents/tasks --list today'
Output is the same old error:
$ t work
File "/home/stopbot/.config/t/t.py", line 208
print p + task['text']
If I change the alias within bashrc to
alias t='python2 $XDG_CONFIG_HOME/t/t.py --task-dir ~/documents/tasks --list today'
$ t work
Traceback (most recent call last):
File "/home/stopbot/.config/t/t.py", line 289, in <module>
_main()
File "/home/stopbot/.config/t/t.py", line 278, in _main
td.write(options.delete)
File "/home/stopbot/.config/t/t.py", line 219, in write
with open(path, 'w') as tfile:
IOError: [Errno 13] Permission denied: '/home/stopbot/documents/tasks/today'
So, perhaps I need to create the actual txt file for the list I want to use within the task directory?
Note, creating a txt file called today in the task directory did not help.
One thing at a time
Offline
kinhodder has created an excellent minimalist todo list with python. Works like a charm.
https://bbs.archlinux.org/viewtopic.php?id=115747
Last edited by rickdg (2011-03-29 08:07:37)
Offline