mirror of
https://github.com/gensokyo-zone/infrastructure.git
synced 2026-02-09 12:29:19 -08:00
Move to recursiveMod, nixdirfmt
This commit is contained in:
parent
3a4458eae5
commit
76a479f14e
66 changed files with 313 additions and 335 deletions
|
|
@ -1,12 +1,16 @@
|
|||
{ config, pkgs, ... }:
|
||||
{ ... }: {
|
||||
imports = [
|
||||
({ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
users.users.arc = {
|
||||
uid = 1001;
|
||||
isNormalUser = true;
|
||||
openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJ8Z6briIboxIdedPGObEWB6QEQkvxKvnMW/UVU9t/ac mew-pgp"
|
||||
];
|
||||
shell = pkgs.zsh;
|
||||
};
|
||||
{
|
||||
users.users.arc = {
|
||||
uid = 1001;
|
||||
isNormalUser = true;
|
||||
openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJ8Z6briIboxIdedPGObEWB6QEQkvxKvnMW/UVU9t/ac mew-pgp"
|
||||
];
|
||||
shell = pkgs.zsh;
|
||||
};
|
||||
})
|
||||
];
|
||||
}
|
||||
|
|
|
|||
7
config/users/arc/settings.nix
Normal file
7
config/users/arc/settings.nix
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
{ ... }: {
|
||||
defaultOnly = true;
|
||||
includeFolders = {
|
||||
enable = true;
|
||||
default.enable = true;
|
||||
};
|
||||
}
|
||||
|
|
@ -1,38 +1,42 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
{ ... }: {
|
||||
imports = [
|
||||
({ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
users.users.hexchen = {
|
||||
uid = 1002;
|
||||
isNormalUser = true;
|
||||
openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDNVUDKx9sukRkb6INny432+2HZBWx/qIEAOvngF1qcj hexchen@montasch"
|
||||
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDI3T1eFS77URHZ/HVWkMOqx7W1U54zJtn9C7QWsHOtyH72i/4EVj8SxYqLllElh1kuKUXSUipPeEzVsipFVvfH0wEuTDgFffiSQ3a8lfUgdEBuoySwceEoPgc5deapkOmiDIDeeWlrRe3nqspLRrSWU1DirMxoFPbwqJXRvpl6qJPxRg+2IolDcXlZ6yxB4Vv48vzRfVzZNUz7Pjmy2ebU8PbDoFWL/S3m7yOzQpv3L7KYBz7+rkjuF3AU2vy6CAfIySkVpspZZLtkTGCIJF228ev0e8NvhuN6ZnjzXxVTQOy32HCdPdbBbicu0uHfZ5O7JX9DjGd8kk1r2dnZwwy/ hexchen@yubi5"
|
||||
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC4CLJ+mFfq5XiBXROKewmN9WYmj+79bj/AoaR6Iud2pirulot3tkrrLe2cMjiNWFX8CGVqrsAELKUA8EyUTJfStlcTE0/QNESTRmdDaC+lZL41pWUO9KOiD6/0axAhHXrSJ0ScvbqtD0CtpnCKKxtuOflVPoUGZsH9cLKJNRKfEka0H0GgeKb5Tp618R/WNAQOwaCcXzg/nG4Bgv3gJW4Nm9IKy/MwRZqtILi8Mtd+2diTqpMwyNRmbenmRHCQ1vRw46joYkledVqrmSlfSMFgIHI1zRSBXb/JkG2IvIyB5TGbTkC4N2fqJNpH8wnCKuOvs46xmgdiRA26P48C2em3 hexchen@yubi5c"
|
||||
];
|
||||
};
|
||||
{
|
||||
users.users.hexchen = {
|
||||
uid = 1002;
|
||||
isNormalUser = true;
|
||||
openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDNVUDKx9sukRkb6INny432+2HZBWx/qIEAOvngF1qcj hexchen@montasch"
|
||||
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDI3T1eFS77URHZ/HVWkMOqx7W1U54zJtn9C7QWsHOtyH72i/4EVj8SxYqLllElh1kuKUXSUipPeEzVsipFVvfH0wEuTDgFffiSQ3a8lfUgdEBuoySwceEoPgc5deapkOmiDIDeeWlrRe3nqspLRrSWU1DirMxoFPbwqJXRvpl6qJPxRg+2IolDcXlZ6yxB4Vv48vzRfVzZNUz7Pjmy2ebU8PbDoFWL/S3m7yOzQpv3L7KYBz7+rkjuF3AU2vy6CAfIySkVpspZZLtkTGCIJF228ev0e8NvhuN6ZnjzXxVTQOy32HCdPdbBbicu0uHfZ5O7JX9DjGd8kk1r2dnZwwy/ hexchen@yubi5"
|
||||
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC4CLJ+mFfq5XiBXROKewmN9WYmj+79bj/AoaR6Iud2pirulot3tkrrLe2cMjiNWFX8CGVqrsAELKUA8EyUTJfStlcTE0/QNESTRmdDaC+lZL41pWUO9KOiD6/0axAhHXrSJ0ScvbqtD0CtpnCKKxtuOflVPoUGZsH9cLKJNRKfEka0H0GgeKb5Tp618R/WNAQOwaCcXzg/nG4Bgv3gJW4Nm9IKy/MwRZqtILi8Mtd+2diTqpMwyNRmbenmRHCQ1vRw46joYkledVqrmSlfSMFgIHI1zRSBXb/JkG2IvIyB5TGbTkC4N2fqJNpH8wnCKuOvs46xmgdiRA26P48C2em3 hexchen@yubi5c"
|
||||
];
|
||||
};
|
||||
|
||||
home-manager.users.hexchen = {
|
||||
programs.vim = {
|
||||
enable = true;
|
||||
extraConfig = ''
|
||||
set viminfo='20,<1000
|
||||
set mouse=a
|
||||
'';
|
||||
};
|
||||
home-manager.users.hexchen = {
|
||||
programs.vim = {
|
||||
enable = true;
|
||||
extraConfig = ''
|
||||
set viminfo='20,<1000
|
||||
set mouse=a
|
||||
'';
|
||||
};
|
||||
|
||||
programs.git = {
|
||||
enable = true;
|
||||
userName = "hexchen";
|
||||
userEmail = "hexchen@lilwit.ch";
|
||||
signing = {
|
||||
key = "B1DF5EAD";
|
||||
};
|
||||
extraConfig = {
|
||||
pull.rebase = true;
|
||||
};
|
||||
};
|
||||
programs.git = {
|
||||
enable = true;
|
||||
userName = "hexchen";
|
||||
userEmail = "hexchen@lilwit.ch";
|
||||
signing = {
|
||||
key = "B1DF5EAD";
|
||||
};
|
||||
extraConfig = {
|
||||
pull.rebase = true;
|
||||
};
|
||||
};
|
||||
|
||||
programs.bat.enable = true;
|
||||
programs.jq.enable = true;
|
||||
};
|
||||
programs.bat.enable = true;
|
||||
programs.jq.enable = true;
|
||||
};
|
||||
})
|
||||
];
|
||||
}
|
||||
|
|
|
|||
7
config/users/hexchen/settings.nix
Normal file
7
config/users/hexchen/settings.nix
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
{ ... }: {
|
||||
defaultOnly = true;
|
||||
includeFolders = {
|
||||
enable = true;
|
||||
default.enable = true;
|
||||
};
|
||||
}
|
||||
|
|
@ -1,19 +0,0 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./vim
|
||||
./shell.nix
|
||||
./git.nix
|
||||
./tmux.nix
|
||||
./base16.nix
|
||||
./xdg.nix
|
||||
./ssh.nix
|
||||
./packages.nix
|
||||
./weechat.nix
|
||||
./inputrc.nix
|
||||
./secrets.nix
|
||||
];
|
||||
|
||||
home.stateVersion = "20.09";
|
||||
}
|
||||
3
config/users/kat/base/state.nix
Normal file
3
config/users/kat/base/state.nix
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
{ config, ... }: {
|
||||
home.stateVersion = "20.09";
|
||||
}
|
||||
|
|
@ -1,28 +1,30 @@
|
|||
let katUser = { lib }:
|
||||
let
|
||||
userImport = profile: { config, ... }: {
|
||||
{ lib, tree, ... }: with lib; let
|
||||
wrapImports = imports: mapAttrs
|
||||
(name: paths: { config, ... }: {
|
||||
config.home-manager.users.kat = {
|
||||
imports = [
|
||||
(./. + "/${profile}")
|
||||
];
|
||||
imports = if isAttrs paths then attrValues paths else singleton paths;
|
||||
};
|
||||
};
|
||||
serviceImport = profile: { config, ... }: {
|
||||
config.home-manager.users.kat = {
|
||||
imports = [
|
||||
(./services + "/${profile}")
|
||||
];
|
||||
};
|
||||
};
|
||||
profileNames = lib.folderList ./. [ "base" "services" ];
|
||||
serviceNames = lib.folderList ./services [ ];
|
||||
userProfiles = with userProfiles;
|
||||
lib.genAttrs profileNames userImport // {
|
||||
services = lib.genAttrs serviceNames serviceImport;
|
||||
base = { imports = [ ./nixos.nix (userImport "base") ]; };
|
||||
server = {};
|
||||
guiFull = { imports = [ gui sway dev media personal ]; };
|
||||
};
|
||||
in
|
||||
userProfiles;
|
||||
in { __functor = self: katUser; isModule = false; }
|
||||
})
|
||||
imports;
|
||||
dirImports = wrapImports tree.dirs;
|
||||
serviceImports = wrapImports tree.dirs.services;
|
||||
in
|
||||
(removeAttrs dirImports (singleton "base")) // {
|
||||
base = {
|
||||
imports = [
|
||||
dirImports.base
|
||||
tree.files.nixos
|
||||
];
|
||||
};
|
||||
server = { };
|
||||
guiFull = {
|
||||
imports = with dirImports; [
|
||||
gui
|
||||
sway
|
||||
dev
|
||||
media
|
||||
personal
|
||||
];
|
||||
};
|
||||
services = serviceImports;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,12 +0,0 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./vim
|
||||
./rink.nix
|
||||
./shell.nix
|
||||
./rustfmt.nix
|
||||
./packages.nix
|
||||
./cookiecutter.nix
|
||||
];
|
||||
}
|
||||
5
config/users/kat/dev/settings.nix
Normal file
5
config/users/kat/dev/settings.nix
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
{ ... }: {
|
||||
excludes = [
|
||||
"emacs"
|
||||
];
|
||||
}
|
||||
|
|
@ -1,16 +0,0 @@
|
|||
{ config, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./firefox
|
||||
./packages.nix
|
||||
./gtk.nix
|
||||
./base16.nix
|
||||
./foot.nix
|
||||
./kitty.nix
|
||||
./xdg.nix
|
||||
./ranger.nix
|
||||
./fonts.nix
|
||||
./qt.nix
|
||||
];
|
||||
}
|
||||
|
|
@ -1,10 +0,0 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./mpv.nix
|
||||
./obs.nix
|
||||
./syncplay.nix
|
||||
./packages.nix
|
||||
];
|
||||
}
|
||||
|
|
@ -1,15 +0,0 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./gpg.nix
|
||||
./git.nix
|
||||
./packages.nix
|
||||
./weechat.nix
|
||||
./email.nix
|
||||
./shell.nix
|
||||
./pass.nix
|
||||
./taskwarrior.nix
|
||||
./bitw.nix
|
||||
];
|
||||
}
|
||||
|
|
@ -7,6 +7,6 @@
|
|||
'';
|
||||
};
|
||||
programs.zsh = {
|
||||
shellAliases = mapListToAttrs (attr: nameValuePair "abby${attr}" "mpv $(bitw get secrets/abby -f ${attr})") ["radio" "tv"];
|
||||
shellAliases = mapListToAttrs (attr: nameValuePair "abby${attr}" "mpv $(bitw get secrets/abby -f ${attr})") [ "radio" "tv" ];
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
{
|
||||
programs.neovim = {
|
||||
extraConfig = ''
|
||||
${source ./init.vim}
|
||||
source ${./init.vim}
|
||||
'';
|
||||
plugins = with pkgs.vimPlugins; [
|
||||
notmuch-vim
|
||||
|
|
|
|||
7
config/users/kat/settings.nix
Normal file
7
config/users/kat/settings.nix
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
{ ... }: {
|
||||
defaultOnly = true;
|
||||
recursiveInclude = true;
|
||||
includeFolders = {
|
||||
default.enable = true;
|
||||
};
|
||||
}
|
||||
|
|
@ -1,14 +0,0 @@
|
|||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./xkb.nix
|
||||
./waybar
|
||||
./wofi
|
||||
./mako.nix
|
||||
./sway.nix
|
||||
./gammastep.nix
|
||||
./konawall.nix
|
||||
./packages.nix
|
||||
];
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue