mirror of
https://github.com/donovanglover/nix-config.git
synced 2024-11-24 01:03:11 +01:00
qutebrowser: drop
No real reason to use qutebrowser now that I've written new-tab-identity and have LibreWolf programmed declaratively. The additional complexity of having another browser installed meant that I had to deal with a pyqt6 build error for an application I rarely used for a number of reasons (no https by default etc.)
This commit is contained in:
parent
54b018aa22
commit
4d90d5cbf0
@ -152,33 +152,6 @@
|
|||||||
echo "Done. Reduced file size from $ORIGINAL_SIZE to $NEW_SIZE"
|
echo "Done. Reduced file size from $ORIGINAL_SIZE to $NEW_SIZE"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
tmp = # fish
|
|
||||||
''
|
|
||||||
set MULLVAD_CACHE "/tmp/mullvad.json"
|
|
||||||
|
|
||||||
if not test -e $MULLVAD_CACHE
|
|
||||||
curl https://api.mullvad.net/www/relays/wireguard > $MULLVAD_CACHE
|
|
||||||
end
|
|
||||||
|
|
||||||
set CONTAINER_PROXY (random choice (cat $MULLVAD_CACHE | jq -r '.[] | select(.active) | select(.hostname | startswith("jp")) | .socks_name'))
|
|
||||||
set CONTAINER_ID "qtb-$(uuidgen)"
|
|
||||||
set SHORT (string split "." "$CONTAINER_PROXY" -f 1)
|
|
||||||
|
|
||||||
mkdir -p "/tmp/$CONTAINER_ID/config/bookmarks"
|
|
||||||
mkdir -p "/tmp/$CONTAINER_ID/data/userscripts"
|
|
||||||
|
|
||||||
ln -s ~/.config/qutebrowser/bookmarks/urls "/tmp/$CONTAINER_ID/config/bookmarks/urls"
|
|
||||||
ln -s ~/.config/qutebrowser/quickmarks "/tmp/$CONTAINER_ID/config/quickmarks"
|
|
||||||
|
|
||||||
TZ="Asia/Tokyo" lnch qutebrowser \
|
|
||||||
--set content.proxy "socks5://$CONTAINER_PROXY:1080" \
|
|
||||||
--set window.title_format "{perc}[$SHORT]{title_sep}{current_title}" \
|
|
||||||
--basedir "/tmp/$CONTAINER_ID" \
|
|
||||||
--config-py "$HOME/.config/qutebrowser/config.py" \
|
|
||||||
:adblock-update \
|
|
||||||
"$argv"
|
|
||||||
'';
|
|
||||||
|
|
||||||
ex = # fish
|
ex = # fish
|
||||||
''
|
''
|
||||||
if string match -qe -- ".part1." "$argv";
|
if string match -qe -- ".part1." "$argv";
|
||||||
|
@ -57,7 +57,7 @@ in
|
|||||||
"librewolf"
|
"librewolf"
|
||||||
"kitty"
|
"kitty"
|
||||||
"thunar"
|
"thunar"
|
||||||
"org.qutebrowser.qutebrowser"
|
"Chromium-browser"
|
||||||
"anki"
|
"anki"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
@ -8,7 +8,7 @@
|
|||||||
"text/plain" = "nvim.desktop";
|
"text/plain" = "nvim.desktop";
|
||||||
"image/png" = "pqiv.desktop";
|
"image/png" = "pqiv.desktop";
|
||||||
"image/jpeg" = "pqiv.desktop";
|
"image/jpeg" = "pqiv.desktop";
|
||||||
"image/gif" = "org.qutebrowser.qutebrowser.desktop";
|
"image/gif" = "pqiv.desktop";
|
||||||
"application/pdf" = "org.pwmt.zathura-pdf-mupdf.desktop";
|
"application/pdf" = "org.pwmt.zathura-pdf-mupdf.desktop";
|
||||||
"application/x-wine-extension-osz" = "osu-stable.desktop";
|
"application/x-wine-extension-osz" = "osu-stable.desktop";
|
||||||
"x-scheme-handler/http" = "librewolf.desktop";
|
"x-scheme-handler/http" = "librewolf.desktop";
|
||||||
|
@ -1,139 +0,0 @@
|
|||||||
{ config, ... }:
|
|
||||||
|
|
||||||
let
|
|
||||||
inherit (config.xdg.userDirs) download;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
programs.qutebrowser = {
|
|
||||||
enable = true;
|
|
||||||
|
|
||||||
settings = {
|
|
||||||
url = {
|
|
||||||
start_pages = [ "about:blank" ];
|
|
||||||
default_page = "about:blank";
|
|
||||||
};
|
|
||||||
|
|
||||||
colors.webpage.darkmode.enabled = false;
|
|
||||||
|
|
||||||
confirm_quit = [
|
|
||||||
"multiple-tabs"
|
|
||||||
"downloads"
|
|
||||||
];
|
|
||||||
|
|
||||||
session.lazy_restore = true;
|
|
||||||
|
|
||||||
tabs = {
|
|
||||||
show = "multiple";
|
|
||||||
mousewheel_switching = false;
|
|
||||||
last_close = "close";
|
|
||||||
new_position.unrelated = "next";
|
|
||||||
};
|
|
||||||
|
|
||||||
content = {
|
|
||||||
persistent_storage = true;
|
|
||||||
notifications.enabled = true;
|
|
||||||
register_protocol_handler = true;
|
|
||||||
mute = true;
|
|
||||||
headers.accept_language = "ja,en-US;q=0.9,en;q=0.8";
|
|
||||||
};
|
|
||||||
|
|
||||||
fileselect = {
|
|
||||||
handler = "external";
|
|
||||||
|
|
||||||
folder.command = [
|
|
||||||
"kitty"
|
|
||||||
"-e"
|
|
||||||
"yazi"
|
|
||||||
"--cwd-file"
|
|
||||||
"{}"
|
|
||||||
];
|
|
||||||
|
|
||||||
multiple_files.command = [
|
|
||||||
"kitty"
|
|
||||||
"-e"
|
|
||||||
"yazi"
|
|
||||||
"--chooser-file"
|
|
||||||
"{}"
|
|
||||||
];
|
|
||||||
|
|
||||||
single_file.command = [
|
|
||||||
"kitty"
|
|
||||||
"-e"
|
|
||||||
"yazi"
|
|
||||||
"--chooser-file"
|
|
||||||
"{}"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
downloads = {
|
|
||||||
location = {
|
|
||||||
directory = download;
|
|
||||||
prompt = false;
|
|
||||||
};
|
|
||||||
|
|
||||||
position = "bottom";
|
|
||||||
remove_finished = 5000;
|
|
||||||
};
|
|
||||||
|
|
||||||
qt = {
|
|
||||||
args = [
|
|
||||||
"disable-backing-store-limit"
|
|
||||||
"enable-accelerated-video-decode"
|
|
||||||
"disable-gpu-driver-bug-workarounds"
|
|
||||||
];
|
|
||||||
|
|
||||||
chromium.low_end_device_mode = "never";
|
|
||||||
};
|
|
||||||
|
|
||||||
editor.command = [
|
|
||||||
"kitty"
|
|
||||||
"-e"
|
|
||||||
"nvim"
|
|
||||||
"{}"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
keyBindings = {
|
|
||||||
normal = {
|
|
||||||
d = "scroll-page 0 0.5";
|
|
||||||
u = "scroll-page 0 -0.5";
|
|
||||||
D = "scroll-page 0 0.5";
|
|
||||||
U = "scroll-page 0 -0.5";
|
|
||||||
"<Alt+Left>" = "back";
|
|
||||||
"<Alt+Right>" = "forward";
|
|
||||||
"<Ctrl+Shift+Tab>" = "tab-prev";
|
|
||||||
"<Ctrl+Tab>" = "tab-next";
|
|
||||||
J = "tab-prev";
|
|
||||||
K = "tab-next";
|
|
||||||
"<F12>" = "devtools";
|
|
||||||
zb = "bookmark-del";
|
|
||||||
x = "tab-close";
|
|
||||||
X = "undo";
|
|
||||||
st = "config-cycle tabs.show multiple switching";
|
|
||||||
sTh = "set tabs.position left";
|
|
||||||
sTj = "set tabs.position bottom";
|
|
||||||
sTk = "set tabs.position top";
|
|
||||||
sTl = "set tabs.position right";
|
|
||||||
|
|
||||||
pp = null;
|
|
||||||
pP = null;
|
|
||||||
Pp = null;
|
|
||||||
PP = null;
|
|
||||||
wp = null;
|
|
||||||
wP = null;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
searchEngines = {
|
|
||||||
DEFAULT = "https://search.goo.ne.jp/web.jsp?MT={}";
|
|
||||||
};
|
|
||||||
|
|
||||||
extraConfig = # python
|
|
||||||
''
|
|
||||||
from qutebrowser.mainwindow import tabwidget
|
|
||||||
|
|
||||||
tabwidget.TabWidget.MUTE_STRING = ""
|
|
||||||
tabwidget.TabWidget.AUDIBLE_STRING = "[A]"
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
}
|
|
Loading…
Reference in New Issue
Block a user