diff options
author | dx <aryadevchavali1@gmail.com> | 2020-07-15 15:34:53 +0100 |
---|---|---|
committer | dx <aryadevchavali1@gmail.com> | 2020-07-15 15:34:53 +0100 |
commit | b41c6dfec4db0a8395d72a76b37d842a2b1221a4 (patch) | |
tree | 18e431dd8e27facb1e49053c321292e4d3afacb1 /Scripts/.local/scripts | |
parent | e2cede510bab6f4d8a29d4bef4c4bc71d739bd9d (diff) | |
download | dotfiles-b41c6dfec4db0a8395d72a76b37d842a2b1221a4.tar.gz dotfiles-b41c6dfec4db0a8395d72a76b37d842a2b1221a4.tar.bz2 dotfiles-b41c6dfec4db0a8395d72a76b37d842a2b1221a4.zip |
~clean up scripts
Remove any redundant info, only leaving what is absolutely necessary.
Diffstat (limited to 'Scripts/.local/scripts')
-rwxr-xr-x | Scripts/.local/scripts/eserver | 2 | ||||
-rwxr-xr-x | Scripts/.local/scripts/status/connection | 4 | ||||
-rwxr-xr-x | Scripts/.local/scripts/status/memory | 2 | ||||
-rwxr-xr-x | Scripts/.local/scripts/status/music | 2 | ||||
-rwxr-xr-x | Scripts/.local/scripts/status/uptime_status | 2 |
5 files changed, 6 insertions, 6 deletions
diff --git a/Scripts/.local/scripts/eserver b/Scripts/.local/scripts/eserver index b613bba..309df99 100755 --- a/Scripts/.local/scripts/eserver +++ b/Scripts/.local/scripts/eserver @@ -6,7 +6,7 @@ then eserver start elif [ $1 = "start" ] then - if [ -e "/tmp/emacs-server-id" ] + if [ -e "/tmp/emacs-server" ] then echo "Server running already!" else diff --git a/Scripts/.local/scripts/status/connection b/Scripts/.local/scripts/status/connection index 94eb929..c201582 100755 --- a/Scripts/.local/scripts/status/connection +++ b/Scripts/.local/scripts/status/connection @@ -3,7 +3,7 @@ internet=$(nmcli g | sed -n 2p | awk '{print $1}') if [[ $internet == "connected" ]] then - echo " Connected" + echo "" else - echo " Not connected" + echo "" fi diff --git a/Scripts/.local/scripts/status/memory b/Scripts/.local/scripts/status/memory index eeaf7af..9f50677 100755 --- a/Scripts/.local/scripts/status/memory +++ b/Scripts/.local/scripts/status/memory @@ -3,5 +3,5 @@ line=$(free -m | sed -n 2p); used=$(echo $line | awk '{print $3}'); available=$(echo $line | awk '{print $2}'); -echo "100 * $used / $available" | bc -l | xargs printf " Mem: %.2f" $1 +echo "100 * $used / $available" | bc -l | xargs printf " %.2f" $1 echo "%" diff --git a/Scripts/.local/scripts/status/music b/Scripts/.local/scripts/status/music index 15c9ea3..8231c04 100755 --- a/Scripts/.local/scripts/status/music +++ b/Scripts/.local/scripts/status/music @@ -5,6 +5,6 @@ if [[ $offline ]] then name="MPD off" else - name="Playing: $name" + name="$name" fi echo $name diff --git a/Scripts/.local/scripts/status/uptime_status b/Scripts/.local/scripts/status/uptime_status index ff44048..7863fda 100755 --- a/Scripts/.local/scripts/status/uptime_status +++ b/Scripts/.local/scripts/status/uptime_status @@ -1,3 +1,3 @@ #!/usr/bin/env bash -echo Uptime: $(uptime --pretty | sed 's/up//;s/ //') +echo $(uptime --pretty | sed 's/up//;s/ //') |