duckland.org

TUI Challenge: Day 6

Day 6: Task Management

Another fairly easy day for me as I already mainly use TUI and CLI for task and calendar management.

Task management

                                Monthly Burndown
250 |
    |
    |           .
    |  .        .
    |  .  .  .  .           .  .
    |  .  .  .  .  .  .  .  .  .  .  .  .                              . Done
    |  .  .  .  .  .  .  .  .  .  .  .  .                              + Started
125 |  .  .  .  .  .  .  .  .  .  .  .  .                              X Pending
    |  .  .  .  .  .  .  .  .  .  .  X  .        .  .  .
    |  .  .  .  .  .  X  X  X  .  .  X  .  .  .  .  .  .  .  .
    |  X  X  X  X  X  X  X  X  X  X  X  .  X  X  X  X  X  .  .  .  .
    |  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  .  X  X  X
    |  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X
    |  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X
    |  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X  X
  0 +---------------------------------------------------------------
      10 11 12 01 02 03 04 05 06 07 08 09 10 11 12 01 02 03 04 05 06
      2023     2024                                2025

   Net Fix Rate:         1.8/d
   Estimated completion: 2025-08-03 (7w)

I have been using taskwarrior for years now. It is a simple command line tool for maintaining your task list. It stores its data in simple text files so backing it up is easy. I use a simple TUI called vit for viewing and interacting with my tasks.

I use taskwarrior for a mix of things I have to do for the family and work, and as a reminder system for websites, projects, and/or media I want to visit but I do not have time for. I even wrote a script to convert emails from neomutt or news articles from newsboat, a TUI RSS reader, to tasks:

#!/usr/bin/env bash
set -o nounset                              # Treat unset variables as an error

tmpfile=$(mktemp)
cat /dev/stdin > "${tmpfile}"

subj=$(grep -E ^'(Subject|Title)': "${tmpfile}" | sed  -e 's/^Subject: //' -e 's/^Title: //')

id=$(task add pri:H due:2d +email "${subj}" | grep ^Created | sed 's/^Created task \(.*\)./\1/')
cat "${tmpfile}" | onenote "${id}" -
echo "${id}"
rm -f "${tmpfile}"

I also have a daily report sent to me in email with my current top tasks, any due today or overdue, as well as my schedule over the next three days.

To keep all my tasks together, I use taskd which I run in a container..

Calendar

For managing my calendar, I use khal for my text based calendar. For the above mentioned reporting, I use khal to list my events. When I need a TUI, I use ikhal which is part of the khal package. This is a nice TUI with vim keys for navigation and gives me a great overview of my events.

I sync this using vdirsyncer to sync my calendars (and address book) with my NextCloud server. I use a custom vdirsyncer profile to sync NextCloud with Google for the shared family calendars.

Daily totals

After yesterday I have accrued 120 points. How does today help that score? Well, completion of task management and calendars nets 20 points, with 5 bonus points for syncing and 10 bonus points for scripting reports using these tools, for a total of 35 points today, and a running total of 155 points.

TUI Challenge: Day 5

Day 5: File management.

‘Wait!’ you say ‘You live at the terminal, what is wrong with ls, cp, or mv?’ Well, most of the time, that is fine, but there are times when I need to rename a bunch of files (cleaning up my MP3 collection) or quickly review some source files. In those cases, what do I use?

vifm

vifm is a ‘file manager with curses interface, which provides Vim-like environment for managing objects within file systems, extended with some useful ideas from mutt.’ When you start it up, you are great with a split window with directory listing on both side. Using the normal vi keys moving around. You can select multiple files, and then do things like mass rename or move the file to the other pane. Very quick and easy. I have used this to bulk rename mp3s in a directory to my new naming standard. I could write a script, but I have messed that up in the past, and part of why I need this type of tool to clean up.

ranger

ranger is a ‘VIM-inspired filemanager for the console’. This is a tri-pane arrangement Contents of the parent directory, current directory, details of what you are looking at. This last part is the useful part. If you have selected a directory, it will show the contents of the directory. If you are looking at a text file, it will show the contents of the file. The lets you review many files without using a pager or an editor to review the contents.

Daily totals

Score time! Yesterday left us with 105 points. On the score. Using a tui filemanager, 10 points. 5 points for the bulk renaming. I have done any scripting with these type of tools, so no more points there. Total today, 15 points, and a grand running total is now 120.

TUI Challenge: Day 4

Day 4: Let the music play!

The challenge is stream music from the terminal. Easy. I moved to self-hosting my music by using a server navidrome. I have been happy with this solution for a long time. I have a an android client which caches locally so I can listen on the go without killing my cell bill.

For the desktop, I have been using feishin which is an electron app. I stumbled across naviterm a couple of weeks ago. The author has been very receptive to issues and feature requests which is great. It connects to my navidrome server, and once I queue up a playlist, it hands off to mpv to play the music. Works like a treat. It also supports the same DBUS protocol that playerctl supports so none of my scripts to display current song or change or pause songs needed to change to use it.

Daily totals

Score time! Yesterday left us with 80 points. Scoring today is pretty easy. 10 points for playing music, 5 for creating a playlist (I have over 50), and 10 for streaming the music. So, 25 points today added to the 80 from yesterday gives us 105.