summaryrefslogtreecommitdiffstats
path: root/.config
diff options
context:
space:
mode:
authorMaks Jopek <maks@jopek.eu>2026-07-12 15:30:03 +0200
committerMaks Jopek <maks@jopek.eu>2026-07-12 15:30:03 +0200
commit497f40ed5a286e52383cc77e81aa1f49b74df925 (patch)
treeb22ecddb58d2bac5be1285f10f4e0e7e44db6690 /.config
parentcfe0107b0b47cff187ffef91d1ae6e4d5566b370 (diff)
parent0e8bd85602cbe3f894d0cf5b0ce8af5cda40fd66 (diff)
downloadeibhear-497f40ed5a286e52383cc77e81aa1f49b74df925.tar.gz
eibhear-497f40ed5a286e52383cc77e81aa1f49b74df925.tar.zst
eibhear-497f40ed5a286e52383cc77e81aa1f49b74df925.zip
Merge remote-tracking branch 'voidrice/master'HEADmaster
Diffstat (limited to '.config')
-rw-r--r--.config/firefox/larbs.js46
-rw-r--r--.config/lf/lfrc3
-rwxr-xr-x.config/lf/scope41
-rw-r--r--.config/shell/aliasrc7
4 files changed, 68 insertions, 29 deletions
diff --git a/.config/firefox/larbs.js b/.config/firefox/larbs.js
new file mode 100644
index 0000000..98c1bbd
--- /dev/null
+++ b/.config/firefox/larbs.js
@@ -0,0 +1,46 @@
+// These are changes made on top of the Arkenfox JS file to tweak it as
+// desired. Any of these settings can be overridden by the user.
+
+// Disable the Twitter/R*ddit/Faceberg ads in the URL bar:
+user_pref("browser.urlbar.suggest.topsites", false); // [FF78+]
+
+// Do not suggest web history in the URL bar:
+user_pref("browser.urlbar.suggest.history", false);
+
+// Do not prefil forms:
+user_pref("signon.prefillForms", false);
+
+// Do not autocomplete in the URL bar:
+user_pref("browser.urlbar.autoFill", false);
+
+// Enable the addition of search keywords:
+user_pref("keyword.enabled", true);
+
+// Allow access to http (i.e. not https) sites:
+user_pref("dom.security.https_only_mode", false);
+
+// Keep cookies until expiration or user deletion:
+user_pref("network.cookie.lifetimePolicy", 0);
+
+user_pref("dom.webnotifications.serviceworker.enabled", false);
+
+// Disable push notifications:
+user_pref("dom.push.enabled", false);
+
+// Disable the pocket antifeature:
+user_pref("extensions.pocket.enabled", false);
+
+// Don't autodelete cookies on shutdown:
+user_pref("privacy.clearOnShutdown.cookies", false);
+
+// Enable custom userChrome.js:
+user_pref("toolkit.legacyUserProfileCustomizations.stylesheets", true);
+
+// This could otherwise cause some issues on bank logins and other annoying sites:
+user_pref("network.http.referer.XOriginPolicy", 0);
+
+// Disable Firefox sync and its menu entries
+user_pref("identity.fxaccounts.enabled", false);
+
+// Fix the issue where right mouse button instantly clicks
+user_pref("ui.context_menus.after_mouseup", true);
diff --git a/.config/lf/lfrc b/.config/lf/lfrc
index d877ab6..d38f16a 100644
--- a/.config/lf/lfrc
+++ b/.config/lf/lfrc
@@ -30,7 +30,7 @@ set autoquit true
cmd open ${{
case $(file --mime-type "$(readlink -f $f)" -b) in
application/vnd.openxmlformats-officedocument.spreadsheetml.sheet) localc $fx ;;
- image/vnd.djvu|application/pdf|application/postscript) setsid -f zathura $fx >/dev/null 2>&1 ;;
+ image/vnd.djvu|application/vnd.djvu|application/pdf|application/postscript|application/epub*) setsid -f zathura $fx >/dev/null 2>&1 ;;
text/*|application/json|inode/x-empty|application/x-subrip) $EDITOR $fx;;
image/x-xcf) setsid -f gimp $f >/dev/null 2>&1 ;;
image/svg+xml) display -- $f ;;
@@ -43,7 +43,6 @@ cmd open ${{
;;
audio/*|video/x-ms-asf) mpv --audio-display=no $f ;;
video/*) setsid -f mpv $f -quiet >/dev/null 2>&1 ;;
- application/pdf|application/vnd.djvu|application/epub*) setsid -f zathura $fx >/dev/null 2>&1 ;;
application/pgp-encrypted) $EDITOR $fx ;;
application/vnd.openxmlformats-officedocument.wordprocessingml.document|application/vnd.oasis.opendocument.text|application/vnd.openxmlformats-officedocument.spreadsheetml.sheet|application/vnd.oasis.opendocument.spreadsheet|application/vnd.oasis.opendocument.spreadsheet-template|application/vnd.openxmlformats-officedocument.presentationml.presentation|application/vnd.oasis.opendocument.presentation-template|application/vnd.oasis.opendocument.presentation|application/vnd.ms-powerpoint|application/vnd.oasis.opendocument.graphics|application/vnd.oasis.opendocument.graphics-template|application/vnd.oasis.opendocument.formula|application/vnd.oasis.opendocument.database) setsid -f libreoffice $fx >/dev/null 2>&1 ;;
application/octet-stream) case ${f##*.} in
diff --git a/.config/lf/scope b/.config/lf/scope
index 332b07e..b55962f 100755
--- a/.config/lf/scope
+++ b/.config/lf/scope
@@ -18,43 +18,38 @@ image() {
# be regenerated once seen.
case "$(file --dereference --brief --mime-type -- "$1")" in
- image/avif) CACHE="${XDG_CACHE_HOME:-$HOME/.cache}/lf/thumb.$(stat --printf '%n\0%i\0%F\0%s\0%W\0%Y' -- "$(readlink -f "$1")" | sha256sum | cut -d' ' -f1)"
- [ ! -f "$CACHE" ] && magick "$1" "$CACHE.jpg"
+ image/avif) CACHE="${XDG_CACHE_HOME:-$HOME/.cache}/lf/thumb.$(stat --printf '%n\0%i\0%F\0%s\0%W\0%Y' -- "$(readlink -f "$1")" | md5sum)" CACHE="${CACHE%% *}"
+ [ ! -f "$CACHE.jpg" ] && magick "$1" "$CACHE.jpg"
image "$CACHE.jpg" "$2" "$3" "$4" "$5" "$1" ;;
image/vnd.djvu)
- CACHE="${XDG_CACHE_HOME:-$HOME/.cache}/lf/thumb.$(stat --printf '%n\0%i\0%F\0%s\0%W\0%Y' -- "$(readlink -f "$1")" | sha256sum | cut -d' ' -f1)"
- [ ! -f "$CACHE" ] && djvused "$1" -e 'select 1; save-page-with /dev/stdout' | magick -density 200 - "$CACHE.jpg" > /dev/null 2>&1
+ CACHE="${XDG_CACHE_HOME:-$HOME/.cache}/lf/thumb.$(stat --printf '%n\0%i\0%F\0%s\0%W\0%Y' -- "$(readlink -f "$1")" | md5sum)" CACHE="${CACHE%% *}"
+ [ ! -f "$CACHE.jpg" ] && djvused "$1" -e 'select 1; save-page-with /dev/stdout' | magick -density 200 - "$CACHE.jpg" > /dev/null 2>&1
+ image "$CACHE.jpg" "$2" "$3" "$4" "$5" "$1" ;;
+ image/svg+xml)
+ CACHE="${XDG_CACHE_HOME:-$HOME/.cache}/lf/thumb.$(stat --printf '%n\0%i\0%F\0%s\0%W\0%Y' -- "$(readlink -f "$1")" | md5sum)" CACHE="${CACHE%% *}"
+ [ ! -f "$CACHE.png" ] && inkscape --convert-dpi-method=none -o "$CACHE.png" --export-overwrite -D --export-png-color-mode=RGBA_16 "$1"
+ image "$CACHE.png" "$2" "$3" "$4" "$5" "$1" ;;
+ image/x-xcf)
+ CACHE="${XDG_CACHE_HOME:-$HOME/.cache}/lf/thumb.$(stat --printf '%n\0%i\0%F\0%s\0%W\0%Y' -- "$(readlink -f "$1")" | md5sum)" CACHE="${CACHE%% *}"
+ [ ! -f "$CACHE.jpg" ] && magick "$1[0]" "$CACHE.jpg"
image "$CACHE.jpg" "$2" "$3" "$4" "$5" "$1" ;;
-image/svg+xml)
- CACHE="${XDG_CACHE_HOME:-$HOME/.cache}/lf/thumb.$(stat --printf '%n\0%i\0%F\0%s\0%W\0%Y' -- "$(readlink -f "$1")" | sha256sum | cut -d' ' -f1)"
- [ ! -f "$CACHE" ] && inkscape --convert-dpi-method=none -o "$CACHE.png" --export-overwrite -D --export-png-color-mode=RGBA_16 "$1"
- image "$CACHE.png" "$2" "$3" "$4" "$5" "$1"
- ;;
- image/x-xcf)
- CACHE="${XDG_CACHE_HOME:-$HOME/.cache}/lf/thumb.$(stat --printf '%n\0%i\0%F\0%s\0%W\0%Y' -- "$(readlink -f "$1")" | sha256sum | awk '{print $1}')"
- [ ! -f "$CACHE.jpg" ] && magick "$1[0]" "$CACHE.jpg"
- image "$CACHE.jpg" "$2" "$3" "$4" "$5" "$1"
- ;;
image/*) image "$1" "$2" "$3" "$4" "$5" "$1" ;;
text/html) lynx -width="$4" -display_charset=utf-8 -dump "$1" ;;
text/troff) man ./ "$1" | col -b ;;
text/* | */xml | application/json | application/x-ndjson) bat -p --theme ansi --terminal-width "$(($4-2))" -f "$1" ;;
audio/* | application/octet-stream) mediainfo "$1" || exit 1 ;;
video/* )
- CACHE="${XDG_CACHE_HOME:-$HOME/.cache}/lf/thumb.$(stat --printf '%n\0%i\0%F\0%s\0%W\0%Y' -- "$(readlink -f "$1")" | sha256sum | cut -d' ' -f1)"
+ CACHE="${XDG_CACHE_HOME:-$HOME/.cache}/lf/thumb.$(stat --printf '%n\0%i\0%F\0%s\0%W\0%Y' -- "$(readlink -f "$1")" | md5sum)" CACHE="${CACHE%% *}"
[ ! -f "$CACHE" ] && ffmpegthumbnailer -i "$1" -o "$CACHE" -s 0
- image "$CACHE" "$2" "$3" "$4" "$5" "$1"
- ;;
+ image "$CACHE" "$2" "$3" "$4" "$5" "$1" ;;
*/pdf)
- CACHE="${XDG_CACHE_HOME:-$HOME/.cache}/lf/thumb.$(stat --printf '%n\0%i\0%F\0%s\0%W\0%Y' -- "$(readlink -f "$1")" | sha256sum | cut -d' ' -f1)"
+ CACHE="${XDG_CACHE_HOME:-$HOME/.cache}/lf/thumb.$(stat --printf '%n\0%i\0%F\0%s\0%W\0%Y' -- "$(readlink -f "$1")" | md5sum)" CACHE="${CACHE%% *}"
[ ! -f "$CACHE.jpg" ] && pdftoppm -jpeg -f 1 -singlefile "$1" "$CACHE"
- image "$CACHE.jpg" "$2" "$3" "$4" "$5" "$1"
- ;;
+ image "$CACHE.jpg" "$2" "$3" "$4" "$5" "$1" ;;
*/epub+zip|*/mobi*)
- CACHE="${XDG_CACHE_HOME:-$HOME/.cache}/lf/thumb.$(stat --printf '%n\0%i\0%F\0%s\0%W\0%Y' -- "$(readlink -f "$1")" | sha256sum | cut -d' ' -f1)"
+ CACHE="${XDG_CACHE_HOME:-$HOME/.cache}/lf/thumb.$(stat --printf '%n\0%i\0%F\0%s\0%W\0%Y' -- "$(readlink -f "$1")" | md5sum)" CACHE="${CACHE%% *}"
[ ! -f "$CACHE.jpg" ] && gnome-epub-thumbnailer "$1" "$CACHE.jpg"
- image "$CACHE.jpg" "$2" "$3" "$4" "$5" "$1"
- ;;
+ image "$CACHE.jpg" "$2" "$3" "$4" "$5" "$1" ;;
application/*zip) atool --list -- "$1" ;;
*opendocument*) odt2txt "$1" ;;
application/pgp-encrypted) gpg -d -- "$1" ;;
diff --git a/.config/shell/aliasrc b/.config/shell/aliasrc
index fe7c70c..2f11a5f 100644
--- a/.config/shell/aliasrc
+++ b/.config/shell/aliasrc
@@ -14,10 +14,9 @@ for command in mount umount sv pacman updatedb su shutdown poweroff reboot ; do
done; unset command
se() {
- s=("${HOME}/.local/bin/"**/*(.))
- c="$(print -lnr ${s:t:r} | fzf)"
- [[ "${c}" ]] && "${EDITOR}" ${${(M)s:#*/${c}*}[1]}
-}
+ choice="$(find ~/.local/bin -mindepth 1 -printf '%P\n' | fzf)"
+ [ -f "$HOME/.local/bin/$choice" ] && $EDITOR "$HOME/.local/bin/$choice"
+ }
# Verbosity and settings that you pretty much just always are going to want.
alias \