Settings

Theme

Show HN: Lightweight time-management CLI tool

github.com

72 points by liviu- · 20 comments

Reader

8 threads
atrudeau

I recently started using Timetrap ( https://github.com/samg/timetrap) and find fantastic. Covers a lot of corner cases while still being incredibly simple to use.

kickingvegas

On Unix/Linux you have "at" http://www.tldp.org/LDP/GNU-Linux-Tools-Summary/html/schedul.... For the Mac, however "at" is disabled (for battery saving reasons? or for working with laptops that sleep?) but you can turn it on.

luxpir

Excellent. Will investigate. Currently using espeak to call out pomodoros (among other things - weather, motivational quotes, reminders) at set times. But of course you tune out after a while. This might be a more flexible solution.

EDIT: CLI is the future :)

  • luxpir

    OK, based on the comment thread I'm now trying this:

        sleep 25m; espeak "Take a break!"; notify-send "Get a cup of coffee, stretch, ignore existential angst"
plicense

Consider using \b instead of printing a new line every time. I've a huge scrollback configured and it can silently crash my terminal given a large enough wake time!

rojobuffalo

This made me smile. I usually pop open the chrome timer or use my phone. I also just started trying out Strict Timer (chrome extension). As simple as these are, I think you've managed to reduce the motion necessary from the user to its absolute lowest level for a parameterized timer. Thanks for the tool.

grewil

Emacs package Chronos: https://libraries.io/emacs/chronos

pep_guardiola

Sweet! I saved the link. My intention is to take a look at the source code and then write my own ding-ding cli tool. It will be fun and I think it will give me a nice feeling when using it.

Thanks for the inspiration!

ams6110

> Around 100 LOC

Say what? To ring the bell after sleeping based on a parameter?

  • lgas

    To be fair it does slightly more than that (relative times, absolute times, etc) but it is somewhat ironic considering that it advertises itself as an alternative to one liners like "sleep 4231; beep".

  • zokier

    GNU sleep is around 150 loc, and does significantly less...

    • glandium

      GNU programs are not a reference. They must have usage(), and handle --help and --version. Even /bin/true.

        coreutils-8.25$ wc -l src/true.c
        80 src/true.c
      • liviu-OP

        Ding has `--version`, and a help message too :P

        To be honest, a big chunk of it is just handling user input and attempting to provide useful error messages.

Keyboard Shortcuts

j
Next item
k
Previous item
o / Enter
Open selected item
?
Show this help
Esc
Close modal / clear selection