diff --git a/housekeeping b/housekeeping index 1d40ae0..20ec2b6 100755 --- a/housekeeping +++ b/housekeeping @@ -6,4 +6,7 @@ WORK_ROOT="/home/nemo/projects/work/razorpay" find $WORK_ROOT -maxdepth 2 -type d -iname .git | xargs -I{} bash -c "cd {}/.. && karn update" PERSONAL_ROOT="/home/nemo/projects/personal" -find $PERSONAL_ROOT -maxdepth 2 -type d -iname .git | xargs -I{} bash -c "cd {}/.. && karn update" \ No newline at end of file +find $PERSONAL_ROOT -maxdepth 2 -type d -iname .git | xargs -I{} bash -c "cd {}/.. && karn update" + +# Cleanup yay-cache +find /home/nemo/.cache/yay -iregex '.*\.\(bz2\|tar\|zip\|deb\|xz\|gz\)$' -delete \ No newline at end of file diff --git a/lowbatterycron.sh b/lowbatterycron.sh index bddca00..84c7435 100755 --- a/lowbatterycron.sh +++ b/lowbatterycron.sh @@ -1,11 +1,17 @@ #!/bin/bash +# Add the following to your crontab to get this working +# DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus +# XAUTHORITY=/home/nemo/.Xauthority BATTINFO=`acpi -b` BATTERY=/sys/class/power_supply/BAT0 REM=`grep "POWER_SUPPLY_CHARGE_NOW" $BATTERY/uevent | awk -F= '{ print $2 }'` FULL=`grep "POWER_SUPPLY_CHARGE_FULL_DESIGN" $BATTERY/uevent | awk -F= '{ print $2 }'` PERCENT=`echo $(( $REM * 100 / $FULL ))` -if [[ `echo $BATTINFO | grep Discharging` && "$PERCENT" -lt "10" ]] ; then - DISPLAY=:0.0 /usr/bin/notify-send "low battery" "$BATTINFO" +echo "Battery is at $PERCENT%" + +if [[ `echo $BATTINFO | grep Discharging` && "$PERCENT" -lt "15" ]] ; then + echo "Not Charging, so alerting" + DISPLAY=:0.0 /usr/bin/notify-send --urgency=critical "Battery Running Low" "$BATTINFO" fi \ No newline at end of file diff --git a/mobile-pass-sync b/mobile-pass-sync new file mode 120000 index 0000000..33a6912 --- /dev/null +++ b/mobile-pass-sync @@ -0,0 +1 @@ +../personal/mobile-passwords/runme.sh \ No newline at end of file diff --git a/signcerts.sh b/signcerts.sh index 3267fe6..77260b1 100755 --- a/signcerts.sh +++ b/signcerts.sh @@ -4,7 +4,7 @@ set -euo pipefail export CF_DNS_SERVERS='1.1.1.1 9.9.9.9' # Based on https://gist.github.com/benkulbertis/fff10759c2391b6618dd/ -export CF_KEY=`gkeyring -n CF_KEY --output secret` +export CF_KEY=$(pass show CloudFlare/CF_KEY) export CF_EMAIL="capt.n3m0@gmail.com" dehydrated --cron \ No newline at end of file diff --git a/youtube-dl b/youtube-dl index fbc3288..4b5d39c 100755 Binary files a/youtube-dl and b/youtube-dl differ