textile to markdown

Ali Karbassi
2018-07-05 23:15:05 -05:00
parent 4aa18e717e
commit 473ed04cbd

@@ -1,18 +1,18 @@
Conky is a system monitor for X, that can also display the output of shell commands. Setting up Conky is generally a simple process of installing it from your Linux distribution's repository.
Displaying your todo.txt file on your desktop is a simple task thanks to Conky. The most basic code to display the todo.txt file is: <code>${execpi 10 todo.sh -p ls}</code> This will cause your todo.txt file to be displayed as it would from the command line, minus the color, and it will refresh every 10 seconds. Using the grep command you can get a bit more fancy and color code your todo items.
Displaying your todo.txt file on your desktop is a simple task thanks to Conky. The most basic code to display the todo.txt file is: `${execpi 10 todo.sh -p ls}` This will cause your todo.txt file to be displayed as it would from the command line, minus the color, and it will refresh every 10 seconds. Using the grep command you can get a bit more fancy and color code your todo items.
Unless you want your todo list to be truncated, you will also need to play with the <code>text_buffer_size variable</code> in your @.conkyrc@ file. The default setting is 128 bytes, but I found that to be inadequate for my todo.txt file, so I raised the variable to 1024 bytes. The higher your <code>text_buffer_size</code>, the more resources that Conky will use, so raise sparingly.
Unless you want your todo list to be truncated, you will also need to play with the `text_buffer_size variable` in your `.conkyrc` file. The default setting is 128 bytes, but I found that to be inadequate for my todo.txt file, so I raised the variable to 1024 bytes. The higher your `text_buffer_size`, the more resources that Conky will use, so raise sparingly.
!http://farm4.static.flickr.com/3316/3343839756_612804f1fe_o.png!
![](http://farm4.static.flickr.com/3316/3343839756_612804f1fe_o.png)
h2. Coloring
## Coloring
The approach by Duane Hubbard uses a wrapper @color_todo.sh@ script that augments the plain todo.txt output with Conky's @${color yellow}@ tags. Starting with todo.txt v 2.7, one can simply redefine todo.txt's built-in color map to achieve the same effect. No wrapper and postprocessing is needed, and this will work together with the new feature of highlighting more than priorities A, B & C.
The approach by Duane Hubbard uses a wrapper `color_todo.sh` script that augments the plain todo.txt output with Conky's `${color yellow}` tags. Starting with todo.txt v 2.7, one can simply redefine todo.txt's built-in color map to achieve the same effect. No wrapper and postprocessing is needed, and this will work together with the new feature of highlighting more than priorities A, B & C.
Add a separate todo.txt configuration in @~/.todo/config-conky@:
Add a separate todo.txt configuration in `~/.todo/config-conky`:
<pre>
```
# todo.txt configuration for Conky highlighting.
export BLACK='${color black}'
export RED='${color red}'
@@ -32,13 +32,13 @@ export LIGHT_CYAN='${color LightCyan}'
export WHITE='${color white}'
export DEFAULT='${color}'
source ~/.todo/config # Adapt this to wherever your todo.txt configuration is located.
</pre>
```
Inside @~/.todo/config@ the color map defaults must _not_ be uncommented, or they'll override the above setting again! On the other hand, the @PRI_...@ defaults _must_ be overridden in there, or else todo.txt will still use the defaults built into the script itself, using the inital color definitions. The execution order of the configurations is @todo.sh@ -> @config-conky@ -> @config@.
Inside `~/.todo/config` the color map defaults must _not_ be uncommented, or they'll override the above setting again! On the other hand, the `PRI_...` defaults _must_ be overridden in there, or else todo.txt will still use the defaults built into the script itself, using the inital color definitions. The execution order of the configurations is `todo.sh` -> `config-conky` -> `config`.
To summarize, your @~/.todo/config@ needs to looks like this:
To summarize, your `~/.todo/config` needs to looks like this:
<pre>
```
# === COLOR MAP ===
# -> commented out!
# export BLACK='\\033[0;30m'
@@ -50,22 +50,22 @@ To summarize, your @~/.todo/config@ needs to looks like this:
export PRI_A=$YELLOW # color for A priority
export PRI_B=$GREEN # color for B priority
# ... snip ...
</pre>
```
Embed the todo.txt call with this special configuration inside your @.conkyrc@ (see below for an example @.conkyrc@ file): <code>${execpi 10 todo.sh -d ~/.todo/config-conky ls</code>
Embed the todo.txt call with this special configuration inside your `.conkyrc` (see below for an example `.conkyrc` file): `${execpi 10 todo.sh -d ~/.todo/config-conky ls`
!http://farm4.static.flickr.com/3561/3343839752_b7e47f7c16_o.png!
![](http://farm4.static.flickr.com/3561/3343839752_b7e47f7c16_o.png)
h2. Resources
## Resources
"conkyrc files by Duane Hubbard":http://github.com/duanehubbard/conky-files
[conkyrc files by Duane Hubbard](http://github.com/duanehubbard/conky-files)
---
Example @~/.conkyrc@ for Conky 1.8.0 on Ubuntu Lucid with todo.txt v 2.6
Example `~/.conkyrc` for Conky 1.8.0 on Ubuntu Lucid with todo.txt v 2.6
<pre>
```
# Conky, a system monitor embedding into the Linux desktop.
#
# Compiz may decorate the embedded Conky window.
@@ -96,4 +96,4 @@ xftfont Courier:size=10
TEXT
${execpi 120 todo.sh -d ~/.todo/config-conky ls}
</pre>
```