Reorganize fish scripts

work
Matthew Ess 2020-01-24 16:19:15 -05:00
parent 05068799c0
commit 35e33047e2
5 changed files with 23 additions and 12 deletions

View File

@ -51,6 +51,7 @@
fira-code fira-code
fira-code-symbols fira-code-symbols
font-awesome_5 font-awesome_5
aileron
]; ];
fontconfig = { fontconfig = {
enable = true; enable = true;

View File

@ -27,9 +27,10 @@ in {
# command line utilities # command line utilities
ag ag
fzy fzy
imagemagick
jq jq
tldr tldr
imagemagick unzip
# graphical applications # graphical applications
alacritty alacritty
atom atom
@ -68,9 +69,26 @@ in {
matthewess/fish-autovenv matthewess/fish-autovenv
''; '';
".config/fish/completions/systemctl.fish".source = ".config/fish/completions/systemctl.fish".source =
./scripts/systemctl.fish; ./assets/systemctl.fish;
".config/fish/functions/kbl.fish".source = ./scripts/kbl.fish; ".config/fish/functions/kbl.fish".text = ''
".config/fish/functions/mkdcd.fish".source = ./scripts/mkdcd.fish; function kbl -a level
set -l initial (cat /sys/class/leds/tpacpi\:\:kbd_backlight/brightness)
test -z "$level"; and set -l level $initial
echo $level > /sys/class/leds/tpacpi\:\:kbd_backlight/brightness
end
'';
".config/fish/functions/mkdcd.fish".text = ''
function mkdcd -a target
mkdir $target
cd $target
end
'';
".config/fish/functions/unz.fish".text = ''
function unz -a target
string match \*.zip $target; and set target (basename target)
unzip -d $target $target
end
'';
".config/i3status/config".text = '' ".config/i3status/config".text = ''
# i3status configuration file. # i3status configuration file.
# see "man i3status" for documentation. # see "man i3status" for documentation.

View File

@ -1,4 +0,0 @@
function kbl -a level
test -z "$level"; and set -l level (cat /sys/class/leds/tpacpi\:\:kbd_backlight/brightness)
echo $level > /sys/class/leds/tpacpi\:\:kbd_backlight/brightness
end

View File

@ -1,4 +0,0 @@
function mkdcd -a target
mkdir $target
cd $target
end