dotfiles

*nix config files
git clone git://git.pyratebeard.net/dotfiles.git
Log | Files | Refs | README

commit 04803766ccd5d2002c4eae1076ea9997f51a6edb
parent 365b76aa7af1b8229bf34e66a4b4c38dcf364df9
Author: pyratebeard <root@pyratebeard.net>
Date:   Tue, 21 May 2024 17:00:59 +0100

feat(zsh): lab alias and funcs. mkcd func. remove mail alias

Diffstat:
Mzsh/.config/zsh/aliases.zsh | 18+++++++++++++++++-
1 file changed, 17 insertions(+), 1 deletion(-)

diff --git a/zsh/.config/zsh/aliases.zsh b/zsh/.config/zsh/aliases.zsh @@ -187,7 +187,7 @@ command -v gmake >/dev/null && alias make='gmake' mixer="alsamixer" \ news="newsboat" \ gifview="gifview -a" \ - mail="mutt -F ~/.mutt/muttrc-imap" \ + lab="ssh pigley 'pcs'" \ \ headsetbatt="bluetooth_battery 34:DF:2A:5F:04:2C" \ headset="echo 'connect 34:DF:2A:5F:04:2C' | bluetoothctl" \ @@ -244,6 +244,22 @@ command -v gmake >/dev/null && alias make='gmake' pandoc -s -t man "$*" | man -l - } + mkcd() { + mkdir -p "$1" && cd "$1" + } + + labup() { + /usr/bin/wol 00:23:24:b3:03:cb + /usr/bin/wol 00:23:24:b5:75:61 + } + + labdown() { + ssh pigley 'for r in $(pcs resource --hide-inactive | awk "{print \$2}") ; do pcs resource disable --wait $r ; done' + for node in pigley goatley ; do + ssh $node "systemctl poweroff" + done + } + :q!() { [[ -v SSH_TTY ]] && echo dumpshock || { ping -q -c1 pigley >/dev/null 2>&1 && {