diff options
| -rwxr-xr-x | scripts/sarc.sh | 7 | ||||
| -rw-r--r-- | wm/dwm-6.3/config.h | 4 |
2 files changed, 10 insertions, 1 deletions
diff --git a/scripts/sarc.sh b/scripts/sarc.sh index f810fae..5c4baca 100755 --- a/scripts/sarc.sh +++ b/scripts/sarc.sh @@ -58,6 +58,11 @@ power() { *) exit 1 ;; esac } + +redshift_run() { + redshift -l $(curl -s "https://location.services.mozilla.com/v1/geolocate?key=geoclue" | jq -r '"\(.location.lat):\(.location.lng)"') +} + case $1 in --get_weather) rm -rf ~/.cache/weather_report @@ -65,6 +70,8 @@ case $1 in $sarc_terminal less -Srf ~/.cache/weather_report;; --search_web) search_web;; + --redshift) + redshift_run;; --unicode) get_unicode;; --power) power;; --goto-website) goto_website;; diff --git a/wm/dwm-6.3/config.h b/wm/dwm-6.3/config.h index 9032d8b..8d648c6 100644 --- a/wm/dwm-6.3/config.h +++ b/wm/dwm-6.3/config.h @@ -29,7 +29,7 @@ static const unsigned int alphas[][3] = { }; static const char *const autostart[] = { - "redshift_run", NULL, + "sarc.sh", "--redshift", NULL, "xsetroot", "-name", "Loading dwmblocks...", NULL, "dwmblocks", NULL, "fehbg", NULL, @@ -137,6 +137,8 @@ static Key keys[] = { { MODKEY|ShiftMask, XK_l, spawn, SHCMD("slock") }, { MODKEY|ShiftMask, XK_F9, spawn, SHCMD("amixer set Capture toggle") }, { MODKEY, XK_F1, spawn, SHCMD("xbacklight -dec 1; kill -44 $(pidof dwmblocks)") }, + { MODKEY, XK_z, spawn, SHCMD("passgen --generate") }, + { MODKEY|ShiftMask, XK_z, spawn, SHCMD("passgen --decrypt") }, { MODKEY, XK_F2, spawn, SHCMD("xbacklight -inc 1; kill -44 $(pidof dwmblocks)") }, { MODKEY, XK_p, spawn, SHCMD("nsxiv -t ~/Pictures") }, { MODKEY, XK_F12, spawn, SHCMD("sarc.sh --power") }, |