summaryrefslogtreecommitdiff
path: root/log/2015-03-15-alife-of-todos.org
blob: 8ca22dec63dbe31eca2a747b7a9ac181cc3b9d29 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
---
title: A life of TODOs
date: 2015-03-15
layout: post
category: log
---

It's been a year and seven months since I reintegrated Emacs to my
life. I do most of my daily tasks with Emacs. From reading my favorite
mailing lists with [[http://www.gnus.org/about.html][Gnus]], to replying to my work's [[https://github.com/baohaojun/org-jira][bug-tracker issues]].
I do all of it inside of Emacs, well, almost all of it, [[http://www.gnu.org/software/emacs/manual/html_node/emacs/EWW.html][EWW]] is only
good for browsing documentation..

It came by surprise to me, but the data of my =TODO= says, that the
major mode that drove me into the Emacs ecosystem, is [[http://orgmode.org/][Org-mode]].

*** Decomposing Org-mode

So what is *Org-mode*? That's usually the main question from the
newcomers.

At first, *Org*, short for Org-mode, looks like another markup
language. To others, it's the way to export to multiple document
formats from Emacs. To the ones that read the [[http://orgmode.org/manual/index.html][Org-mode manual]] or [[https://www.gnu.org/software/emacs/manual/html_node/org/index.html][Emacs
info reader]], it's just a =TODO= list and Agenda suite that mimics
other software that they know of, for example, Evernote and Trello.

Org is that and more. To quote the Org-mode website:

#+begin_quote
Org mode is for keeping notes, maintaining TODO lists, planning
projects, and authoring documents with a fast and effective plain-text
system.
#+end_quote

*** Everything is a TODO

Org-mode revolves around plain text headings, which makes all of the
entries generated by it manageable and portable. In Org-mode, all of
the headings start with a =*=, followed by the state of the heading.
The state usually changes from =TODO= to =NEXT=, and ends in =DONE=.
For example:

#+begin_src org
,* TODO Example to do
   This is a paragraph inside of the heading.
   [[http://example.com][this is a link to example]]

,* NEXT Next example to do
   ** Child heading with list
   - Item A
   - Item B
   - Item C

,* DONE Example done
#+end_src

This examples show the markup language that Org-mode uses. There's a
full list of the elements in the [[http://orgmode.org/manual/Markup.html#Markup][markup section of the manual]].

*** But why TODOs?

The brilliance behind the selection of =TODO= headings, is based on
the fact that everything you write to be addressed later is a task to
be done soon. To give an example of this, if I recommended you the
works of Op-art artist [[http://en.wikipedia.org/wiki/Victor_Vasarely][Victor Vasarely]] in the middle of a party or an
event conversation, one usually doesn't interrupt the conversation,
and goes searching for Victor Vasarely's artwork in his smart-phone.
Usually, what people do is to create a =TODO= in whichever format and
in whatever software. For example:

#+begin_example
Artists to checkout:
  - Victor Vasarely <- Recommended by Carlos
#+end_example

As you can see, this basic note of the task is enough, but the problem
arises if you were to sort it and search for this =TODO= later. This
can be solved by having a markup or syntax with parseable definitions.
Now what would that =TODO= look in Org-mode:

#+begin_src org
,* Personal
,** Arts
,*** Victor Vasarely
     :LOGBOOK:
     CLOCK: [2015-03-15 Sun 23:34]--[2015-03-16 Mon 00:30] =>  0:56
     :END:
     [2015-03-15 Sun 23:33]

#+end_src

In the example above, there's a =TODO= entry in the correct tree
(category), this way we can sort and order for fast searching. It
seems like an overkill, but trust me, after a couple of =TODO=, you
forget why you added that =TODO= and what to do =NEXT= with it.

The example above shows a timestamp and clock to track the time spent
on that =TODO=. This is useful for keeping track of the type of [[http://orgmode.org/manual/Tracking-your-habits.html#Tracking-your-habits][habits]]
you commit.

*** Outline structure with TODOs

Giving the nature of Org-mode, you can outline a text with different
heading levels. With this you can create sections, a hierarchy of
topics, or a simple tree that works as the main outline of a text
file. For instance, this text's outline so far:

#+begin_src org
,* A life of TODOs
,** Decomposing Org-Mode
,** Everything is a TODO
,** Outline structure
,** Agenda made of TODOs
#+end_src

With these you can create projects or topics based on the headings
levels. So it becomes fairly easy to order your ideas, and author
documents. Org-mode well defined markup can be exported to any format.

Org-mode can export to most common markups and documents, see the
[[http://orgmode.org/manual/Exporting.html#Exporting][Exporting]] section of the Org-mode manual for more information.

This document is rendered to HTML from Org markup, thanks to =jekyll=
and [[https://github.com/wallyqs/org-ruby][org-ruby]].


*** Agenda made of TODOs

With hierarchy and levels of your tasks, it makes sense to prioritize
headings based on their schedule, deadline, and priority. That's when
the [[http://orgmode.org/manual/Agenda-Views.html#Agenda-Views][Org-mode Agenda]] comes in the picture.

#+CAPTION: Org-mode Agenda view
#+NAME: block-agenda-nonproject.png
[[../img/block-agenda-nonproject.png]]

Agenda views render and display the current projects you have, the
child headings of the projects, in these case the =NEXT= headings
entries. The Agenda divides work into what is active, stuck, and
scheduled. At the top of the Agenda, you have the headings with
[[http://orgmode.org/manual/Deadlines-and-scheduling.html#Deadlines-and-scheduling][DEADLINES and SCHEDULED tags]]. Timestamps and Clocks help with your habits,
but they can be used as a way to schedule tasks that need to be
repeated or have a higher priority.

For example, a =TODO= about doing your laundry weekly:

#+begin_src org
,* TODO [#B] Laundry                                               :CLEANING:
:LOGBOOK:
- State "DONE"       from "TODO"       [2015-02-23 Mon 13:01]
- State "DONE"       from "NEXT"       [2015-01-16 Fri 18:54]
CLOCK: [2015-01-10 Sat 12:17]--[2015-01-10 Sat 12:18] =>  0:01
:END:
:PROPERTIES:
:LAST_REPEAT: [2015-02-23 Mon 13:01]
:END:
:DEADLINE: <2015-03-01 Sun +1w>
[2015-01-10 Sat 12:17]

#+end_src

The above =TODO= entry has a priority of level B, and will be repeated
every week after it's set to the =DONE= state, that's what the tag
=:DEADLINE:= says. The last time this entry was re-inserted was on
Monday February 23, this was introduced after the state was set to
=DONE=. The =:LOGBOOK:= tells us when was the last time the state was
changed from "=TODO=" to "=DONE=", and also a clock of the time it
took for this =TODO= to be captured. The last timestamp tells us the
time this =TODO= was captured(inserted), which was on Saturday January
the 10th.

*** Capture quickly, take care of it later

Like mentioned before, you usually want to capture a =TODO=, and add
as much information as you can in a give set of time. This means that
you should write down as fast as possible the task you have in mind or
the information just given. This a great habit and it works for
anybody, since not all retain that much information, at least, not me.

Because we want to capture as soon as you think about the =TODO=,
captures occur directly from any mode or place in ~Emacs~. Capturing
is done by calling =org-capture=, this will bring a selection frame
that will give you hooks based on a set of templates in your
configuration. For instance:

#+CAPTION: Org-mode Capture selection
#+NAME: org-capture.png
[[../img/org-capture.png]]

For example, you just realized that you have to reply to a
collaborator or compose an email. You want to capture as fast as
possible this =TODO=, you make use of the email template in
=org-capture= by pressing =m=. This will give you a template to fill
out, in these case the email address and the name.

To generate new capture templates you can call =C-c c C=, this will
bring up a customize group frame. For more information on the
templates, check the Org-mode manual section on [[http://orgmode.org/manual/Capture-templates.html][Capture Templates]].

To understand how capturing a =TODO= works, read the Org-mode manual
section on [[http://orgmode.org/manual/Capture-_002d-Refile-_002d-Archive.html#Capture-_002d-Refile-_002d-Archive][Capturing, Refiling and Archiving]].

*** Refile and archive later

This is one of my least favorite parts, but in order to keep a sane
=TODO= entries tree and to keep tidy projects, you have to refile them
and archive them.

Refile, literally, means reorganize and file the entries in their
corresponding hierarchy. For example, move your recently captured
=TODO= entry about Cats into Personal/Animals.

#+begin_src org
,* Cats

,* Personal
,** Animals
#+end_src

You can refile any heading in any view of Org-mode with =C-c C-w=,
that calls =org-refile=, and that will ask you in what hierarchy or
project do you want to file a =TODO= heading. org-refile takes care
about assigning a hierarchy to the entry, for instance, the Cats
=TODO= entry it was first heading, it will now be filed under Personal/Animals/,
turning into a third hierarchy heading. For example:

#+begin_src org
,* Personal
,** Animals
,*** Cats
#+end_src

You should capture and refile all the uncatalogued =TODO= entries into
a file dedicated as a staging step before refiling each to the correct
project. Usually, the community makes use of the '=refile.org=' file
as a staging space, and it's turn into a community standard.

The *advice* is to ~refile when you have time~, make it your last
errand, the same goes for archiving. Org-mode Agenda views will tell
you what entries are ready to be archived.

** TODOs make my life easier

Org-mode is part of my work flow with Emacs, and I love it. On a daily
basis, I create =TODO= entries for every task or activity I take part
of, for instance, keeping track of meetings, email replies to write,
mailing list articles to reply, documentation to finish. This is all
thanks to how well Org-mode is integrated with Emacs base modes, like
[[http://www.gnus.org/about.html][Gnus]] and [[http://magit.github.io/][Magit]]. All kind of modes provide integration with Org-mode,
at least [[http://orgmode.org/manual/External-links.html][org-links]], for example, =org-mu4e=, that provides org-links
to mails and drafts to later to be finished or to be later send.

According to what I've witness and what I've found online, it looks
like I don't even take full advantage of Org-mode. You can find
hardcore users and org-veterans in the Org-mode mailing list -
[[http://news.gmane.org/gmane.emacs.orgmode][http://news.gmane.org/gmane.emacs.orgmode]]. One of those hardcore users
is Bernt Hansen. To see how Bernt Hansen makes use of Org-mode and his
work flow, go read his famous article [[http://doc.norang.ca/org-mode.html][Organize your life in Text]].

Thanks to [[http://orgmode.org/manual/MobileOrg.html#MobileOrg][MobileOrg]], you can capture =TODO= entries from your
Smart-phone. I capture =TODO= entries everywhere, that I later
synchronize with the ones in my laptop.

I hope that with the given points of how you can make use of Org-mode,
and how I make use of it, I'm able to explain why Org-mode is the
killer feature of Emacs.