Files
dotfiles/profiles/desktop/.config/lf/previewer_sandbox
2026-02-13 04:20:30 +01:00

25 lines
599 B
Bash

#!/usr/bin/env bash
## ~/.config/lf/previewer_sandbox
set -euo pipefail
(
exec bwrap \
--ro-bind /usr/bin /usr/bin \
--ro-bind /usr/share/ /usr/share/ \
--ro-bind /usr/lib /usr/lib \
--ro-bind /usr/lib64 /usr/lib64 \
--symlink /usr/bin /bin \
--symlink /usr/bin /sbin \
--symlink /usr/lib /lib \
--symlink /usr/lib64 /lib64 \
--proc /proc \
--dev /dev \
--ro-bind /etc /etc \
--ro-bind ~/.config ~/.config \
--ro-bind ~/.cache ~/.cache \
--ro-bind "$PWD" "$PWD" \
--unshare-all \
--new-session \
ctpv "$@"
)