1
0
Fork 0
mirror of https://github.com/topydo/topydo.git synced 2024-05-20 13:58:33 +00:00
Commit graph

41 commits

Author SHA1 Message Date
David Steele c4db4bce5e Remove some references to topydo.org 2020-12-03 17:41:11 -05:00
Jacek Sowiński 00d2496e5c Fix focus at the bottom and the top of the column
When scrolling down we need to switch to valign=bottom to properly show
last lines of the TodoWidget at the end of the TodoListWidget. Also
config <Down> key to use 'down' action in default config. Without such
config entry, using <Down> key would not take advantage of valign fix.

Also do not focus dividers when jumping with 'home' shortcut.
2020-11-23 07:35:21 +01:00
David Steele 0bf7b8030e Add auto_delete_whitespace config variable
Make the feature that deletes blank lines on load optional.

Defaults to true, to preserve existing behavior.
2020-10-05 21:32:14 -04:00
Bram Schoenmakers 58cd00f087 Documentation updates, expose the 'repeat' functionality with the . key 2017-11-21 10:24:00 +01:00
Bram Schoenmakers e28607b67a Show completed items at the bottom by default 2017-08-15 14:56:30 +02:00
Bram Schoenmakers 894edaade1 Make alphabet of the IDs configurable
I don't like typing numbers, and would like to limit the characters to
be those that are easily reachable with a Dvorak keyboard layout.
2017-07-20 10:28:21 +02:00
Jacek Sowiński 4bae3b9503 Introduce new 'mark_all' action in Column UI
It will mark all todo items contained in currently selected
TodoListWidget. By defualt it is mapped to <C-a> (Ctrl-a).
2017-02-27 23:02:01 +01:00
Bram Schoenmakers ebb3b4c229 Make text editor more configurable
Lookup mechanism:

1. Check whether an editor was given with the -E flag:

     topydo edit -E vim

2. Use the value of $TOPYDO_EDITOR
3. Use the value in the configuration file:

   [edit]
   editor = vim

4. Use the value in $EDITOR
5. Use 'vi' if the above fails.

