Refactoring des scripts des lancements d'environnements

This commit is contained in:
Hippolyte Chauvin 2023-10-24 11:24:43 +02:00
parent a6de14df91
commit 868e0476f0
3 changed files with 27 additions and 12 deletions

View file

@ -3,12 +3,16 @@
# cd to home
cd
if [ -z "$DBUS_SESSION_BUS_ADDRESS" ]; then
exec dbus-launch --exit-with-session "$0" "$@"
fi
if [ -z "$SSH_AGENT_PID" ]; then
exec ssh-agent "$0" "$@"
fi
# XDG
export XDG_CONFIG_HOME="${HOME}/.config"
# Execution
exec ssh-agent \
dbus-launch --exit-with-session \
/usr/bin/Hyprland \
"$@"
exec /usr/bin/Hyprland "$@"

View file

@ -1,8 +1,15 @@
#!/bin/sh -xe
# cd
cd
if [ -z "$DBUS_SESSION_BUS_ADDRESS" ]; then
exec dbus-launch --exit-with-session "$0" "$@"
fi
if [ -z "$SSH_AGENT_PID" ]; then
exec ssh-agent "$0" "$@"
fi
# Environment
# XDG
export \
@ -19,6 +26,4 @@ export \
MOZ_ENABLE_WAYLAND=1
# Execution
exec dbus-launch --exit-with-session \
ssh-agent /usr/bin/sway "$@"
exec /usr/bin/sway "$@"

View file

@ -1,10 +1,16 @@
#!/bin/sh
#!/bin/sh -xe
cd
if [ -z "$DBUS_SESSION_BUS_ADDRESS" ]; then
exec dbus-launch --exit-with-session ssh-agent "$0" "$@"
fi
cd
if [ -z "$SSH_AGENT_PID" ]; then
exec ssh-agent "$0" "$@"
fi
xfwm4 &
artix-pipewire-launcher &
artix-pipewire-launcher restart &
alacritty
wait