Add optional mate session launch file
[khome.git] / home / .xlaunch.d / 99-dmesg-notifier-error
1 #! /bin/bash
2
3 set -e
4
5 DIR="$HOME/var/log/dmesg"
6 FILE="$DIR/error.log"
7
8 mkdir -p "$DIR"
9 sleep 3 # wait for dunst to hopefully restart
10 # TODO File with ignore patterns
11 sudo dmesg --follow --level=emerg,alert,crit,err --since=now --ctime \
12 | while read -r line
13 do
14 notify-send -u critical 'dmesg error' "$line"
15 echo "$line" >> "$FILE"
16 done
This page took 0.0905 seconds and 4 git commands to generate.