first commit

This commit is contained in:
Chris Cochrun 2020-05-14 09:05:21 -05:00
commit 78b79e224f
239 changed files with 14912 additions and 0 deletions

1
rofi/bin/apps.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/apps.sh

1
rofi/bin/backlight.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/backlight.sh

1
rofi/bin/battery.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/battery.sh

1
rofi/bin/menu_apps.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/menu_apps.sh

1
rofi/bin/menu_backlight.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/menu_backlight.sh

1
rofi/bin/menu_battery.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/menu_battery.sh

1
rofi/bin/menu_mpd.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/menu_mpd.sh

1
rofi/bin/menu_network.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/menu_network.sh

1
rofi/bin/menu_powermenu.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/menu_powermenu.sh

1
rofi/bin/menu_quicklinks.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/menu_quicklinks.sh

1
rofi/bin/menu_screenshot.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/menu_screenshot.sh

1
rofi/bin/menu_time.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/menu_time.sh

1
rofi/bin/menu_volume.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/menu_volume.sh

1
rofi/bin/mpd.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/mpd.sh

1
rofi/bin/network.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/network.sh

1
rofi/bin/powermenu.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/powermenu.sh

1
rofi/bin/quicklinks.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/quicklinks.sh

1
rofi/bin/screenshot.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/screenshot.sh

1
rofi/bin/time.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/time.sh

53
rofi/bin/usedcpu Executable file
View file

@ -0,0 +1,53 @@
#!/bin/bash
# Source: http://askubuntu.com/a/450136
# I only slightly modify this script to add an option to show icon, useful for my tint2 executor
# Also useful for polybar custom script, dzen2 feeder, conkybar, lemonbar feeder, dunst notify, etc.
# 'usedcpu -i' = with icon, 'usedcpu' = text only
# Cheers!
# Addy
PREV_TOTAL=0
PREV_IDLE=0
cpuFile="/tmp/.cpu"
if [[ -f "${cpuFile}" ]]; then
fileCont=$(cat "${cpuFile}")
PREV_TOTAL=$(echo "${fileCont}" | head -n 1)
PREV_IDLE=$(echo "${fileCont}" | tail -n 1)
fi
CPU=(`cat /proc/stat | grep '^cpu '`) # Get the total CPU statistics.
unset CPU[0] # Discard the "cpu" prefix.
IDLE=${CPU[4]} # Get the idle CPU time.
# Calculate the total CPU time.
TOTAL=0
for VALUE in "${CPU[@]:0:4}"; do
let "TOTAL=$TOTAL+$VALUE"
done
if [[ "${PREV_TOTAL}" != "" ]] && [[ "${PREV_IDLE}" != "" ]]; then
# Calculate the CPU usage since we last checked.
let "DIFF_IDLE=$IDLE-$PREV_IDLE"
let "DIFF_TOTAL=$TOTAL-$PREV_TOTAL"
let "DIFF_USAGE=(1000*($DIFF_TOTAL-$DIFF_IDLE)/$DIFF_TOTAL+5)/10"
if [[ $1 = "-i" ]]; then
echo " ${DIFF_USAGE}%"
else
echo "${DIFF_USAGE}%"
fi
else
if [[ $1 = "-i" ]]; then
echo " ?"
else
echo "?"
fi
fi
# Remember the total and idle CPU times for the next check.
echo "${TOTAL}" > "${cpuFile}"
echo "${IDLE}" >> "${cpuFile}"

34
rofi/bin/usedram Executable file
View file

@ -0,0 +1,34 @@
#!/bin/bash
# this script is taken from screenfetch
# I only slightly modify this script to add an option to show icon, useful for my tint2 executor
# 'usedram -i' = with icon, 'usedram' = text only
# 'usedram -fi' = full summary with icon, 'usedram' = full summary text only
# Cheers!
# Addy
mem_info=$(</proc/meminfo)
mem_info=$(echo $(echo $(mem_info=${mem_info// /}; echo ${mem_info//kB/})))
for m in $mem_info; do
case ${m//:*} in
"MemTotal") usedmem=$((usedmem+=${m//*:})); totalmem=${m//*:} ;;
"ShMem") usedmem=$((usedmem+=${m//*:})) ;;
"MemFree"|"Buffers"|"Cached"|"SReclaimable") usedmem=$((usedmem-=${m//*:})) ;;
esac
done
usedmem=$((usedmem / 1024))
totalmem=$((totalmem / 1024))
mem="${usedmem}MB / ${totalmem}MB"
## Complete summary
if [[ $1 = "-fi" ]]; then
echo " $mem"
elif [[ $1 = "-f" ]]; then
echo "$mem"
## Only used RAM
elif [[ $1 = "-i" ]]; then
echo " $usedmem MB"
else
echo "$usedmem MB"
fi

1
rofi/bin/volume.sh Symbolic link
View file

@ -0,0 +1 @@
../scripts/volume.sh