Compare commits

..

4 commits

Author SHA1 Message Date
2bfd250806
vanadium/xmonad: use firefox 2026-01-31 22:08:49 +01:00
ce446ffe39
vanadium/home: switch back to firefox
zen-browser wouldn't open anymore
2026-01-31 22:08:49 +01:00
9affd2771d
home/zen-browser: disable window syncing 2026-01-31 22:08:49 +01:00
895173460a
chore/manage: fix bug where nixpkgs store path is "" 2026-01-31 22:08:32 +01:00
5 changed files with 21 additions and 9 deletions

View file

@ -8,7 +8,7 @@ let
in
{
programs.firefox = {
enable = false;
enable = true;
policies.SearchEngines.Add = [
# Forges

View file

@ -350,7 +350,7 @@ keybinds =
)
-- Launcher
++ (let launchFirefox = "zen"
++ (let launchFirefox = "firefox"
launchDmenu = "dmenu_run -i -fn \"Iosevka-18\" -nb \"#36363a\" -nf \"#e2e2e4\" -sb \"#f7f7f8\" -sf \"#36363a\" -l 10"
lock = "xscreensaver-command -lock"
in [ ((controlMask .|. altMask, xK_m), namedScratchpadAction myScratchpads "cmus" )

View file

@ -8,7 +8,7 @@ let
in
{
programs.zen-browser = {
enable = true;
enable = false;
policies.SearchEngines.Add = [
# Forges

View file

@ -32,6 +32,10 @@ in
"zen.view.show-newtab-button-top" = false;
"zen.view.use-single-toolbar" = false;
"zen.tabs.ctrl-tab.ignore-pending-tabs" = true; # ctrl-tab ignore unloaded tabs
# https://github.com/zen-browser/desktop/discussions/12025
# This makes tabs sync across windows, which as annoying af
"zen.window-sync.enabled" = false;
};
}
];

View file

@ -23,14 +23,14 @@ main = do
) ->
manageArgs `showHelpOr` do
nixpkgs <- readNixpkgsPath
void $ readProcessFriendly "nixos-rebuild" (action : nixosRebuildArgs nixpkgs host <> extraArgs)
exitWith =<< transparentProcess "nixos-rebuild" (action : nixosRebuildArgs nixpkgs host <> extraArgs)
( "install" : host
: (partitionArgs -> (manageArgs, extraArgs))
) ->
manageArgs `showHelpOr` do
nixpkgs <- readNixpkgsPath
void $ readProcessFriendly "nixos-install" (nixosInstallArgs nixpkgs host <> extraArgs)
exitWith =<< transparentProcess "nixos-install" (nixosInstallArgs nixpkgs host <> extraArgs)
_ -> putStr help >> exitFailure
@ -79,8 +79,10 @@ quote x = "\"" <> x <> "\""
blueForeground :: String -> String
blueForeground x = "\ESC[34m" <> x <> "\ESC[0m"
readProcessFriendly :: String -> [String] -> IO String
readProcessFriendly cmdName args = do
-- |
-- Run with a shared std{in,out,err}
transparentProcess :: String -> [String] -> IO ExitCode
transparentProcess cmdName args = do
hPutStrLn stderr
$ "Executing: " <> (quote . blueForeground) (showCommandForUser cmdName args)
(_, _, _, pid) <- createProcess
@ -89,8 +91,13 @@ readProcessFriendly cmdName args = do
, std_out = UseHandle stdout
, std_err = UseHandle stderr
}
_ <- waitForProcess pid
pure ""
waitForProcess pid
readProcessFriendly :: String -> [String] -> String -> IO String
readProcessFriendly cmdName args inp = do
hPutStrLn stderr
$ "Executing: " <> (quote . blueForeground) (showCommandForUser cmdName args)
readProcess cmdName args inp
readNixpkgsPath :: IO StorePath
readNixpkgsPath =
@ -100,5 +107,6 @@ readNixpkgsPath =
, "-E"
, "let sources = import ./npins; in sources.nixpkgs.outPath"
]
""
where
clean = filter (\c -> c /= '\n' && c /= '"')