Add installation scripts

This commit is contained in:
2026-04-15 10:54:48 +02:00
parent 20c3536ae5
commit 49ab682669
21 changed files with 1002 additions and 1936 deletions

View File

@@ -132,6 +132,24 @@ fi
exec i3
#+end_src
* =setup-display= Script
:PROPERTIES:
:header-args:bash: :tangle ~/.local/bin/setup-display :mkdirp yes :tangle-mode (identity #o755) :comments none
:END:
Detects connected outputs and applies the appropriate =xrandr= configuration.
#+begin_src bash :shebang "#!/bin/bash"
# Desktop: DP-5 connected
if xrandr | grep -q "^DP-5 connected"; then
xrandr --output DP-5 --mode 2560x1440 --dpi 192
# Laptop: eDP-1 connected
elif xrandr | grep -q "^eDP-1 connected"; then
xrandr --output eDP-1 --mode 1920x1200 --dpi 192
fi
#+end_src
* =~/.xprofile=
:PROPERTIES:
:header-args: :tangle ~/.xprofile
@@ -149,7 +167,7 @@ setxkbmap -layout us -variant intl -option caps:escape &
Start programs related to display:
#+begin_src bash
# Screen options
xrandr --output eDP-1 --mode 1920x1200 --dpi 192 &
~/.local/bin/setup-display &
# Set random wallpaper
setbg ~/.local/data/wallpapers/ &
@@ -159,7 +177,8 @@ pgrep -xu "$USER" unclutter >/dev/null || \
unclutter --timeout 5 &
# Autolock screen after x minutes
xautolock -locker "~/.local/bin/lockscreen" -detectsleep -time 30 -notify 60 -notifier "notify-send -u critical -t 10000 -- 'Locking Screen' '60 seconds'" &
pgrep -xu "$USER" xautolock >/dev/null || \
xautolock -locker "~/.local/bin/lockscreen" -detectsleep -time 30 -notify 60 -notifier "dunstify --replace=31846 -u critical -t 10000 -- 'Locking Screen' '60 seconds'" &
# Redshift
pgrep -xu "$USER" redshift >/dev/null || \
@@ -176,15 +195,6 @@ blueman-applet &
# Udiskie - Automatic USB mount
udiskie --notify --automount --tray &
# Japanese input
# fcitx -d &
#+end_src
Manually start =mopidy= as it seems to not start automatically:
#+begin_src bash
# Mopidy
~/.local/soft/mopidy-jellyfin/env/bin/mopidy >/tmp/mopidy.log 2>&1 &
#+end_src
Finally, run SXHKD for the key bindings: