From 6fe18fb699a5b63c3a6bd302675cbb05761a8a40 Mon Sep 17 00:00:00 2001 From: Hadi <112569860+anotherhadi@users.noreply.github.com> Date: Sat, 5 Apr 2025 14:22:06 +0200 Subject: [PATCH] init anyrun config Former-commit-id: 67bdbb09a33572b2e51c5e11de8339a22c966d5e --- home/programs/anyrun/default.nix | 90 ++++++++++++++++++++++++++++++++ 1 file changed, 90 insertions(+) create mode 100644 home/programs/anyrun/default.nix diff --git a/home/programs/anyrun/default.nix b/home/programs/anyrun/default.nix new file mode 100644 index 0000000..2343e8f --- /dev/null +++ b/home/programs/anyrun/default.nix @@ -0,0 +1,90 @@ +{ pkgs, inputs, ... }: { + imports = [ inputs.anyrun.homeManagerModules.default ]; + + programs.anyrun = { + enable = true; + + config = { + plugins = with inputs.anyrun.packages.${pkgs.system}; [ + applications + shell + randr + rink + symbols + translate + ]; + + width.fraction = 0.25; + y.fraction = 0.3; + hidePluginInfo = true; + closeOnClick = true; + }; + + extraCss = '' + * { + all: unset; + font-size: 1.2rem; + } + + #window, + #match, + #entry, + #plugin, + #main { + background: transparent; + } + + #match.activatable { + border-radius: 8px; + margin: 4px 0; + padding: 4px; + /* transition: 100ms ease-out; */ + } + #match.activatable:first-child { + margin-top: 12px; + } + #match.activatable:last-child { + margin-bottom: 0; + } + + #match:hover { + background: rgba(255, 255, 255, 0.05); + } + #match:selected { + background: rgba(255, 255, 255, 0.1); + } + + #entry { + background: rgba(255, 255, 255, 0.05); + border: 1px solid rgba(255, 255, 255, 0.1); + border-radius: 8px; + padding: 4px 8px; + } + + box#main { + background: rgba(0, 0, 0, 0.5); + box-shadow: + inset 0 0 0 1px rgba(255, 255, 255, 0.1), + 0 30px 30px 15px rgba(0, 0, 0, 0.5); + border-radius: 20px; + padding: 12px; + } + ''; + + extraConfigFiles = { + "applications.ron".text = '' + Config( + desktop_actions: false, + max_entries: 5, + terminal: Some("foot"), + ) + ''; + + "shell.ron".text = '' + Config( + prefix: ">" + ) + ''; + }; + }; +}