This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sdump () | |
{ | |
nm=$(diceware -n2 -d -); | |
xclip -o > clip_"($nm)".txt; | |
echo "Clipboard saved to clip_$nm.txt"; | |
echo -e "$(date)\nClipboard saved to clip_$nm.txt" > /dev/rfcomm0 | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
btpdfr () | |
{ | |
export BTPLINE="\n\n\n\x1b\x61\x01\x1d\x21\x01\x1b\x45\x01\x1d\x21\x10\x1d\x21\x20$(date +%A)\x1d\x21\x00\x1b\x45\x00\n"; | |
export BTPLINE=$BTPLINE"\n\n\n\x1b\x61\x01\x1d\x21\x01\x1b\x45\x01\x1d\x21\x10\x1d\x21\x20DF Report\x1d\x21\x00\x1b\x45\x00\n"; | |
export BTPLINE=$BTPLINE"\x1d\x21\x10\x1b\x61\x01$(date -I)\n"; | |
export BTPLINE=$BTPLINE"\x1d\x21\x10\x1b\x61\x01$(date +%X.%Z)\n"; | |
echo -e $BTPLINE > /dev/rfcomm0; | |
echo -e "\n\n\x1b\x61\x01\x1b\x45\x01\x1d\x21\x01\x1d\x21\x10\x1d\x21\x20--- btrfs ---\x1d\x21\x00\x1b\x45\x00\x1b\x61\x00\n" > /dev/rfcomm0; | |
df -h -t btrfs --output=target,pcent,avail,source --total > /dev/rfcomm0; | |
echo -e "\n\n\x1b\x61\x01\x1b\x45\x01\x1d\x21\x01\x1d\x21\x10\x1d\x21\x20--- xfs ---\x1d\x21\x00\x1b\x45\x00\x1b\x61\x00\n" > /dev/rfcomm0; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
uhist () | |
{ | |
history | grep --color=auto -i "$1" | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alias vsnazzy='export LS_COLORS="$(vivid generate snazzy)"' | |
alias vjbeans='export LS_COLORS="$(vivid generate jellybeans)"' | |
alias vayu='export LS_COLORS="$(vivid generate ayu)"' | |
alias vlava='export LS_COLORS="$(vivid generate lava)"' | |
alias v1dark='export LS_COLORS="$(vivid generate one-dark)"' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mutt mike@mikeybob.co.uk -s "install functions error" -a clip_Avid-Bogged.txt -- | |
Error in /home/mike/.muttrc, line 66: sidebar_non_empty_mailbox_only: unknown variable | |
Error in /home/mike/.muttrc, line 82: arrow_string: unknown variable | |
source: errors in /home/mike/.muttrc | |
Press any key to continue... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
multitail -Z red,black,inverse -T -x "%m %u@%h %f (%t) [%l]" -b 8 -m 0 -n 100 -f -cS my_fail2ban "/var/log/fail2ban.log" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
multitail -Z red,black,inverse -T -x "%m %u@%h %f (%t) [%l]" -b 8 -m 5000 -p w -n 5000 -f -cS postfix "/var/log/mail.log" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
multitail -Z red,black,inverse -T -x "%m %u@%h %f (%t) [%l]" -b 8 -m 0 -p s -n 100 -f -cS syslog -cS ssh "/var/log/syslog" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
head -n 2 -v clip*.txt > /dev/rfcomm0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Check if a directory path is provided as an argument | |
if [ "$#" -ne 1 ]; then | |
echo "Usage: $0 /path/to/directory" | |
exit 1 | |
fi | |
# Assign the first argument to dir_path | |
dir_path="$1" |
OlderNewer