1
Fork 0

anyrun stuff, no more minesweeper, hoogle search

This commit is contained in:
Matei Adriel 2023-08-22 18:24:04 +03:00
parent 78d0f94f1e
commit 30f0ea7eb5
No known key found for this signature in database
6 changed files with 24 additions and 16 deletions

View file

@ -20,7 +20,7 @@ let
}; };
satellite = { satellite = {
transparency.value = 0.6; transparency.value = 0.6;
rounding.radius = 8; rounding.radius = 8.0;
}; };
}; };
# }}} # }}}

View file

@ -60,7 +60,7 @@ in
search.engines = search.engines =
let let
# {{{ Search engine creation helpers # {{{ Search engine creation helpers
mkBasicSearchEngine = { aliases, url, param }: { mkBasicSearchEngine = { aliases, url, param, icon ? null }: {
urls = [{ urls = [{
template = url; template = url;
params = [ params = [
@ -69,19 +69,16 @@ in
}]; }];
definedAliases = aliases; definedAliases = aliases;
}; } // (if icon == null then { } else { inherit icon; });
mkNixPackagesEngine = { aliases, type }: mkNixPackagesEngine = { aliases, type }:
let basicEngine = mkBasicSearchEngine mkBasicSearchEngine
{ {
aliases = aliases; aliases = aliases;
url = "https://search.nixos.org/${type}"; url = "https://search.nixos.org/${type}";
param = "query"; param = "query";
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
}; };
in
basicEngine // {
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
};
# }}} # }}}
in in
# {{{ Engine declarations # {{{ Engine declarations
@ -102,6 +99,13 @@ in
aliases = [ "@ps" "@pursuit" ]; aliases = [ "@ps" "@pursuit" ];
}; };
"Hoogle" = mkBasicSearchEngine {
url = "https://hoogle.haskell.org";
param = "hoogle";
aliases = [ "@hg" "@hoogle" ];
};
"Wikipedia" = mkBasicSearchEngine { "Wikipedia" = mkBasicSearchEngine {
url = "https://en.wikipedia.org/wiki/Special:Search"; url = "https://en.wikipedia.org/wiki/Special:Search";
param = "search"; param = "search";

View file

@ -45,13 +45,13 @@
list#main, list#main,
row#match:selected { row#match:selected {
box-shadow: 0.5px 0.5px 1.5px 1.5px rgba(0, 0, 0, 0.5); box-shadow: 0.5px 0.5px 1.5px 1.5px rgba(0, 0, 0, 0.5);
border-radius: ${config.theming.rounding.radius}px; border-radius: ${toString config.satellite.theming.rounding.radius}px;
} }
#entry, #entry,
list#main { list#main {
margin: 1rem; margin: 1rem;
background: rgba(${config.theming.colors.rgba "base00"}); background: rgba(${config.satellite.theming.colors.rgba "base00"});
min-height: 1rem; min-height: 1rem;
} }
/* }}} */ /* }}} */

View file

@ -4,7 +4,7 @@
./dunst.nix ./dunst.nix
./wlsunset.nix ./wlsunset.nix
./wlogout.nix ./wlogout.nix
./anyrun ./anyrun.nix
../desktop/wezterm # Default hyprland terminal ../desktop/wezterm # Default hyprland terminal
../desktop/batsignal.nix ../desktop/batsignal.nix
../desktop/eww ../desktop/eww

View file

@ -1,4 +1,4 @@
{ { lib, ... }: {
imports = [ imports = [
../common/global ../common/global
../common/users/adrielus.nix ../common/users/adrielus.nix
@ -39,9 +39,13 @@
stylix.targets.gtk.enable = true; stylix.targets.gtk.enable = true;
# }}} # }}}
# {{{ Some ad-hoc site blocking # {{{ Some ad-hoc site blocking
networking.extraHosts = '' networking.extraHosts =
127.0.0.1 twitter.com let
''; blacklisted = [ "twitter.com" "minesweeper.online" ];
# 127.0.0.1 www.reddit.com blacklist = lib.concatStringsSep "\n" (lib.forEach blacklisted (host: "127.0.0.1 ${host}"));
in
blacklist;
# }}} # }}}
} }