2019-08-18 06:26:48 -07:00
|
|
|
#!/usr/bin/env fish
|
2019-07-27 05:30:14 -07:00
|
|
|
|
2019-06-24 06:23:58 -07:00
|
|
|
function fish_prompt
|
2019-08-15 20:39:12 -07:00
|
|
|
set _stat $status
|
2019-07-29 03:36:13 -07:00
|
|
|
echo -n (set_color 70a9ff)(date +%H:%M:%S)
|
2019-08-15 20:39:12 -07:00
|
|
|
echo -n (set_color normal)(
|
|
|
|
if test $_stat -eq 0
|
|
|
|
echo '@'
|
|
|
|
else
|
|
|
|
echo '!'
|
|
|
|
end)
|
2019-07-29 03:36:13 -07:00
|
|
|
echo -n (set_color c792ea)$hostname
|
|
|
|
echo (set_color normal)"% "
|
2019-06-24 06:23:58 -07:00
|
|
|
end
|
|
|
|
|
|
|
|
function fish_right_prompt
|
2019-07-29 03:36:13 -07:00
|
|
|
echo -n (set_color c3e88d)(pwd)
|
|
|
|
echo (set_color normal)
|
2019-06-24 06:23:58 -07:00
|
|
|
end
|
|
|
|
|
|
|
|
function fish_greeting
|
2020-08-02 10:56:00 -07:00
|
|
|
if test -f /usr/share/dict/words && test (which shuf) && test (which ruby)
|
2019-08-05 16:20:51 -07:00
|
|
|
set_color c50ed2
|
2019-06-25 16:13:32 -07:00
|
|
|
|
2020-01-07 07:41:44 -08:00
|
|
|
echo -n "Word of the moment: "(shuf -n1 /usr/share/dict/words) |
|
|
|
|
ruby -e 'puts $stdin.read.center ARGV[0].to_i' $COLUMNS
|
2019-06-25 16:13:32 -07:00
|
|
|
|
2019-08-05 16:20:51 -07:00
|
|
|
set_color normal
|
|
|
|
end
|
2019-06-24 06:23:58 -07:00
|
|
|
end
|
|
|
|
|
|
|
|
## EOF
|