repositories

voidwalker.py

Penetration testing arsenal builder and workspace manager for macOS and Linux

clonegit clone https://git.daemon-sec.xyz/voidwalker.py.git
bspwmrc115 lines5.3 KiBraw download
#!/usr/bin/env bash
# bspwmrc — pentest-env Rose Pine BSPWM rice.
# Deployed to ~/.config/bspwm/bspwmrc (symlinked from the repo by setup-wm.sh).
# Executable: bspwm runs this on startup and every `bspc wm -r` reload.
#
# Palette mirrors config/config.sh (Rose Pine):
#   base #191724  surface #1f1d2e  overlay #26233a  muted #6e6a86
#   text #e0def4  love #eb6f92  gold #f6c177  rose #ebbcba
#   pine #31748f  foam #9ccfd8  iris #c4a7e7  hl_high #524f67

# --- helpers ----------------------------------------------------------------
# run CMD... : start CMD once, killing any stale instance first (idempotent
# across reloads so we don't stack duplicate picom/sxhkd/polybar processes).
run() { pgrep -x "$(basename "$1")" >/dev/null || "$@" & }

# --- monitors & desktops ----------------------------------------------------
# Six desktops, named numerically; Polybar maps each number to a Nerd-Font
# glyph (see polybar/config.ini). Robust if the icon font is missing.
# Spread desktops across every connected monitor (handles Parallels resize).
mons=$(bspc query -M --names)
i=1
for m in $mons; do
    case $i in
        1) bspc monitor "$m" -d 1 2 3 4 5 6 ;;
        *) bspc monitor "$m" -d 7 8 9 0 ;;
    esac
    i=$((i + 1))
done

# --- global layout ----------------------------------------------------------
bspc config border_width         2
bspc config window_gap          10
bspc config split_ratio          0.50
bspc config borderless_monocle   true
bspc config gapless_monocle      true
bspc config single_monocle       false
bspc config focus_follows_pointer true
bspc config pointer_follows_monitor true

# floating-polybar clearance: reserve space at the top so tiled windows sit
# BELOW the detached bar (struts aren't reserved when the bar width < 100%).
# ≈ bar offset-y(6) + height(30) − window_gap(10) + a little breathing room.
# Tune this if you change the bar's height/offset in polybar/config.ini.
bspc config top_padding 30

# --- borders (Rose Pine) ----------------------------------------------------
bspc config normal_border_color   "#26233a"   # overlay  — unfocused
bspc config active_border_color   "#403d52"   # hl_med   — focused, other monitor
bspc config focused_border_color  "#c4a7e7"   # iris     — focused window
bspc config presel_feedback_color "#9ccfd8"   # foam     — preselection

# --- window rules -----------------------------------------------------------
# desktop assignment for common pentest / daily apps; floaters for tools that
# behave badly when tiled. `bspc rule -a CLASS:INSTANCE ...`
bspc rule -a Alacritty           desktop='^1'
bspc rule -a firefox             desktop='^2'
bspc rule -a Firefox-esr         desktop='^2'
bspc rule -a Chromium            desktop='^2'
bspc rule -a 'Code'              desktop='^3'
bspc rule -a 'burp-StartBurp'    desktop='^4' state=tiled  # Burp Suite (JDK class)
bspc rule -a 'Burp Suite Community Edition' desktop='^4'
bspc rule -a Wireshark           desktop='^4'
bspc rule -a Thunar              desktop='^5'
bspc rule -a Pcmanfm             desktop='^5'
# floaters
bspc rule -a Pavucontrol         state=floating follow=on
bspc rule -a Blueman-manager     state=floating
bspc rule -a Nm-connection-editor state=floating
bspc rule -a Lxappearance        state=floating
bspc rule -a feh                 state=floating
bspc rule -a Galculator          state=floating
bspc rule -a 'Xfce4-appfinder'   state=floating
bspc rule -a Yad                 state=floating center=on

# --- autostart --------------------------------------------------------------
# kill leftovers from a previous session, then (re)launch the stack.
pgrep -x sxhkd >/dev/null && pkill -x sxhkd
run sxhkd                                    # hotkey daemon (sxhkdrc)
run picom --config "$HOME/.config/picom/picom.conf"   # compositor
run dunst                                    # notifications

# clipboard:
#  • Parallels Tools user agents = Mac<->VM shared clipboard inside a bare WM
#    (no DE to fire their XDG-autostart entries). Needs Parallels Tools installed
#    (sudo pt-install). Harmless no-ops if the binaries aren't present.
#  • clipmenud = local clipboard *history* daemon, popped via super+c (sxhkd).
for _prl in prlcc prldnd prlcp prlst; do
    command -v "$_prl" >/dev/null 2>&1 && run "$_prl"
done
command -v clipmenud >/dev/null 2>&1 && run clipmenud

# system-tray agents (populate the polybar tray) + GUI polkit auth agent
command -v nm-applet >/dev/null 2>&1 && run nm-applet --indicator
command -v lxpolkit  >/dev/null 2>&1 && run lxpolkit

# idle / suspend / manual screen lock via xss-lock -> i3lock (betterlockscreen if present)
if command -v xss-lock >/dev/null 2>&1; then
    xset s 300 5                              # blank/lock after 5 min idle
    _locker="i3lock -n -c 191724"
    command -v betterlockscreen >/dev/null 2>&1 && _locker="betterlockscreen -l"
    run xss-lock -- $_locker
fi

# wallpaper: prefer a user-dropped image, else a clean Rose Pine base fill.
if command -v feh >/dev/null 2>&1 && ls "$HOME/.config/bspwm/wallpaper".* >/dev/null 2>&1; then
    feh --no-fehbg --bg-fill "$HOME"/.config/bspwm/wallpaper.* &
else
    command -v xsetroot >/dev/null 2>&1 && xsetroot -solid '#191724'
fi

# hide the mouse cursor when idle (optional, no hard dep)
command -v unclutter >/dev/null 2>&1 && run unclutter --timeout 3

# status bar last (needs bspwm socket up)
"$HOME/.config/polybar/launch.sh" &