Added better quoting.
This commit is contained in:
parent
64eafcb816
commit
57f7d3beb0
68
020_qtile.sh
68
020_qtile.sh
|
|
@ -29,11 +29,11 @@ QTILE_SCRIPTS=${QTILE_HOME}/scripts
|
|||
QTILE_SETTINGS_HOME=${CONFIG_HOME}/ml4w
|
||||
QTILE_SETTINGS=${QTILE_SETTINGS_HOME}/settings
|
||||
QTILE_THEME_CACHE=${QTILE_SETTINGS_HOME}/cache
|
||||
mkdir -p ${ROFI_HOME}
|
||||
mkdir -p ${QTILE_HOME}
|
||||
mkdir -p ${QTILE_SCRIPTS}
|
||||
mkdir -p ${QTILE_SETTINGS}
|
||||
mkdir -p ${QTILE_THEME_CACHE}
|
||||
mkdir -p "${ROFI_HOME}"
|
||||
mkdir -p "${QTILE_HOME}"
|
||||
mkdir -p "${QTILE_SCRIPTS}"
|
||||
mkdir -p "${QTILE_SETTINGS}"
|
||||
mkdir -p "${QTILE_THEME_CACHE}"
|
||||
|
||||
# x11-utils
|
||||
DEBIAN_XPROP_PATH="/usr/bin/xprop"
|
||||
|
|
@ -45,17 +45,17 @@ xprop=${DEBIAN_XPROP_PATH}
|
|||
|
||||
# Other settings
|
||||
git clone --depth 1 https://github.com/mylinuxforwork/dotfiles /var/tmp/ml4w_dotfiles/
|
||||
cp -a /var/tmp/ml4w_dotfiles/.config/ml4w/ ${QTILE_SETTINGS_HOME}
|
||||
cp -a /var/tmp/ml4w_dotfiles/.config/ml4w/ "${QTILE_SETTINGS_HOME}"
|
||||
|
||||
# Add the rofi configuration
|
||||
# https://davatorium.github.io/rofi/CONFIG/
|
||||
cp -a /var/tmp/ml4w_dotfiles/.config/rofi/* ${ROFI_HOME}
|
||||
cp -a /var/tmp/ml4w_dotfiles/.config/rofi/* "${ROFI_HOME}"
|
||||
|
||||
# Create the wallpaper directory and copy in the ml4w wallpapers
|
||||
# The ensure-wal sscript below will copy in just the default background if the
|
||||
# wallpaper directory is empty so you can comment this out.
|
||||
mkdir -p ${DEST}/wallpaper
|
||||
cp -a /var/tmp/ml4w_dotfiles/dotfiles/.config/ml4w/wallpapers/* ${DEST}/wallpaper
|
||||
mkdir -p "${DEST}/wallpaper"
|
||||
cp -a /var/tmp/ml4w_dotfiles/dotfiles/.config/ml4w/wallpapers/* "${DEST}/wallpaper"
|
||||
|
||||
# START: nested displays for configuration testing in X and Wayland
|
||||
# Test qtile in a xephyr nested server.
|
||||
|
|
@ -64,7 +64,7 @@ if [ -d "/usr/bin/Xephyr" ]; then
|
|||
fi
|
||||
|
||||
# https://raw.githubusercontent.com/qtile/qtile/refs/heads/master/scripts/wephyr
|
||||
conf_print_wephyr() {
|
||||
conf_print_xephyr() {
|
||||
cat <<-'EOF'
|
||||
#!/usr/bin/env python
|
||||
#
|
||||
|
|
@ -127,8 +127,8 @@ signal.signal(signal.SIGINT, noop)
|
|||
proc.wait()
|
||||
EOF
|
||||
}
|
||||
conf_print_xephyr | tee ${HOME}/.local/bin/qtile-start_wnested.sh
|
||||
chmod +x ${HOME}/.local/bin/qtile-start_wnested.sh
|
||||
conf_print_xephyr | tee "${HOME}/.local/bin/qtile-start_wnested.sh"
|
||||
chmod +x "${HOME}/.local/bin/qtile-start_wnested.sh"
|
||||
|
||||
# https://raw.githubusercontent.com/qtile/qtile/refs/heads/master/scripts/xephyr
|
||||
conf_print_xephyr_official() {
|
||||
|
|
@ -157,7 +157,7 @@ XEPHYR_PID=$!
|
|||
)
|
||||
EOF
|
||||
}
|
||||
conf_print_xephyr_official | sudo tee ${HOME}/.local/bin/qtile-start_xnested_official.sh
|
||||
conf_print_xephyr_official | sudo tee "${HOME}/.local/bin/qtile-start_xnested_official.sh"
|
||||
|
||||
# Working - two screens
|
||||
conf_print_xephyr() {
|
||||
|
|
@ -167,8 +167,8 @@ export DISPLAY=:1
|
|||
qtile start
|
||||
EOF
|
||||
}
|
||||
conf_print_xephyr | tee ${HOME}/.local/bin/qtile-start_xnested.sh
|
||||
chmod +x ${HOME}/.local/bin/qtile-start_xnested.sh
|
||||
conf_print_xephyr | tee "${HOME}/.local/bin/qtile-start_xnested.sh"
|
||||
chmod +x "${HOME}/.local/bin/qtile-start_xnested.sh"
|
||||
|
||||
# Add XDG path
|
||||
if [ -d "$HOME/.local/bin" ]; then
|
||||
|
|
@ -207,8 +207,8 @@ conf_print_xsession() {
|
|||
exec dbus-run-session -- ${DEST}/.local/bin/qtile start
|
||||
EOF
|
||||
}
|
||||
conf_print_xsession | tee ${DEST}/.xsession
|
||||
chmod +x ${DEST}/.xsession
|
||||
conf_print_xsession | tee "${DEST}/.xsession"
|
||||
chmod +x "${DEST}/.xsession"
|
||||
|
||||
# The default session for lightdm: named system sessions
|
||||
# xfce, qtile, or default etc from /usr/share/xsessions and
|
||||
|
|
@ -221,7 +221,7 @@ Language=en_GB.UTF-8
|
|||
Session=default
|
||||
EOF
|
||||
}
|
||||
conf_print_dmrc | tee ${DEST}/.dmrc
|
||||
conf_print_dmrc | tee "${DEST}/.dmrc"
|
||||
chmod 644 ~/.dmrc
|
||||
|
||||
conf_print_wayland_desktop() {
|
||||
|
|
@ -777,9 +777,9 @@ def autostart():
|
|||
subprocess.Popen([home])
|
||||
EOF
|
||||
}
|
||||
conf_print_config | tee ${QTILE_HOME}/config.py
|
||||
chmod 644 ${QTILE_HOME}/config.py
|
||||
sudo chown $USER:$USER ${QTILE_HOME}/qtile -R
|
||||
conf_print_config | tee "${QTILE_HOME}/config.py"
|
||||
chmod 644 "${QTILE_HOME}/config.py"
|
||||
sudo chown "$USER:$USER" "${QTILE_HOME}/qtile" -R
|
||||
|
||||
# initializing wallpaper cache to ensure startup
|
||||
conf_print_ensure_wal() {
|
||||
|
|
@ -814,8 +814,8 @@ wal -q -i "$WALLPAPER_DIR" >/dev/null 2>&1
|
|||
echo "[ensure_wal.sh] Pywal initialized → Qtile can start safely"
|
||||
EOF
|
||||
}
|
||||
conf_print_ensure_wal | tee ${QTILE_HOME}/scripts/ensure_wal.sh
|
||||
chmod +x ${QTILE_HOME}/scripts/ensure_wal.sh
|
||||
conf_print_ensure_wal | tee "${QTILE_HOME}/scripts/ensure_wal.sh"
|
||||
chmod +x "${QTILE_HOME}/scripts/ensure_wal.sh"
|
||||
|
||||
# autostart
|
||||
conf_print_autostart() {
|
||||
|
|
@ -850,7 +850,7 @@ dunst &
|
|||
$HOME/.config/qtile/scripts/wallpaper.sh init
|
||||
EOF
|
||||
}
|
||||
conf_print_autostart | tee ${QTILE_HOME}/autostart.sh
|
||||
conf_print_autostart | tee "${QTILE_HOME}/autostart.sh"
|
||||
|
||||
# qtile scripts
|
||||
conf_print_diagnosis() {
|
||||
|
|
@ -894,7 +894,7 @@ echo "Press return to exit"
|
|||
read
|
||||
EOF
|
||||
}
|
||||
conf_print_diagnosis | tee ${QTILE_HOME}/scripts/diagnosis.sh
|
||||
conf_print_diagnosis | tee "${QTILE_HOME}/scripts/diagnosis.sh"
|
||||
|
||||
conf_print_loadbar() {
|
||||
cat <<-'EOF'
|
||||
|
|
@ -906,7 +906,7 @@ conf_print_loadbar() {
|
|||
echo "Loading Qtile status bar..."
|
||||
EOF
|
||||
}
|
||||
conf_print_loadbar | tee ${QTILE_HOME}/scripts/loadbar.sh
|
||||
conf_print_loadbar | tee "${QTILE_HOME}/scripts/loadbar.sh"
|
||||
|
||||
conf_print_powermenu() {
|
||||
cat <<-'EOF'
|
||||
|
|
@ -942,7 +942,7 @@ $option4)
|
|||
esac
|
||||
EOF
|
||||
}
|
||||
conf_print_powermenu | tee ${QTILE_HOME}/scripts/powermenu.sh
|
||||
conf_print_powermenu | tee "${QTILE_HOME}/scripts/powermenu.sh"
|
||||
|
||||
conf_print_screenshot() {
|
||||
cat <<-'EOF'
|
||||
|
|
@ -978,7 +978,7 @@ case $choice in
|
|||
esac
|
||||
EOF
|
||||
}
|
||||
conf_print_screenshot | tee ${QTILE_HOME}/scripts/screenshot.sh
|
||||
conf_print_screenshot | tee "${QTILE_HOME}/scripts/screenshot.sh"
|
||||
|
||||
conf_print_wallpaper() {
|
||||
cat <<EOF
|
||||
|
|
@ -1010,7 +1010,7 @@ fi
|
|||
|
||||
current_wallpaper=\$(cat "\$cache_file")
|
||||
|
||||
case $1 in
|
||||
case \$1 in
|
||||
|
||||
# Load wallpaper from .cache of last session
|
||||
"init")
|
||||
|
|
@ -1074,16 +1074,16 @@ notify-send "Colors and Wallpaper updated" "with image \$newwall"
|
|||
echo "Done."
|
||||
EOF
|
||||
}
|
||||
conf_print_wallpaper | tee ${QTILE_HOME}/scripts/wallpaper.sh
|
||||
chmod +x ${QTILE_HOME}/scripts/wallpaper.sh
|
||||
conf_print_wallpaper | tee "${QTILE_HOME}/scripts/wallpaper.sh"
|
||||
chmod +x "${QTILE_HOME}/scripts/wallpaper.sh"
|
||||
|
||||
conf_print_browser() {
|
||||
cat <<-'EOF'
|
||||
|
||||
EOF
|
||||
}
|
||||
conf_print_wallpaper | tee ${QTILE_SCRIPTS}/browser.sh
|
||||
chmod +x ${QTILE_SCRIPTS}/browser.sh
|
||||
conf_print_browser | tee "${QTILE_SCRIPTS}/browser.sh"
|
||||
chmod +x "${QTILE_SCRIPTS}/browser.sh"
|
||||
|
||||
# END: ml4w_dotfiles
|
||||
|
||||
|
|
@ -1577,7 +1577,7 @@ conf_print_dunstrc() {
|
|||
# */
|
||||
EOF
|
||||
}
|
||||
conf_print_config | tee ${DEST}/.config/dunst/dunstrc
|
||||
conf_print_config | tee "${DEST}/.config/dunst/dunstrc"
|
||||
|
||||
# END: supporting app dotfiles
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue