foot, vintage fonts, scope operator

This commit is contained in:
atagen 2025-08-12 15:47:26 +10:00
parent 8d77e96d89
commit 5575604452
46 changed files with 803 additions and 702 deletions

View file

@ -1,25 +1,26 @@
{
pkgs,
getPkgs,
...
}:
{
environment.systemPackages = builtins.attrValues {
environment.systemPackages = getPkgs {
inherit (pkgs)
curl
eza
git
;
};
home.packages = builtins.attrValues {
inherit (pkgs)
btop
bat
ripgrep
fd
lazygit
zoxide
zellij
ouch
;
};
home.packages = getPkgs {
inherit (pkgs)
lazygit
zoxide
zellij
;
};
}

View file

@ -1,6 +1,6 @@
{ pkgs, ... }:
{ pkgs, getPkgs, ... }:
{
environment.systemPackages = builtins.attrValues {
environment.systemPackages = getPkgs {
inherit (pkgs)
man-pages
man-pages-posix

View file

@ -2,253 +2,252 @@
inputs,
pkgs,
config,
scope,
...
}:
let
inherit (config) rice;
pal = rice.palette.hex;
in
{
hm.programs.helix = {
enable = true;
package = inputs.helix.packages.${pkgs.system}.helix;
themes = with pal; {
nix-rice = {
"attribute" = bright.cyan;
"keyword" = {
fg = normal.red;
};
"keyword.directive" = normal.red;
"namespace" = bright.cyan;
"punctuation" = bright.yellow;
"punctuation.delimiter" = bright.yellow;
"operator" = bright.magenta;
"special" = normal.magenta;
"variable.other.member" = bright.blue;
"variable" = util.fg;
"variable.builtin" = bright.yellow;
"variable.parameter" = bright.white;
"type" = normal.yellow;
"type.builtin" = normal.yellow;
"constructor" = {
fg = bright.magenta;
modifiers = [ "bold" ];
};
"function" = {
fg = normal.green;
modifiers = [ "bold" ];
};
"function.macro" = bright.cyan;
"function.builtin" = normal.yellow;
"tag" = normal.red;
"comment" = {
fg = normal.magenta;
modifiers = [ "italic" ];
};
"constant" = {
fg = bright.magenta;
};
"constant.builtin" = {
fg = bright.magenta;
modifiers = [ "bold" ];
};
"string" = normal.green;
"constant.numeric" = bright.magenta;
"constant.character.escape" = {
fg = bright.white;
modifiers = [ "bold" ];
};
"label" = bright.cyan;
"module" = bright.cyan;
"diff.plus" = bright.green;
"diff.delta" = bright.yellow;
"diff.minus" = bright.red;
"warning" = bright.yellow;
"error" = bright.red;
"info" = bright.cyan;
"hint" = bright.blue;
"ui.background" = {
inherit (util) bg;
};
"ui.linenr" = {
fg = normal.cyan;
};
"ui.linenr.selected" = {
fg = normal.yellow;
modifiers = [ "bold" ];
};
"ui.cursorline" = {
bg = normal.black;
};
"ui.statusline" = {
inherit (util) fg;
bg = bright.black;
};
"ui.statusline.normal" = {
inherit (util) fg;
bg = bright.black;
};
"ui.statusline.insert" = {
inherit (util) fg;
bg = normal.blue;
};
"ui.statusline.select" = {
inherit (util) fg;
bg = bright.yellow;
};
"ui.statusline.inactive" = {
fg = normal.white;
bg = normal.black;
};
"ui.popup" = {
bg = normal.black;
};
"ui.window" = {
bg = normal.black;
};
"ui.help" = {
bg = normal.black;
inherit (util) fg;
};
"ui.text" = {
inherit (util) fg;
};
"ui.text.focus" = {
inherit (util) fg;
};
"ui.selection" = {
# modifiers = ["reversed"];
bg = bright.yellow;
};
"ui.selection.primary" = {
modifiers = [ "reversed" ];
};
# "ui.selection.primary" = { bg = bright.cyan; };
"ui.cursor.primary" = {
bg = normal.white;
fg = normal.black;
};
"ui.cursor.match" = {
bg = bright.cyan;
};
"ui.menu" = {
inherit (util) fg;
bg = bright.black;
};
"ui.menu.selected" = {
fg = bright.black;
bg = bright.blue;
modifiers = [ "bold" ];
};
"ui.virtual.whitespace" = bright.black;
"ui.virtual.ruler" = {
bg = normal.black;
};
"ui.virtual.inlay-hint" = {
fg = normal.magenta;
};
"diagnostic.warning" = {
underline = {
color = bright.yellow;
style = "curl";
};
};
"diagnostic.error" = {
underline = {
color = bright.red;
style = "curl";
};
};
"diagnostic.info" = {
underline = {
color = bright.cyan;
style = "curl";
};
};
"diagnostic.hint" = {
underline = {
color = bright.blue;
style = "curl";
};
};
"markup.heading" = bright.cyan;
"markup.bold" = {
modifiers = [ "bold" ];
};
"markup.italic" = {
modifiers = [ "italic" ];
};
"markup.strikethrough" = {
modifiers = [ "crossed_out" ];
};
"markup.link.url" = {
fg = bright.green;
modifiers = [ "underlined" ];
};
"markup.link.text" = bright.red;
"markup.raw" = bright.red;
scope "hm.programs.helix" {
enable = true;
package = inputs.helix.packages.${pkgs.system}.helix;
themes = with pal; {
nix-rice = {
"attribute" = bright.cyan;
"keyword" = {
fg = normal.red;
};
};
# theme = "nix-rice"
settings = {
theme = "nix-rice";
editor = {
bufferline = "multiple";
cursorline = true;
true-color = true;
cursor-shape = {
insert = "bar";
normal = "block";
select = "underline";
};
statusline.left = [
"mode"
"spinner"
"version-control"
"file-name"
"file-modification-indicator"
];
lsp.display-messages = true;
"keyword.directive" = normal.red;
"namespace" = bright.cyan;
"punctuation" = bright.yellow;
"punctuation.delimiter" = bright.yellow;
"operator" = bright.magenta;
"special" = normal.magenta;
"variable.other.member" = bright.blue;
"variable" = util.fg;
"variable.builtin" = bright.yellow;
"variable.parameter" = bright.white;
"type" = normal.yellow;
"type.builtin" = normal.yellow;
"constructor" = {
fg = bright.magenta;
modifiers = [ "bold" ];
};
"function" = {
fg = normal.green;
modifiers = [ "bold" ];
};
"function.macro" = bright.cyan;
"function.builtin" = normal.yellow;
"tag" = normal.red;
"comment" = {
fg = normal.magenta;
modifiers = [ "italic" ];
};
"constant" = {
fg = bright.magenta;
};
"constant.builtin" = {
fg = bright.magenta;
modifiers = [ "bold" ];
};
"string" = normal.green;
"constant.numeric" = bright.magenta;
"constant.character.escape" = {
fg = bright.white;
modifiers = [ "bold" ];
};
"label" = bright.cyan;
"module" = bright.cyan;
"diff.plus" = bright.green;
"diff.delta" = bright.yellow;
"diff.minus" = bright.red;
"warning" = bright.yellow;
"error" = bright.red;
"info" = bright.cyan;
"hint" = bright.blue;
"ui.background" = {
inherit (util) bg;
};
"ui.linenr" = {
fg = normal.cyan;
};
"ui.linenr.selected" = {
fg = normal.yellow;
modifiers = [ "bold" ];
};
"ui.cursorline" = {
bg = normal.black;
};
"ui.statusline" = {
inherit (util) fg;
bg = bright.black;
};
"ui.statusline.normal" = {
inherit (util) fg;
bg = bright.black;
};
"ui.statusline.insert" = {
inherit (util) fg;
bg = normal.blue;
};
"ui.statusline.select" = {
inherit (util) fg;
bg = bright.yellow;
};
"ui.statusline.inactive" = {
fg = normal.white;
bg = normal.black;
};
"ui.popup" = {
bg = normal.black;
};
"ui.window" = {
bg = normal.black;
};
"ui.help" = {
bg = normal.black;
inherit (util) fg;
};
"ui.text" = {
inherit (util) fg;
};
"ui.text.focus" = {
inherit (util) fg;
};
"ui.selection" = {
# modifiers = ["reversed"];
bg = bright.yellow;
};
"ui.selection.primary" = {
modifiers = [ "reversed" ];
};
# "ui.selection.primary" = { bg = bright.cyan; };
"ui.cursor.primary" = {
bg = normal.white;
fg = normal.black;
};
"ui.cursor.match" = {
bg = bright.cyan;
};
"ui.menu" = {
inherit (util) fg;
bg = bright.black;
};
"ui.menu.selected" = {
fg = bright.black;
bg = bright.blue;
modifiers = [ "bold" ];
};
"ui.virtual.whitespace" = bright.black;
"ui.virtual.ruler" = {
bg = normal.black;
};
"ui.virtual.inlay-hint" = {
fg = normal.magenta;
};
"diagnostic.warning" = {
underline = {
color = bright.yellow;
style = "curl";
};
};
"diagnostic.error" = {
underline = {
color = bright.red;
style = "curl";
};
};
"diagnostic.info" = {
underline = {
color = bright.cyan;
style = "curl";
};
};
"diagnostic.hint" = {
underline = {
color = bright.blue;
style = "curl";
};
};
"markup.heading" = bright.cyan;
"markup.bold" = {
modifiers = [ "bold" ];
};
"markup.italic" = {
modifiers = [ "italic" ];
};
"markup.strikethrough" = {
modifiers = [ "crossed_out" ];
};
"markup.link.url" = {
fg = bright.green;
modifiers = [ "underlined" ];
};
"markup.link.text" = bright.red;
"markup.raw" = bright.red;
};
};
languages = {
language = [
{
name = "rust";
language-servers = [ "rust-analyzer" ];
}
{
name = "nix";
language-servers = [ "nil" ];
file-types = [ "nix" ];
auto-format = true;
formatter = {
command = "nixfmt";
};
}
# theme = "nix-rice"
settings = {
theme = "nix-rice";
editor = {
bufferline = "multiple";
cursorline = true;
true-color = true;
cursor-shape = {
insert = "bar";
normal = "block";
select = "underline";
};
statusline.left = [
"mode"
"spinner"
"version-control"
"file-name"
"file-modification-indicator"
];
lsp.display-messages = true;
};
};
language-server = {
qmlls = {
command = "qmlls";
args = [ "-E" ];
languages = {
language = [
{
name = "rust";
language-servers = [ "rust-analyzer" ];
}
{
name = "nix";
language-servers = [ "nil" ];
file-types = [ "nix" ];
auto-format = true;
formatter = {
command = "nixfmt";
};
}
];
nil = {
command = "nil";
};
language-server = {
qmlls = {
command = "qmlls";
args = [ "-E" ];
};
rust-analyzer = {
config = {
cargo.buildScripts.enable = true;
procMacro.enable = true;
check.command = "clippy";
};
nil = {
command = "nil";
};
rust-analyzer = {
config = {
cargo.buildScripts.enable = true;
procMacro.enable = true;
check.command = "clippy";
};
}; # language-server
}; # languages
}; # helix config
};
};
};
}

View file

@ -1,4 +1 @@
{ lib, ... }:
{
networking.useDHCP = lib.mkDefault true;
}
{ lib, scope, ... }: scope "networking.useDHCP" <| lib.mkDefault true

View file

@ -1,10 +1,13 @@
{ inputs, lib, ... }:
{
nixpkgs = {
config = {
allowUnfree = true;
allowUnfreePredicate = _: true;
};
inputs,
lib,
scope,
...
}:
scope "nixpkgs" {
config = {
allowUnfree = true;
allowUnfreePredicate = _: true;
};
nixpkgs.flake.source = lib.mkForce inputs.nixpkgs;
flake.source = lib.mkForce inputs.nixpkgs;
}

View file

@ -1,23 +1,24 @@
{
scope,
...
}:
{
nix.settings = {
substituters = [
"https://cache.nixos.org"
"https://nix-community.cachix.org"
"https://helix.cachix.org"
"https://walker-git.cachix.org"
"https://anmonteiro.nix-cache.workers.dev"
"https://cache.atagen.co"
];
trusted-public-keys = [
"cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY="
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
"helix.cachix.org-1:ejp9KQpR1FBI2onstMQ34yogDm4OgU2ru6lIwPvuCVs="
"walker-git.cachix.org-1:vmC0ocfPWh0S/vRAQGtChuiZBTAe4wiKDeyyXM0/7pM="
"ocaml.nix-cache.com-1:/xI2h2+56rwFfKyyFVbkJSeGqSIYMC/Je+7XXqGKDIY="
"cache.atagen.co:SOUkNQxuu/eQ7FcI8nlUe7FpV27e7YjQlDQdn8HTUnw="
];
};
scope "nix.settings" {
substituters = [
"https://cache.nixos.org"
"https://nix-community.cachix.org"
"https://helix.cachix.org"
"https://walker-git.cachix.org"
"https://anmonteiro.nix-cache.workers.dev"
"https://cache.atagen.co"
"https://cache.privatevoid.net"
];
trusted-public-keys = [
"cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY="
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
"helix.cachix.org-1:ejp9KQpR1FBI2onstMQ34yogDm4OgU2ru6lIwPvuCVs="
"walker-git.cachix.org-1:vmC0ocfPWh0S/vRAQGtChuiZBTAe4wiKDeyyXM0/7pM="
"ocaml.nix-cache.com-1:/xI2h2+56rwFfKyyFVbkJSeGqSIYMC/Je+7XXqGKDIY="
"cache.atagen.co:SOUkNQxuu/eQ7FcI8nlUe7FpV27e7YjQlDQdn8HTUnw="
"cache.privatevoid.net:SErQ8bvNWANeAvtsOESUwVYr2VJynfuc9JRwlzTTkVg="
];
}

View file

@ -1,7 +1,12 @@
{ pkgs, inputs, ... }:
{
pkgs,
inputs,
getPkgs,
...
}:
{
environment.systemPackages = builtins.attrValues {
environment.systemPackages = getPkgs {
inherit (pkgs)
home-manager
cachix
@ -9,13 +14,10 @@
;
inherit (inputs.nil.packages.${pkgs.system}) nil;
};
hm.imports = [
inputs.nix-index-database.hmModules.nix-index
];
imports = [
inputs.nix-index-database.nixosModules.nix-index
];
programs.nix-index-database.comma.enable = true;
programs.nix-index.enableZshIntegration = false;
programs.nix-index.enableBashIntegration = false;
# programs.nix-index.enableZshIntegration = false;
# programs.nix-index.enableBashIntegration = false;
}