taskopenrc(5)

πŸ“¦
version 1.1.5 Β· 2 versions
, in fedora 43, fedora 44

πŸ’– taskopenrc(5) πŸ’–

okay bestie, so this is the manual page for taskopenrc, living in the User Manuals section of your friendly neighbourhood Unix man pages. it's the config file for taskopen(1) and honestly? it's giving lowkey powerful. let's get into it. πŸ¦‹


✨ NAME ✨

taskopenrc β€” the configuration file for the taskopen(1) command. it's literally the little brain that tells taskopen how to behave. 🧚


🌸 SYNOPSIS 🌸

~/.taskopenrc
taskopen -c /path/to/taskopenrc

πŸŽ€ DESCRIPTION πŸŽ€

so here's the tea: taskopen gets all its config data from a file called ~/.taskopenrc sitting in your home directory. that's its home. its vibe. its whole thing. πŸ’…

every single line in the taskopenrc file is one of exactly three things:

  • an assignment
  • a comment
  • or just empty (a blank line, no thoughts, head empty, iconic)

an assignment is a variable name and a value, separated by the equal sign (=) like this:

<variable name>=<value>

and that <variable name> has to be one of the names listed down below, no cap.

you can also use a hash mark (#) to mark the beginning of a comment line. notes to self? absolutely. πŸ“


πŸ‘‘ CONFIGURATION VARIABLES πŸ‘‘

the valid variable names and their default values are... drumroll πŸ₯

⭐ General configuration ⭐

  • BROWSER=xdg-open$FILE&>/dev/null β€” the executable that gets used to open URIs. it's the one opening your links, main character energy fr.
  • EDITOR=vim β€” your preferred editor. (yes it defaults to vim, no we are not debating this today πŸ™ˆ)
  • FILE_CMD=xdg-open β€” the command used for opening non-text files.
  • TASKBIN=task β€” the path to your taskwarrior binary. show me where your task lives.
  • PATH_EXT=/usr/share/taskopen/scripts β€” the given path(s) get prepended to taskopen's PATH variable. heads up: the default value depends on the installation path, so don't come for me if yours looks different. πŸ’œ
  • DEBUG=0 β€” set this to '1' if you want extra debugging output. turn it on when things are being weird, turn it off when you're done snooping. πŸ”₯

πŸ“ Notes files πŸ“

  • NOTES_FOLDER=$HOME/tasknotes/ β€” the directory where your Notes files get stored. their little home.
  • NOTES_EXT=.txt β€” the file extension used for Notes files.
  • NOTES_FILE β€” this sets the actual path of the Notes files. the string "UUID" gets replaced with the task's UUID. if you don't set it, the value gets assembled by taking NOTES_FOLDER and NOTES_EXT together: ${NOTES_FOLDER}UUID${NOTES_EXT}
  • NOTES_CMD β€” sets the command that gets executed to open a Notes file. if not set, the value gets assembled by taking EDITOR and NOTES_FILE: ${EDITOR} "${NOTES_FILE}"
  • NOTES_REGEX=Notes β€” the regular expression that identifies an annotation as a link to the Notes file. regex girlies rise 🌈

🌸 Default arguments 🌸

  • DEFAULT_FILTER=status.is:pending β€” the default taskwarrior filter applied to all queries. can be deactivated by using the -a or -A switches. your default, your rules, until you switch them off.
  • DEFAULT_SORT β€” specify the default sorting, which may be overridden by the -s option. sorting is self-care.
  • DEFAULT-i=ls -la β€” default command for the -i parameter, which lets you use -i without an argument. (yes, that's the literal variable name, don't look at me 😭)
  • DEFAULT-x β€” default command for the -x parameter, which lets you use -x without an argument.

πŸ¦‹ Classification πŸ¦‹

  • BROWSER_REGEX=www|http β€” the regular expression that identifies annotations openable by BROWSER.
  • FILE_REGEX="\.|\/|~" β€” the regular expression that identifies file paths in annotations, which then get opened by EDITOR or xdg-open.
  • TEXT_REGEX β€” this regular expression identifies annotations that can be edited in raw mode (see '-r'). if it's set and no other regular expression matches the annotation, the EDITOR gets invoked to edit the annotation. it's the fallback bestie. 🫢
  • CUSTOM1_REGEX β€” the regular expression that identifies annotations openable by CUSTOM1_CMD.
  • CUSTOM1_CMD β€” the command with which annotations matching CUSTOM1_REGEX get opened. you may use these environment variables: $FILE, $UUID, $ID, $LABEL, $ANNOTATION and $LAST_MATCH. by default, the value of $FILE gets appended to the command. see taskopen(1) for further details. ✨
  • CUSTOM[0-9]+_REGEX β€” see CUSTOM1_REGEX. same energy, more numbers.
  • CUSTOM[0-9]+_CMD β€” see CUSTOM1_CMD.
  • NO_ANNOTATION_HOOK β€” execute an arbitrary script if there is no annotation found. the corresponding taskwarrior IDs get passed as arguments, e.g. "attach.sh 21 42". the no-annotation backup plan. πŸ’€
  • TASK_ATTRIBUTES β€” add arbitrary taskwarrior attributes (comma separated) as sort keys and environment variables for use within user commands. to prevent name conflicts, the corresponding sort keys are preceded by "task_" (e.g. "task_project"). environment variables are additionally in upper case (e.g. TASK_PROJECT). so extra. so useful.

πŸ’… EXAMPLES πŸ’…

Using different file extensions for Notes files

NOTES_REGEX="Notes.(.*)"
NOTES_CMD="editnote /path/to/tasknotes/$UUID.$LAST_MATCH
"$TASK_DESCRIPTION" $UUID"
NO_ANNOTATION_HOOK=addnote
TASK_ATTRIBUTES=description

Using the notes.vim plugin for Notes files

NOTES_FOLDER=$HOME/Notes/vimnotes
NOTES_EXT=""
NOTES_CMD="vim -c ":Note $UUID""

the notes.vim plugin can be found at <http://peterodding.com/code/vim/notes/> β€” go check it out, it's cute. 🌈

CUSTOM1_REGEX=Message-[iI][dD]:|message:
CUSTOM1_CMD="echo "$FILE" | muttjump"

thanks to Jostein Berntsen, the old bash version of taskopen had support for linking to your emails by using mutt. this feature can still be enabled by setting the CUSTOM1_REGEX and CUSTOM1_CMD appropriately, given that taskopen's PATH contains the path to the corresponding helper scripts (see PATH_EXT). πŸ”₯

taskopen then uses muttjump to open the mutt mailboxes natively or in a screen window (very quick and effective, no notes). the muttjump can be found at <https://github.com/weisslj/muttjump>

Integrating user-defined attributes (UDAs)

TASK_ATTRIBUTES=url,costs
CUSTOM1_REGEX=URL
CUSTOM1_CMD="xdg-open $TASK_URL"
DEFAULT_SORT="task_costs-,id+"

you can make taskopen agnostic to any taskwarrior attributes by adding them to TASK_ATTRIBUTES. this enables the use of these attributes within user commands (see taskopen (1)) or as sort keys. obsessed with the flexibility tbh. ✨


πŸŽ€ CREDITS & COPYRIGHTS πŸŽ€

copyright (C) 2010 - 2020, J. Schlatow β€” respect the icon πŸ‘‘

taskopen is distributed under the GNU General Public License. see <http://www.opensource.org/licenses/gpl-2.0.php> for more information. (yes bestie, it's GPL, that's the whole vibe.)


🌟 SEE ALSO 🌟

for more information regarding taskopen, see the following:


πŸ™ˆ REPORTING BUGS πŸ™ˆ

bugs in taskopen may be reported to the issue-tracker at <https://github.com/ValiValpas/taskopen/issues>

go tell them. they want to know. bug reports are a love language, fr fr. πŸ’–

okay that's the whole page bestie, you ate that. this was taskopen v1.1.5, dated 2020-02-04, and it's taskopenrc(5) β€” now go configure something iconic. periodt. πŸ’…βœ¨πŸŒΈ

πŸ“¦ where this page comes from