5 files changed,
32 insertions(+),
3 deletions(-)
Author:
Smirnov Oleksandr
ss2316544@gmail.com
Committed at:
2024-11-02 15:12:25 +0200
Parent:
72cc1a3
jump to
| A | bin/ex |
| A | bin/goclean |
| A | bin/kittyreload |
| A | bin/today |
| D | config/fish/functions/kitty_reload.fish |
A
bin/ex
@@ -0,0 +1,24 @@
+#!/usr/bin/env bash + +ex () { + file=$1 + [ -z "$file" ] && echo 'ex <compressed>' && return 1 + [ ! -f "$file" ] && echo 'Invalid file: `'"$file"'`' && return 1 + case "$file" in + *.tar.bz2) tar xjf "$file";; + *.tar.gz) tar xzf "$file";; + *.bz2) bunzip2 "$file";; + *.rar) unrar x "$file";; + *.gz) gunzip "$file";; + *.tar) tar xf "$file";; + *.tbz2) tar xjf "$file";; + *.tgz) tar xzf "$file";; + *.zip) unzip "$file";; + *.Z) uncompress "$file";; + *.7z) 7z x "$file";; + *.xz) unxz "$file";; + *) echo 'Unknown suffix on file: `'"$file"'`'; return 1 ;; + esac +} + +ex "$@"
A
bin/kittyreload
@@ -0,0 +1,2 @@
+#!/usr/bin/env bash +kill -SIGUSR1 "$(pidof kitty | awk '{ print $1 }')"
A
bin/today
@@ -0,0 +1,4 @@
+#!/usr/bin/env bash +p=$HOME/Documents/Syncthing/logseq/journals +d=$(date +%Y-%m-%d) +[ -d "$p" ] && exec nvim "$p/$d.md"
D
config/fish/functions/kitty_reload.fish
@@ -1,3 +0,0 @@
-function kitty_reload - kill -SIGUSR1 (pidof kitty | awk '{ print $1 }') -end