diff --git a/.Xresources b/.Xresources
index 14fcf52..3f70f0d 100644
--- a/.Xresources
+++ b/.Xresources
@@ -217,7 +217,7 @@ URxvt.keysym.C-equal: resize-font:reset
URxvt.keysym.C-question: resize-font:show
URxvt.keysym.M-s: searchable-scrollback:start
URxvt.resize-font.step: 2
-URxvt.refreshRate: 240
+URxvt.refreshRate: 60
! Base16 Eighties
! Scheme: Chris Kempson (http://chriskempson.com)
diff --git a/.config/i3/config b/.config/i3/config
index 436cd4c..8223449 100644
--- a/.config/i3/config
+++ b/.config/i3/config
@@ -371,10 +371,10 @@ exec --no-startup-id urxvtc -name newsboat -e newsboat
exec --no-startup-id redshift-gtk
exec --no-startup-id nm-applet
exec --no-startup-id system-config-printer-applet
-exec --no-startup-id sleep 1m && steam-native -silent -noverifyfiles -language french
+exec --no-startup-id steam-native -silent -noverifyfiles -language french
#exec --no-startup-id SVPManager
#exec --no-startup-id hp-systray -x
-exec --no-startup-id sleep 1m && play "$HOME/Musique/WELCOME BACK.wav"
+exec --no-startup-id sleep 20 && pamixer --set-volume 40 && play "$HOME/Musique/WELCOME BACK.wav"
exec --no-startup-id variety
#exec --no-startup-id sleep 5m && qbittorrent
diff --git a/.config/i3blocks/config b/.config/i3blocks/config
index 1b30b38..82b4a24 100644
--- a/.config/i3blocks/config
+++ b/.config/i3blocks/config
@@ -201,6 +201,10 @@ interval=60
[bepo]
interval=60
+separator=false
+
+[screen_freq]
+interval=once
[beep]
interval=once
diff --git a/.config/mpv/mpv.conf b/.config/mpv/mpv.conf
index 273fe54..ea587eb 100644
--- a/.config/mpv/mpv.conf
+++ b/.config/mpv/mpv.conf
@@ -1,5 +1,6 @@
# Vidéo
profile=gpu-hq
+gpu-context=x11vk
scale=ewa_lanczossharp
cscale=ewa_lanczossharp
#video-sync=display-resample
diff --git a/.i3blocks/bepo b/.i3blocks/bepo
index 7f62748..4386c62 100755
--- a/.i3blocks/bepo
+++ b/.i3blocks/bepo
@@ -13,8 +13,8 @@ runtime="${XDG_RUNTIME_DIR}/i3blocks"
case $button in
1) setxkbmap fr bepo_afnor; echo "bépo" > "$runtime/keyboard";;
#1) xmodmap ~/.Xmodmap; echo "bépo" > "$runtime/keyboard";;
- 2) setxkbmap fr oss; echo "oss " > "$runtime/keyboard";;
- 3) setxkbmap fr us; echo "qwer" > "$runtime/keyboard";;
+ 2) setxkbmap fr us; echo "qwer" > "$runtime/keyboard";;
+ 3) setxkbmap fr oss; echo "oss " > "$runtime/keyboard";;
esac
} &>/dev/null
cat "$runtime/keyboard"
diff --git a/.local/bin/mpd-notif b/.local/bin/mpd-notif
index 84ec580..a4419a6 100755
--- a/.local/bin/mpd-notif
+++ b/.local/bin/mpd-notif
@@ -4,7 +4,8 @@ export MPD_HOST="$HOME/.mpd/socket"
DUNST_ID=$(sum <<<"mpd" | cut -d' ' -f1)
# Déclaration des variables globales
-declare -- cursong prevsong
+declare -- prevfile
+declare -a -- infos
# Tant que le service MPD fonctionne
while systemctl --user is-active mpd.service &>/dev/null
@@ -12,24 +13,17 @@ do
# Toutes les 5 secondes, ou dès que le morceau se termine
timeout 5 mpc -w current
- prevsong="$cursong"
- cursong="$(mpc -f '[[%artist%\n|%name%\n]%title%[\n%album%]]|[%file%]' current)"
+ prevfile="${infos[3]}"
+ mapfile -t infos < <(mpc -f '[%artist%|%name%]\n%title%\n%album%\n%file%\n%time%' current)
# Si le morceau a changé depuis la dernière vérification
- if [[ "$cursong" != "$prevsong" && "$prevsong" != "Arrêt" ]]
+ if [[ "${infos[3]}" != "$prevfile" && "$title" != "Arrêt" ]]
then
- # Extractions des informations depuis la chaîne récupérée plus
- # tôt, vers un format plus lisible.
- artist="$(sed -n 1p <<<"$cursong")"
- title="$(sed -n 2p <<<"$cursong")"
- album="$(sed -n 3p <<<"$cursong")"
-
- # Petit trick : si le titre s’est retrouvé sur la première
- # ligne parce qu’il n’y a pas d’artiste renseigné, on corrige
- # le contenu des variables (pas forcément fiable, mais
- # chez moi ça marche™).
- [[ -z "$title" ]] && title="$artist" && artist=""
+ artist="${infos[0]}"
+ title="${infos[1]:-${infos[3]}}"
+ album="${infos[2]}"
+ length="$(( ${infos[4]%%:*} * 60 + ${infos[4]##*:} ))"
# Si on obtiens un chemin absolu, on n’affiche que le nom, pas
# le chemin.
@@ -37,21 +31,22 @@ do
# Si aucune information n’est retournée, c’est que la lecture
# s’est arrêtée.
- if [[ -z "$cursong" ]]
+ if [[ "${#infos[@]}" -eq 0 ]]
then
- cursong="Arrêt"
- unset artist title album
+ title="Arrêt"
+ unset artist title album length
fi
# Notification du morceau
- dunstify -r "$DUNST_ID" "MPD" "$cursong"
+ dunstify -r "$DUNST_ID" "MPD" "${artist:+${artist}$'\n'}${title}"$'\n'"${album}"
# Ajout au scrobbler Pleroma
- # curl -s -X POST -u "breizh:$(pass show Web/pleroma.breizh.pm)" \
- # --data-urlencode "title=${title}" \
- # --data-urlencode "artist=${artist}" \
- # --data-urlencode "album=${album}" \
- # https://pleroma.breizh.pm/api/v1/pleroma/scrobble &>/dev/null
+ curl -s -X POST -u "breizh:$(pass show Web/pleroma.breizh.pm)" \
+ --data-urlencode "title=${title}" \
+ --data-urlencode "artist=${artist}" \
+ --data-urlencode "album=${album}" \
+ --data-urlencode "length=${length}" \
+ https://pleroma.breizh.pm/api/v1/pleroma/scrobble &>/dev/null
fi
done
diff --git a/.xinitrc b/.xinitrc
index f0a4e11..7db52e5 100644
--- a/.xinitrc
+++ b/.xinitrc
@@ -35,6 +35,6 @@ fi
urxvtd -q -f -o
[ -f $HOME/.fehbg ] && $HOME/.fehbg
-[ -f $HOME/.screenlayout/home.sh ] && $HOME/.screenlayout/home.sh
+#[ -f $HOME/.screenlayout/home.sh ] && $HOME/.screenlayout/home.sh
exec i3 #--shmlog-size=26214400