Mercurial > getan
annotate README @ 417:d6d9d319bd2e
Prepares for PyPi publication.
author | Bernhard Reiter <bernhard@intevation.de> |
---|---|
date | Wed, 03 May 2017 16:29:24 +0200 |
parents | 69ef6f89e930 |
children | cd990c7dc746 |
rev | line source |
---|---|
417
d6d9d319bd2e
Prepares for PyPi publication.
Bernhard Reiter <bernhard@intevation.de>
parents:
414
diff
changeset
|
1 Usage |
d6d9d319bd2e
Prepares for PyPi publication.
Bernhard Reiter <bernhard@intevation.de>
parents:
414
diff
changeset
|
2 ===== |
d6d9d319bd2e
Prepares for PyPi publication.
Bernhard Reiter <bernhard@intevation.de>
parents:
414
diff
changeset
|
3 |
d6d9d319bd2e
Prepares for PyPi publication.
Bernhard Reiter <bernhard@intevation.de>
parents:
414
diff
changeset
|
4 Call ``getan`` or ``getan.py`` in a terminal to start |
d6d9d319bd2e
Prepares for PyPi publication.
Bernhard Reiter <bernhard@intevation.de>
parents:
414
diff
changeset
|
5 with an empty list of tasks that you want to track time for. |
d6d9d319bd2e
Prepares for PyPi publication.
Bernhard Reiter <bernhard@intevation.de>
parents:
414
diff
changeset
|
6 |
d6d9d319bd2e
Prepares for PyPi publication.
Bernhard Reiter <bernhard@intevation.de>
parents:
414
diff
changeset
|
7 Use the Insert-Key to add a new task to track. |
d6d9d319bd2e
Prepares for PyPi publication.
Bernhard Reiter <bernhard@intevation.de>
parents:
414
diff
changeset
|
8 (A *task* is called *project* within getan.) |
d6d9d319bd2e
Prepares for PyPi publication.
Bernhard Reiter <bernhard@intevation.de>
parents:
414
diff
changeset
|
9 |
d6d9d319bd2e
Prepares for PyPi publication.
Bernhard Reiter <bernhard@intevation.de>
parents:
414
diff
changeset
|
10 Now select one of the projects with the arrow keys from your keyboard |
d6d9d319bd2e
Prepares for PyPi publication.
Bernhard Reiter <bernhard@intevation.de>
parents:
414
diff
changeset
|
11 and press enter to start the clock. See ``INTRODUCTION`` for more keyboard |
d6d9d319bd2e
Prepares for PyPi publication.
Bernhard Reiter <bernhard@intevation.de>
parents:
414
diff
changeset
|
12 commands. |
d6d9d319bd2e
Prepares for PyPi publication.
Bernhard Reiter <bernhard@intevation.de>
parents:
414
diff
changeset
|
13 |
d6d9d319bd2e
Prepares for PyPi publication.
Bernhard Reiter <bernhard@intevation.de>
parents:
414
diff
changeset
|
14 The time log entries will be saved in an sqlite database. |
d6d9d319bd2e
Prepares for PyPi publication.
Bernhard Reiter <bernhard@intevation.de>
parents:
414
diff
changeset
|
15 The ``scripts/`` will help to generate reports from them. |
d6d9d319bd2e
Prepares for PyPi publication.
Bernhard Reiter <bernhard@intevation.de>
parents:
414
diff
changeset
|
16 |
288 | 17 Installation |
18 ============ | |
0 | 19 |
336
a3d1fc6c0153
README updated: New urwid.org homepage and location simplified. Typo fixed.
Bernhard Reiter <bernhard@intevation.de>
parents:
291
diff
changeset
|
20 Getan requires `urwid <http://urwid.org/>`_ in a version >= 1.0. Urwid is |
367
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
21 a console user interface library written in Python. For console output e.g. |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
22 zeiterfassung.py Getan also requires `Jinja2 <http://jinja.pocoo.org/>_`. |
261 | 23 |
288 | 24 Install urwid |
25 ------------- | |
23
9c4e8ba3c4fa
Added a new implementation of 'getan' based on urwid, a python console user interface library.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
3
diff
changeset
|
26 |
288 | 27 On Debian GNU/Linux >= Wheezy just run as root::: |
28 | |
29 $ apt-get install python-urwid | |
30 | |
31 On other systems urwid may be installed via pip or directly put into the sources | |
32 of getan. | |
33 | |
34 Using pip | |
35 ^^^^^^^^^ | |
36 | |
37 To install urwid via pip run as root:: | |
38 | |
39 $ pip install urwid | |
40 | |
41 Or if you prefer using a virtualenv:: | |
42 | |
414
69ef6f89e930
Prepares release v2.0.
Bernhard Reiter <bernhard@intevation.de>
parents:
367
diff
changeset
|
43 $ virtualenv getan-env |
288 | 44 $ source getan-env/bin/activate |
414
69ef6f89e930
Prepares release v2.0.
Bernhard Reiter <bernhard@intevation.de>
parents:
367
diff
changeset
|
45 (getan-env)$ pip install -U pip # to get the latest pip |
288 | 46 (getan-env)$ pip install urwid |
47 | |
48 Using urwid sources | |
49 ^^^^^^^^^^^^^^^^^^^ | |
50 | |
51 Urwid can be put as source to the getan directory when getan is run directly | |
52 from the sources. Urwid source can be downloaded from `pypi | |
336
a3d1fc6c0153
README updated: New urwid.org homepage and location simplified. Typo fixed.
Bernhard Reiter <bernhard@intevation.de>
parents:
291
diff
changeset
|
53 <https://pypi.python.org/pypi/urwid/>`_. |
288 | 54 |
337
96a8545eb247
README: updated for urwid 1.1.2. Better example shell commands for using urwid from source.
Bernhard Reiter <bernhard@intevation.de>
parents:
336
diff
changeset
|
55 For urwid 1.1.2 the direct download link from pypi is |
340
325499a01b65
Use text width of 80 chars per line in README
Björn Ricks <bjoern.ricks@intevation.de>
parents:
337
diff
changeset
|
56 `<https://pypi.python.org/packages/source/u/urwid/urwid-1.1.2.tar.gz>`_ |
325499a01b65
Use text width of 80 chars per line in README
Björn Ricks <bjoern.ricks@intevation.de>
parents:
337
diff
changeset
|
57 (sha256sum is |
325499a01b65
Use text width of 80 chars per line in README
Björn Ricks <bjoern.ricks@intevation.de>
parents:
337
diff
changeset
|
58 f56568b4f8459b3265c65d9e275ef72df6cb16ad0c291f0feb027cc911ea0f26).:: |
288 | 59 |
60 $ cd getan-source | |
337
96a8545eb247
README: updated for urwid 1.1.2. Better example shell commands for using urwid from source.
Bernhard Reiter <bernhard@intevation.de>
parents:
336
diff
changeset
|
61 $ v=urwid-1.1.2 |
96a8545eb247
README: updated for urwid 1.1.2. Better example shell commands for using urwid from source.
Bernhard Reiter <bernhard@intevation.de>
parents:
336
diff
changeset
|
62 $ curl -O https://pypi.python.org/packages/source/u/urwid/$v.tar.gz |
96a8545eb247
README: updated for urwid 1.1.2. Better example shell commands for using urwid from source.
Bernhard Reiter <bernhard@intevation.de>
parents:
336
diff
changeset
|
63 $ sha256sum $v.tar.gz |
96a8545eb247
README: updated for urwid 1.1.2. Better example shell commands for using urwid from source.
Bernhard Reiter <bernhard@intevation.de>
parents:
336
diff
changeset
|
64 $ tar -xzvf $v.tar.gz |
96a8545eb247
README: updated for urwid 1.1.2. Better example shell commands for using urwid from source.
Bernhard Reiter <bernhard@intevation.de>
parents:
336
diff
changeset
|
65 $ ln -s $v/urwid urwid |
288 | 66 |
367
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
67 Install Jinja2 |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
68 -------------- |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
69 |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
70 On Debian GNU/Linux just run as root::: |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
71 |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
72 $ apt-get install python-jinja2 |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
73 |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
74 On other systems jinja2 may be installed via pip or directly put into the |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
75 sources of getan. |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
76 |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
77 Using pip |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
78 ^^^^^^^^^ |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
79 |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
80 To install jinja2 via pip run as root:: |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
81 |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
82 $ pip install jinja2 |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
83 |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
84 Or if you prefer using a virtualenv:: |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
85 |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
86 $ source getan-env/bin/activate |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
87 (getan-env)$ pip install jinja2 |
ea5a171abda7
Update README for installing jinja2
Björn Ricks <bjoern.ricks@intevation.de>
parents:
342
diff
changeset
|
88 |
288 | 89 Install getan |
90 ------------- | |
91 | |
92 A installation of getan is not required. It can also be run directly from the | |
93 sources. To install getan system wide the following command must be run as root | |
94 user:: | |
95 | |
96 $ python setup.py install | |
97 | |
98 Starting getan | |
99 ============== | |
100 | |
101 Getan can be directly run from sources or after a system wide installation from | |
102 the bin dir (e.g. /usr/bin). | |
103 | |
104 Running from Sources | |
105 -------------------- | |
106 | |
107 To run getan from the sources run:: | |
0 | 108 |
23
9c4e8ba3c4fa
Added a new implementation of 'getan' based on urwid, a python console user interface library.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
3
diff
changeset
|
109 $ ./getan.py |
0 | 110 |
288 | 111 or:: |
0 | 112 |
288 | 113 $ ./getan.py /path/to/mytime.db |
0 | 114 |
341
148300d6f126
Fix typos in README
Björn Ricks <bjoern.ricks@intevation.de>
parents:
340
diff
changeset
|
115 to choose a different sqlite3 database then the default time.db |
288 | 116 |
117 The classic version of 'getan' which is based on curses can be run with:: | |
118 | |
23
9c4e8ba3c4fa
Added a new implementation of 'getan' based on urwid, a python console user interface library.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
3
diff
changeset
|
119 $ classic/getan |
9c4e8ba3c4fa
Added a new implementation of 'getan' based on urwid, a python console user interface library.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
3
diff
changeset
|
120 |
288 | 121 or:: |
23
9c4e8ba3c4fa
Added a new implementation of 'getan' based on urwid, a python console user interface library.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
3
diff
changeset
|
122 |
288 | 123 $ classic/getan /path/to/mytime.db |
124 | |
125 Running from installation | |
126 ------------------------- | |
127 | |
128 After installing getan it can be run with:: | |
129 | |
130 $ getan | |
131 | |
132 or:: | |
133 | |
134 $ getan /path/to/mytime.db | |
135 | |
136 The classic version of 'getan' is also available:: | |
137 | |
138 $ getan-classic | |
139 | |
140 or:: | |
141 | |
142 $ getan-classic /path/to/mytime.db | |
342
0ad38a86b1e6
Add vim modeline to REAMDE file
Björn Ricks <bjoern.ricks@intevation.de>
parents:
341
diff
changeset
|
143 |
417
d6d9d319bd2e
Prepares for PyPi publication.
Bernhard Reiter <bernhard@intevation.de>
parents:
414
diff
changeset
|
144 .. vim: set ts=4 sw=4 tw=80 filetype=rst : |