Be reminded to have lunch, directly in your prompt.
Messages are displayed in configurable time-intervals.
~/.config/sealion.conf
11:00 - 11:20 : lunch 11:20, in %m minutesThis will add a prompt reminder from 11:00 to 11:20 with the message "lunch 11:20, in N minutes", where N is the number of minutes left.
System installation:
git clone https://github.com/xyproto/sealion
cd sealion
sudo make install
User setup:
sealion-setup
sealion.confneeds to follow the existing format (using:and-in the appropriate places).- Comments in
sealion.confare allowed, as long as they are single-line comments starting with#. - If a description in
sealion.confcontains%m, it will be replaced with the number of minutes left when outputting the message.
Type on or off to enable or disable Sea Lion for the current shell session.
sealion-setup
- Python 3
bash,fishorzsh.
Simple case:
watch sealionFor updating every 5 seconds, with no title and highlighting any differences:
watch --color --differences --no-title --interval 5 sealionThe following is not normally needed, since sealion-setup handles this per user, but it helps to explain what is being set up by sealion-setup:
- Add the following to your
~/.bashrc:
# Sea Lion Prompt Reminder
on() {
export PROMPT_COMMAND="/usr/bin/sealion"
off() { unset PROMPT_COMMAND; }
}
# Enable prompt messages if on the right host and not over ssh
[ $HOSTNAME = "work_pc" ] && [ ! -n "$SSH_TTY" ] && on || true- NOTE: Change
work_pcto whatever the hostname of your work PC is.
- Add the following to your
~/.config/fish/config.fish:
# Sea Lion Prompt Reminder
function on
function sealion --on-event fish_prompt
/usr/bin/sealion
end
function off
functions -e sealion
end
end
# Enable prompt messages if on the right host and not over ssh
if [ (hostname) = "work_pc" ]; and not count $SSH_TTY > /dev/null; on; end- NOTE: Change
work_pcto whatever the hostname of your work PC is.
- Add the following to your
~/.zshrc:
# Sea Lion Prompt Reminder
on() {
precmd() { /usr/bin/sealion }
off() { unset -f precmd }
}
# Enable prompt messages if on the right host and not over ssh
[ "$HOST" = "work_pc" ] && [ ! -n "$SSH_TTY" ] && on || true- NOTE: Change
work_pcto whatever the hostname of your work PC is.
- Version: 2.0.1
- License: MIT
- Author: Alexander F. Rødseth <[email protected]>