This makes it easier to invoke an editor as vim with additional
parameters, for instance by adding the full todo.txt file to the
completion options (see the tip in issue #164). This trick was added to
the configuration file as a comment.
2017-02-08 14:13:55 +01:00
Colin Sullivan 162cc77695 focus and mark colors can now be specified in config 2016-11-24 08:34:08 +01:00
Bram Schoenmakers 8163a029a6 Introduce the topydo.org domain 2016-07-08 21:13:14 +02:00
Bram Schoenmakers 798ed50b47 Make column width configurable
Use this in the configuration file:

[columns]
column_width = 42
2016-05-30 15:01:16 +02:00
Jacek Sowiński 6b13938717 Add new 'reset' action for resetting state
It does 2 things:

1. Clears marked statuses for todo items
2. Resets keystates in all columns
2016-02-27 19:27:54 +01:00
Jacek Sowiński ef360c2fd0 Execute commands on multiple items marked with 'm'
1. 'm' can be reconfigured to any other key (action: 'mark').
2. Using 'mark' on already marked todo item will unmark it.
3. 'esc' key will clear whole selection.
4. Command will be executed on **all** marked items in **all** columns.
2016-02-23 00:24:06 +01:00
Bram Schoenmakers adcebfc0f9 Merge branch 'column-ui' of https://github.com/bram85/topydo into column-ui 2016-02-12 10:37:21 +01:00
Bram Schoenmakers 239a275f54 Introduce -C flag to steer color output
The -C flag takes 0, 1, 16, 256, auto, yes, true, no, false as possible
values.

If auto, then colors are enabled unless the output is not connected to a
TTY and is likely not to understand ANSI escape codes. 'auto' is the
default value.

The config().colors() function either returns 0, 16 or 256 for the
possible colors that can be displayed.

These values are also recognized by the colors option in the
configuration file.

This fixes issue #111.
2016-02-12 10:33:46 +01:00
Jacek Sowiński d6f2a9a550 Correctly recognize special keys in key-shortcuts
Special keys in config should follow similiar syntax to that used in
vim:

left arrow = `<Left>`
right arrow = `<Right>`
page down = `<Page down>`
home = `<Home>`
esc = `<Esc>`
F4 = `<F4>`
Ctrl+s = `<C-s>`
Meta+k = `<M-k>`

Examples:
=========

```ini
[column_keymap]
<Left> = prev_column
<Right> = next_column
<Esc>k = home
<C-s> = tag {} foo 1
<M-s> = tag {} foo
```
2016-02-11 00:31:48 +01:00
Jacek Sowiński 52a04262ba Give access to keymap of "column_actions"
Action names and default config for them:

```ini
[column_keymap]
0 = first_column
$ = last_column
h = prev_column
l = next_column
A = append_column
I = insert_column
E = edit_column
D = delete_column
Y = copy_column
L = swap_left
R = swap_right
```
2016-02-11 00:30:10 +01:00
Jacek Sowiński 2ece281203 Configurable keymap
User can now specify key-shortcuts in main topydo config file under
'column_keymap' section in form of:

`<SHORTCUT> = <ACTION>`

Two main types of action are supported:
- built-in (one of: 'home', 'end', 'up', 'down', 'postpone', 'postpone_s'
  and 'pri')
- topydo commands (aliases included). Prefixed with 'cmd'. Commands to
  call on selected todo item should contain '{}' placeholder to mark its
  place in final command call in similiar fashion as in aliases
  definitions.

postpone, postpone_s and pri shortcuts are sort of prefixes for
arguments for respective topydo commands triggered on selected todo item:
- `postpone<COUNT><PERIOD>` will translate to `cmd postpone {}
  <COUNT><PERIOD>`. postpone_s will do the same but with '-s' flag
  added.
- `pri<PRIORITY>` will translate to `cmd pri {} <PRIORITY>`

Default config as an example:

```ini
[column_keymap]
gg = home
G = end
j = down
k = up
d = cmd del {}
e = cmd edit {}
u = cmd revert
x = cmd do {}
pp = postpone
ps = postpone_s
pr = pri
```

- pp23d will postpone selected item by 23 days
- ps1m will postpone selected item (threshold date included) by 1 month
- prz will set priority of selected item to (Z)
2016-02-10 23:50:13 +01:00
Jacek Sowiński 5696719104 Create placeholder for args in aliases
With this change there is now possible to forward args supplied on CLI
to desired placed in real command.

Example config:

[aliases]
star = tag {} star 1
unstar = tag {} star

Example usage:

`topydo star foo` will resolve to: `topydo tag foo star 1`
`topydo unstar foo` will resolve to: `topydo tag foo star`
2015-12-16 13:24:59 +01:00
MinchinWeb 650a420c13 Update default for top alias.
Uses new %P format and -N parameter.
2015-12-03 21:29:48 -07:00
Bram Schoenmakers 8bf0fbb7f8 Merge branch 'master' into ls-format
Conflicts:
	setup.py
2015-11-08 21:15:54 +01:00
Bram Schoenmakers c35b9d1609 Put comment on a separate line
The comment is not stripped from the value by the ConfigParser, so

    identifiers = text ; foo

didn't work.

Although the documention says that inline comments are allowed:
https://docs.python.org/2/library/configparser.html?highlight=comment
2015-11-06 10:33:27 +01:00
Jacek Sowiński 99b91fea5e Append %d and %t to default list_format 2015-11-05 17:42:14 +01:00
Jacek Sowiński e065dfeb8a Add customizable right alignment in list_format
User can now mark place in list_format from where he wants to start
right-aligning remaining content. Tab character (\t) is used as marker.

Added also 'top' alias example to topydo.conf which utilizes this
feature and implements #52.

Minor:
    - remove `- 1` from statements setting line width
    - move strip_braces() to topydo.lib.ListFormat and rename it to
      strip_placeholder_braces()

fixup strip_braces
2015-11-05 17:41:59 +01:00
Bram Schoenmakers a92411f795 Swap priority and creation date.
Now it conforms to the normal todo.txt CLI output.
2015-11-05 12:42:56 +01:00
Bram Schoenmakers 15f497ee59 Merge branch 'master' into ls-format 2015-11-04 08:34:45 +01:00
Jacek Sowiński 7120f86676 Fix tests and config for list_format 2015-10-31 00:00:31 +01:00
Bram Schoenmakers 8167470b36 Add example 'next' alias to configuration
It shows the first todo item to be done, optionally with a filter
applied:

topydo next +Chores @Home
2015-10-30 23:31:05 +01:00
Jacek Sowiński 3a8e8efaf2 Add %I for identifiers padded with spaces
It calculates if actual todo id is shorter than 3 characters and adds
additional space or two to maintain fixed length of this parameter.

Also set %I as default instead of %i to provide compatibility with
tests and.
2015-10-30 23:21:50 +01:00
Jacek Sowiński eaf382a087 Use "conditional characters" in list_format
These conditional characters should be specified **inside** curly braces
({}) and **after** percent sign (%). They can appear in two groups:
before and after particular placeholder.

Example:
"list_format = %{(}p{)}"

If priority of given todo is C, "list_format" set above will now resolve
to (C), but also won't display empty parentheses if there is no priority
set.

Fixes issue mentioned in 8650033bdb
2015-10-30 23:21:50 +01:00
Bram Schoenmakers 8650033bdb Introduce list format option.
The `ls` output can be customized with the list_format option in the
configuration, or the `-F` flag for `ls`.

Open issues:

* Relative dates to be implemented (see PR #52)
* Using (%p) without todo items without priority results in ()
* Ability to print todo on a single line (see PR #52)
2015-10-27 13:18:19 +01:00
Jacek Sowiński 189cb6ab14 Move all lsprj and lscon variants to aliases 2015-10-24 00:42:22 +02:00
Jacek Sowiński 9088cd3775 Introduce aliases functionality
Aliases can now be defined in 'aliases' section of topydo config file.

Examples:

[aliases]
showall = ls -x
purge = del -f
ical = ls -f ical
2015-10-24 00:36:45 +02:00
Jacek Sowiński b8f99e6ed9 Add possibility for creating backups of todolist
Backups containing whole todolist and archive can be now saved after
execution of each "read-write" command. Furthermore this change creates
base for eventual "revert" command.

Backups are safely stored and indexed in our own JSON-based format which
is compatible with python2.x and python3.x. We also use zlib compression
to minimize size of backup file. Path of the backup file is always
relative to the todo file, so backups from different todo files won't
mix up.

User can configure number of stored backups with new config option -
"backup_count". Any positive number will tell topydo to store that very
number of backups. Setting "backup_count" to 0 will completely turn off
backup functionality.
2015-10-15 22:20:15 +02:00
Bram Schoenmakers 62b77241d2 Add option to disable adding the creation date for 'add'.
Fixes #20.
2015-07-31 19:16:46 +02:00
Bram Schoenmakers 5d867764a2 Remove option highlight_projects_colors in favor of colorscheme options.
No need to toggle the highlighting of projects and contexts anymore. If
you want to turn it off, simply assign an empty value to the
project/context colors:

  [colorscheme]
  project_color =
  context_color =
2015-06-04 20:50:09 +02:00
Jacek Sowiński 44025480fe Add possibility to configure colorscheme of topydo
- Add new module `topydo.lib.Colors` and class `Colors` for handling
  output colors and their ANSI codes.
- Create new config options with colors for priorities, projects,
  contexts, metadata, and links and place them under "colorscheme"
  section. When certain config option is absent default color code will be
  applied.
- Empty values:
    ! priority_colors will fall back to NEUTRAL_COLOR
    ! project_color, context_color, link_color, metadata_color will
      return empty string, so priority_color (if configured and applicable) of
      specific item should be used
- Return NEUTRAL_COLOR if supplied color number is out range
- Support user-friendly color names in config. At least for 16 base
  terminal colors.
2015-06-01 00:26:00 +02:00
Jacek Sowiński 8605bb1bf5 Append parent contexts to subtodo
This works identically to append_parent_projects option. Code was
generated by simply `s/project/context/`
2015-03-28 15:42:32 +01:00
Bram Schoenmakers 4e9c8b54c0 Add pretty printer filter for hiding certain tags.
topydo may introduce some internal tags, such as 'id' and 'p' for
dependency tracking, and 'ical' for keeping track of unique ids when
outputting iCalendar files.

Add a pretty printer filter that prevents certain tags from displaying
in the 'ls' output. These tags can be configured with the 'hide_tags'
configuration option in the 'ls' section, a comma-separated list of
tags (default: id,p,ical). To always show all tags, leave an empty
value.
2015-02-04 18:17:44 +01:00
Bram Schoenmakers 0cbfc6a882 Copy projects from parent to new sub todo items. 2014-12-09 20:51:31 +01:00
Bram Schoenmakers d73b512842 Move file out of bin directory. 2014-12-06 20:19:21 +01:00
Renamed from bin/topydo.conf (Browse further)