aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastiano Tronto <sebastiano.tronto@gmail.com>2022-02-09 19:50:38 +0100
committerSebastiano Tronto <sebastiano.tronto@gmail.com>2022-02-09 19:50:38 +0100
commit6f45972265b532365421658f1370742bb82b757b (patch)
treec293262456ba35ae5c1b778684527ed5c70c7ad1
parent547311be5f6d90f36022a6e5e6fdbfb26862fd75 (diff)
downloadscripts-6f45972265b532365421658f1370742bb82b757b.tar.gz
scripts-6f45972265b532365421658f1370742bb82b757b.zip
Changed default notification system to herbe
Diffstat (limited to '')
-rw-r--r--Makefile1
-rwxr-xr-xbrightness9
-rwxr-xr-xdmenu-unmount4
-rwxr-xr-xmail-checknow5
-rwxr-xr-xnotify-battery8
-rwxr-xr-xnotify-time8
-rwxr-xr-xold/dunst-toggle (renamed from dunst-toggle)0
-rwxr-xr-xtogglemute8
-rwxr-xr-xvolume9
-rwxr-xr-xxwallpaper-random-notify7
10 files changed, 42 insertions, 17 deletions
diff --git a/Makefile b/Makefile
index 0e62fa4..dc6edfc 100644
--- a/Makefile
+++ b/Makefile
@@ -12,7 +12,6 @@ SCRIPTS = addressgrep \
12 dmenu-unmount \ 12 dmenu-unmount \
13 dmenu-urlselect \ 13 dmenu-urlselect \
14 dmenu-websearch \ 14 dmenu-websearch \
15 dunst-toggle \
16 mail-checknow \ 15 mail-checknow \
17 mail-compose \ 16 mail-compose \
18 notify-battery \ 17 notify-battery \
diff --git a/brightness b/brightness
index 46fd0a8..b2ff43a 100755
--- a/brightness
+++ b/brightness
@@ -1,7 +1,12 @@
1#!/bin/sh 1#!/bin/sh
2 2
3# Increase / decrease brightness, and pops up a notification 3# Increase / decrease brightness, and pops up a notification
4# Requires: xbacklight, notify-send 4# Requires: xbacklight, a notification program such as herbe or notify-send
5# Usage: brightness {inc|dec} n 5# Usage: brightness {inc|dec} n
6 6
7xbacklight -$1 $2 && notify-send "Brightness: $(xbacklight | sed 's/\..*$//')%" 7#notify="notify-send"
8notify="herbe"
9
10pkill herbe # comment this too if not using herbe
11
12xbacklight -$1 $2 && $notify "Brightness: $(xbacklight | sed 's/\..*$//')%"
diff --git a/dmenu-unmount b/dmenu-unmount
index c0b387a..2c59ec4 100755
--- a/dmenu-unmount
+++ b/dmenu-unmount
@@ -1,10 +1,10 @@
1#!/bin/sh 1#!/bin/sh
2 2
3# Prompts selection for mounted devices and unmounts the selected one 3# Prompts selection for mounted devices and unmounts the selected one
4# Requires: udevil, dmenu (or similar), notify-send (optional) 4# Requires: udevil, dmenu (or similar), notify-send or similar (optional)
5 5
6menu=${MENU:-dmenu} 6menu=${MENU:-dmenu}
7writeout="notify-send" # Change this to whatever you want, e.g. echo 7writeout=herbe # Change this to whatever you want, e.g. echo or notify-send
8 8
9listdev=$(grep "media" /proc/mounts | sed 's/\/media.*\///g' | \ 9listdev=$(grep "media" /proc/mounts | sed 's/\/media.*\///g' | \
10 awk '{print $1" ("$2")"}') 10 awk '{print $1" ("$2")"}')
diff --git a/mail-checknow b/mail-checknow
index 3363173..188042b 100755
--- a/mail-checknow
+++ b/mail-checknow
@@ -1,10 +1,11 @@
1#!/bin/sh 1#!/bin/sh
2 2
3# Check for new email, save result to file. 3# Check for new email, save result to file.
4# Requires: mpop, notify-send 4# Requires: mpop, notify-send or similar
5 5
6file="$XDG_DATA_HOME/newmail" 6file="$XDG_DATA_HOME/newmail"
7notify="notify-send" 7#notify="notify-send"
8notify=herbe
8 9
9l=$(cat "$file") 10l=$(cat "$file")
10n=$(mpop -s | awk '/new*./{print $2}') 11n=$(mpop -s | awk '/new*./{print $2}')
diff --git a/notify-battery b/notify-battery
index 0d26ef4..0294b70 100755
--- a/notify-battery
+++ b/notify-battery
@@ -1,4 +1,10 @@
1#!/bin/sh 1#!/bin/sh
2 2
3# Popup battery notification, based on the script battery-status 3# Popup battery notification, based on the script battery-status
4notify-send "Battery" "$(battery-status)" 4
5# Requires: notify-send or similar
6
7#notify=notify-send
8notify=herbe
9
10$notify "Battery" "$(battery-status)"
diff --git a/notify-time b/notify-time
index 1173bf0..39bc805 100755
--- a/notify-time
+++ b/notify-time
@@ -1,9 +1,13 @@
1#!/bin/sh 1#!/bin/sh
2 2
3# Little notification to show time and date 3# Little notification to show time and date
4# Requirements: notify-send 4
5# Requires: notify-send or similar
6
7#notify=notify-send
8notify=herbe
5 9
6t=$(date +"%H:%M:%S") 10t=$(date +"%H:%M:%S")
7d=$(date +"%d\ %B\ %Y,\ %A") 11d=$(date +"%d\ %B\ %Y,\ %A")
8 12
9notify-send "$t" "$d" 13$notify "$t" "$d"
diff --git a/dunst-toggle b/old/dunst-toggle
index 2de2343..2de2343 100755
--- a/dunst-toggle
+++ b/old/dunst-toggle
diff --git a/togglemute b/togglemute
index d952676..b799b02 100755
--- a/togglemute
+++ b/togglemute
@@ -1,7 +1,10 @@
1#!/bin/sh 1#!/bin/sh
2 2
3# Toggle mute state and notify 3# Toggle mute state and notify
4# Requires: pulsemixer, notify-send 4# Requires: pulsemixer, notify-send or similar
5
6#notify=notify-send
7notify=herbe
5 8
6ismute=$(pulsemixer --toggle-mute --get-mute) 9ismute=$(pulsemixer --toggle-mute --get-mute)
7 10
@@ -11,4 +14,5 @@ else
11 m="unmuted" 14 m="unmuted"
12fi 15fi
13 16
14notify-send "Audio $m" 17pkill herbe # comment this line too if not using herbe
18$notify "Audio $m"
diff --git a/volume b/volume
index 6852577..8dcd36a 100755
--- a/volume
+++ b/volume
@@ -2,9 +2,12 @@
2 2
3# Change volume and notify 3# Change volume and notify
4# Usage: volume {+n|-n} 4# Usage: volume {+n|-n}
5# Requires: pulsemixer, notify-send 5# Requires: pulsemixer, notify-send or similar
6 6
7#TODO: use this to replace myvolumeup/myvolumedown 7#notify=notify-send
8notify=herbe
8 9
9newvol=$(pulsemixer --change-volume "$1" --get-volume | awk '{print $1}') 10newvol=$(pulsemixer --change-volume "$1" --get-volume | awk '{print $1}')
10notify-send "Volume" "$newvol%" 11
12pkill herbe # comment this line too if not using herbe
13$notify "Volume" "$newvol%"
diff --git a/xwallpaper-random-notify b/xwallpaper-random-notify
index d0d1fbe..ac1898d 100755
--- a/xwallpaper-random-notify
+++ b/xwallpaper-random-notify
@@ -1,7 +1,10 @@
1#!/bin/sh 1#!/bin/sh
2 2
3# Set a random background from the wallpapers folder and notify about it 3# Set a random background from the wallpapers folder and notify about it
4# Requires: xwallpaper (or feh), notify-send (optional) 4# Requires: xwallpaper (or feh), notify-send or similar (optional)
5
6#notify=notify-send
7notify=herbe
5 8
6folder=~/Pictures/wallpapers 9folder=~/Pictures/wallpapers
7pic=$(ls $folder | sort -R | head -1) 10pic=$(ls $folder | sort -R | head -1)
@@ -10,4 +13,4 @@ pic=$(ls $folder | sort -R | head -1)
10#feh --bg-fill --no-fehbg $folder/$pic 13#feh --bg-fill --no-fehbg $folder/$pic
11xwallpaper --zoom $folder/$pic 14xwallpaper --zoom $folder/$pic
12 15
13notify-send "Background of the day" $pic 16$notify "Background of the day" $pic

Generated with cgit - Back to sebastiano.tronto.net