mirror of
https://github.com/harish2704/dotFiles.git
synced 2026-09-10 07:11:09 +00:00
Minor fixes
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# Open space separated list of ssh logins in separate tabs ( using gnome-terminal )
|
||||||
sshInTabs(){
|
sshInTabs(){
|
||||||
logins="$@"
|
logins="$@"
|
||||||
for i in $logins; do
|
for i in $logins; do
|
||||||
@@ -8,19 +8,20 @@ sshInTabs(){
|
|||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Edit this file
|
||||||
edit(){
|
edit(){
|
||||||
vim ~/.local/Apps/daily-utils/bin/hari-tools.sh
|
vim ~/.local/bin/hari-tools.sh
|
||||||
}
|
}
|
||||||
|
|
||||||
## Convert text to wav
|
## Convert text to wav
|
||||||
genSound(){ echo $1 | espeak --stdout | ffmpeg -i - -ar 8000 -y $2.wav ; }
|
genSound(){ echo $1 | espeak --stdout | ffmpeg -i - -ar 8000 -y $2.wav ; }
|
||||||
|
|
||||||
|
# Clear sysrq keys which messing up with Window manager after switching to "raw mode"
|
||||||
clearSysRq(){
|
clearSysRq(){
|
||||||
sudo kbd_mode -s -C /dev/tty7
|
sudo kbd_mode -s -C /dev/tty7
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Show my public IP
|
||||||
myIp(){
|
myIp(){
|
||||||
curl 'https://api.ipify.org?format=json'
|
curl 'https://api.ipify.org?format=json'
|
||||||
}
|
}
|
||||||
@@ -34,6 +35,9 @@ block_dev_to_vmdk(){
|
|||||||
# Print sha256 fignerprint of ssh public keys
|
# Print sha256 fignerprint of ssh public keys
|
||||||
sshsha256(){ awk '{print $2}' $1 | base64 -d | sha256sum -b | awk '{print $1}' | xxd -r -p | base64 ; }
|
sshsha256(){ awk '{print $2}' $1 | base64 -d | sha256sum -b | awk '{print $1}' | xxd -r -p | base64 ; }
|
||||||
|
|
||||||
|
|
||||||
|
# Print all available commands if none was provided in commandline
|
||||||
|
|
||||||
cmd=$1
|
cmd=$1
|
||||||
shift
|
shift
|
||||||
allFunctions=$(typeset -F | cut -d ' ' -f 3 | grep -v '^_' | tr '\n' ' ' )
|
allFunctions=$(typeset -F | cut -d ' ' -f 3 | grep -v '^_' | tr '\n' ' ' )
|
||||||
|
|||||||
Reference in New Issue
Block a user