std actually works now

std
htran 2023-06-18 02:06:08 -07:00
parent 3f1f1c8f6f
commit f454e55e80
7 changed files with 44 additions and 22 deletions

1
.gitignore vendored
View File

@ -1 +1,2 @@
result result
.direnv

View File

@ -5,7 +5,7 @@ symbol = " "
[c] [c]
disabled = false disabled = false
commmands = [ [ 'cc', '--version' ], [ 'gcc', '--version' ], [ 'clang', '--version' ] ] # commands = [ [ 'cc', '--version' ], [ 'gcc', '--version' ], [ 'clang', '--version' ] ]
detect_extensions = ["c", "h", "cc", "cpp", "hh", "hpp"] detect_extensions = ["c", "h", "cc", "cpp", "hh", "hpp"]
[conda] [conda]

View File

@ -70,10 +70,13 @@ in {
settings = let settings = let
native = builtins.fromTOML (builtins.readFile "${proj_root.config.path}/starship/starship.toml"); native = builtins.fromTOML (builtins.readFile "${proj_root.config.path}/starship/starship.toml");
patch-nix = pkgs.lib.recursiveUpdate native { patch-nix = pkgs.lib.recursiveUpdate native {
c.commands = [ # WARNING: home-manager fails on here for some reason. Likely not at the
["nix" "run" "nixpkgs#clang" "--" "--version"] # validation phase (type-checking), but at evaluation phaase (stringify)
["nix" "run" "nixpkgs#gcc" "--" "--version"] # c.commands = [
]; # ["nix" "run" "nixpkgs#clang" "--" "--version"]
# ["nix" "run" "nixpkgs#gcc" "--" "--version"]
# ];
c.commands = "fuk";
}; };
in in
patch-nix; patch-nix;

View File

@ -16,11 +16,12 @@
base-modules = [ base-modules = [
home-profiles.alacritty home-profiles.alacritty
home-profiles.git # home-profiles.git
home-profiles.ssh home-profiles.ssh
home-profiles.shells home-profiles.shells
({config.programs.home-manager.enable = true;}) ({config.programs.home-manager.enable = true;})
home-profiles.nix-index home-profiles.nix-index
home-profiles.neovim
]; ];
in { in {
homeConfigurations.htran = home-config { homeConfigurations.htran = home-config {

View File

@ -8,6 +8,7 @@ _imports @ {
# TODO: I don't think abstracting namespace away is a good idea in this case # TODO: I don't think abstracting namespace away is a good idea in this case
namespace = "repo"; namespace = "repo";
imports = _imports // {inherit namespace;}; imports = _imports // {inherit namespace;};
inherit (cell) home-modules;
in { in {
neovim = import ./neovim.nix imports; neovim = import ./neovim.nix imports;
nerd_font_module = { nerd_font_module = {
@ -15,11 +16,11 @@ in {
pkgs, pkgs,
... ...
}: { }: {
fonts.fontconfig.enable = true; config.fonts.fontconfig.enable = true;
home.packages = [ config.home.packages = [
(pkgs.nerdfonts.override {fonts = ["Hack"];}) (pkgs.nerdfonts.override {fonts = ["Hack"];})
]; ];
"${namespace}".alacritty.font.family = "Hack Nerd Font Mono"; config."${namespace}".alacritty.font.family = "Hack Nerd Font Mono";
}; };
secrets = { secrets = {
@ -99,8 +100,12 @@ in {
co = "checkout"; co = "checkout";
b = "branch"; b = "branch";
}; };
cfg = config."${namespace}".profile.git;
in { in {
options."${namespace}".git = { imports = [
home-modules.git
];
options."${namespace}".profile.git = {
aliases = lib.mkOption { aliases = lib.mkOption {
type = lib.types.attrs; type = lib.types.attrs;
default = {}; default = {};
@ -135,11 +140,16 @@ in {
example = [".direnv" "node_modules"]; example = [".direnv" "node_modules"];
}; };
}; };
# WARNING: This should be completed wtf
config."${namespace}".git = {
inherit (cfg) name email ignores aliases;
enable = true;
};
}; };
git-htran = { git-htran = {
imports = [inputs.cells.repo.home-profiles.git]; imports = [inputs.cells.repo.home-profiles.git];
config."${namespace}".git = { config."${namespace}".profile.git = {
name = "htran"; name = "htran";
email = "htran@egihosting.com"; email = "htran@egihosting.com";
}; };
@ -147,8 +157,10 @@ in {
git-pegasust = { git-pegasust = {
imports = [inputs.cells.repo.home-profiles.git]; imports = [inputs.cells.repo.home-profiles.git];
config.git."${namespace}".name = "pegasust"; config."${namespace}".profile.git = {
config.git."${namespace}".email = "pegasucksgg@gmail.com"; email = "pegasucksgg@gmail.com";
name = "pegasust";
};
}; };
dev-packages = let pkgs = inputs.nixpkgs; in { dev-packages = let pkgs = inputs.nixpkgs; in {
@ -170,7 +182,7 @@ in {
imports = [ imports = [
inputs.nix-index-database.hmModules.nix-index inputs.nix-index-database.hmModules.nix-index
]; ];
programs.nix-index = { config.programs.nix-index = {
enable = true; enable = true;
enableBashIntegration = true; enableBashIntegration = true;
enableZshIntegration = true; enableZshIntegration = true;
@ -179,9 +191,9 @@ in {
# digital garden stack # digital garden stack
zk = { zk = {
xdg.configFile."zk/config.toml".source = "${inputs.self}/native_configs/zk/config.toml"; config.xdg.configFile."zk/config.toml".source = "${inputs.self}/native_configs/zk/config.toml";
# NB: lib.mkMerge # NB: this is done with lib.mkMerge
home.packages = [ config.home.packages = [
inputs.nixpkgs.zk inputs.nixpkgs.zk
]; ];
}; };

View File

@ -83,7 +83,7 @@ in {
extraLuaConfig = builtins.readFile "${inputs.self}/native_configs/neovim/init.lua"; extraLuaConfig = builtins.readFile "${inputs.self}/native_configs/neovim/init.lua";
plugins = let plugins = let
inherit inherit
(inputs.nixpkgs-latest.vimPlugins) (inputs.nixpkgs-latest.legacyPackages.${system}.vimPlugins)
plenary-nvim plenary-nvim
nvim-treesitter nvim-treesitter
nvim-treesitter-textobjects nvim-treesitter-textobjects

View File

@ -69,10 +69,15 @@ in {
settings = let settings = let
native = builtins.fromTOML (builtins.readFile "${inputs.self}/native_configs/starship/starship.toml"); native = builtins.fromTOML (builtins.readFile "${inputs.self}/native_configs/starship/starship.toml");
patch-nix = pkgs.lib.recursiveUpdate native { patch-nix = pkgs.lib.recursiveUpdate native {
c.commands = [ # WARNING: home-manager fails on here for some reason. Likely not at the
["nix" "run" "nixpkgs#clang" "--" "--version"] # validation phase (type-checking), but at evaluation phaase (stringify)
["nix" "run" "nixpkgs#gcc" "--" "--version"] # I'm thinking when `settings` are evaluated, it has some sort of
]; # recursive processing before it gets turned into a toml
# c.commands = [
# ["nix" "run" "nixpkgs#clang" "--" "--version"]
# ["nix" "run" "nixpkgs#gcc" "--" "--version"]
# ];
c.disabled = true;
}; };
in in
patch-nix; patch-nix;