1
0
Fork 0

chore: re-organize

Signed-off-by: jolheiser <john.olheiser@gmail.com>
jolheiser 2023-08-31 23:09:18 -05:00
parent d7795d2481
commit 79b408e8df
Signed by: jolheiser
GPG Key ID: B853ADA5DA7BBF7A
40 changed files with 53 additions and 80 deletions

View File

@ -1,2 +1,2 @@
"apps/firefox/work.nix": "apps/gui/firefox/work.nix":
- age105cm5awxxegyrqthh4vhnxzr0tdy86q8uq52wkkjacfkutp2vprqwseak7 - age105cm5awxxegyrqthh4vhnxzr0tdy86q8uq52wkkjacfkutp2vprqwseak7

2
.gitattributes vendored
View File

@ -1 +1 @@
apps/firefox/work.nix filter=git-age diff=git-age apps/gui/firefox/work.nix filter=git-age diff=git-age

Binary file not shown.

View File

@ -1,9 +1,7 @@
{pkgs, ...}: { {pkgs, ...}: {
imports = [ imports = [
./common.nix ../nogui
./firefox.nix ./firefox.nix
./go.nix
./gtk.nix ./gtk.nix
./spotifyd.nix ./spotifyd.nix
./tiny.nix ./tiny.nix
@ -18,23 +16,21 @@
spotify-tui spotify-tui
# LSPs # LSPs
gopls
lua-language-server lua-language-server
marksman marksman
nodePackages.yaml-language-server nodePackages.yaml-language-server
# Formatters # Formatters
alejandra nodePackages.lua-fmt
python3Packages.black
# IDEs # IDEs
jetbrains.goland jetbrains.goland
# Personal NUR # Personal NUR
nur.repos.jolheiser.git-age
nur.repos.jolheiser.gomodinit nur.repos.jolheiser.gomodinit
nur.repos.jolheiser.imp nur.repos.jolheiser.imp
nur.repos.jolheiser.kv nur.repos.jolheiser.kv
nur.repos.jolheiser.tclip
nur.repos.jolheiser.tmpl nur.repos.jolheiser.tmpl
]; ];
}; };

Binary file not shown.

View File

@ -8,8 +8,9 @@
./bottom.nix ./bottom.nix
./exa.nix ./exa.nix
./fzf.nix ./fzf.nix
./gpg.nix
./git.nix ./git.nix
./go.nix
./gpg.nix
./helix.nix ./helix.nix
./jq.nix ./jq.nix
./lazygit.nix ./lazygit.nix
@ -29,12 +30,19 @@
fd fd
just just
ripgrep ripgrep
usql
# LSPs # LSPs
gopls
nil nil
# Formatters # Formatters
alejandra alejandra
gofumpt
# Personal NUR
nur.repos.jolheiser.git-age
nur.repos.jolheiser.tclip
]; ];
activation.report-changes = config.lib.dag.entryAnywhere '' activation.report-changes = config.lib.dag.entryAnywhere ''
${pkgs.nvd}/bin/nvd --nix-bin-dir=${pkgs.nix}/bin diff $oldGenPath $newGenPath ${pkgs.nvd}/bin/nvd --nix-bin-dir=${pkgs.nix}/bin diff $oldGenPath $newGenPath

View File

@ -36,7 +36,7 @@
}; };
}; };
}; };
commonConfig = {server ? false}: { commonConfig = {gui ? true}: {
config, config,
pkgs, pkgs,
... ...
@ -46,33 +46,26 @@
owner = username; owner = username;
}; };
in { in {
config = config = {
{
nixpkgs.overlays = [overlays]; nixpkgs.overlays = [overlays];
home-manager = { home-manager = {
useGlobalPkgs = true; useGlobalPkgs = true;
useUserPackages = true; useUserPackages = true;
users.${username}.imports = users.${username}.imports =
if !server if gui
then [./apps] then [./apps/gui]
else [./apps/common.nix]; else [./apps/nogui];
extraSpecialArgs = { extraSpecialArgs = {
flakePath = "/home/${username}/.config/nixpkgs"; flakePath = "/home/${username}/.config/nixpkgs";
}; };
}; };
}
// (
if !server
then {
age.secrets = { age.secrets = {
ssh-config = userSecret ./secrets/shared/ssh-config.age; ssh-config = userSecret ./secrets/shared/ssh-config.age;
ssh-config-work = userSecret ./secrets/shared/ssh-config-work.age; ssh-config-work = userSecret ./secrets/shared/ssh-config-work.age;
spotify-pw = userSecret ./secrets/shared/spotify-pw.age; spotify-pw = userSecret ./secrets/shared/spotify-pw.age;
irc-pw = userSecret ./secrets/shared/irc-pw.age; irc-pw = userSecret ./secrets/shared/irc-pw.age;
}; };
} };
else {}
);
}; };
username = "jolheiser"; username = "jolheiser";
in in
@ -83,9 +76,8 @@
modules = [ modules = [
home-manager.nixosModules.home-manager home-manager.nixosModules.home-manager
agenix.nixosModules.default agenix.nixosModules.default
./machines/common
./machines/chai ./machines/chai
commonConfig (commonConfig {})
({pkgs, ...}: { ({pkgs, ...}: {
config = { config = {
nixpkgs.overlays = [ nixpkgs.overlays = [
@ -118,17 +110,17 @@
modules = [ modules = [
home-manager.nixosModules.home-manager home-manager.nixosModules.home-manager
agenix.nixosModules.default agenix.nixosModules.default
./machines/common
./machines/matcha ./machines/matcha
commonConfig (commonConfig {})
]; ];
}; };
"dragonwell" = nixpkgs.lib.nixosSystem { "dragonwell" = nixpkgs.lib.nixosSystem {
system = "x86_64-linux"; system = "x86_64-linux";
modules = [ modules = [
home-manager.nixosModules.home-manager home-manager.nixosModules.home-manager
agenix.nixosModules.default
./machines/dragonwell ./machines/dragonwell
(commonConfig {server = true;}) (commonConfig {gui = false;})
]; ];
}; };
}; };

View File

@ -1,7 +1,7 @@
{pkgs, ...}: let {pkgs, ...}: let
username = "jolheiser"; username = "jolheiser";
in { in {
imports = [./hardware.nix ../common]; imports = [./hardware.nix ../common/gui];
boot = { boot = {
kernelPackages = pkgs.linuxPackages_latest; kernelPackages = pkgs.linuxPackages_latest;

View File

@ -1,4 +1,6 @@
{ {pkgs, ...}: {
imports = [../nogui];
sound.enable = true; sound.enable = true;
hardware.pulseaudio.enable = false; hardware.pulseaudio.enable = false;
security = {rtkit.enable = true;}; security = {rtkit.enable = true;};
@ -9,4 +11,12 @@
alsa.enable = true; alsa.enable = true;
}; };
}; };
services.xserver = {
enable = true;
displayManager.lightdm.enable = true;
desktopManager.cinnamon.enable = true;
layout = "us";
xkbVariant = "";
};
} }

View File

@ -1,6 +1,4 @@
{pkgs, ...}: { {pkgs, ...}: {
imports = [./sound.nix ./xserver.nix];
console.colors = [ console.colors = [
"1e1e2e" "1e1e2e"
"585b70" "585b70"

View File

@ -1,9 +0,0 @@
{pkgs, ...}: {
services.xserver = {
enable = true;
displayManager.lightdm.enable = true;
desktopManager.cinnamon.enable = true;
layout = "us";
xkbVariant = "";
};
}

View File

@ -1,26 +1,7 @@
{pkgs, ...}: let {pkgs, ...}: let
username = "jolheiser"; username = "jolheiser";
in { in {
imports = [./hardware.nix]; imports = [./hardware.nix ../common/nogui];
nixpkgs.config.allowUnfree = true;
nix = {
gc.automatic = true;
package = pkgs.nixVersions.nix_2_15;
settings = {
experimental-features = ["flakes" "nix-command" "repl-flake"];
auto-optimise-store = true;
warn-dirty = false;
};
};
system.activationScripts.diff = {
supportsDryActivation = true;
text = ''
${pkgs.nvd}/bin/nvd --nix-bin-dir=${pkgs.nix}/bin diff /run/current-system "$systemConfig"
'';
};
boot.tmp.cleanOnBoot = true; boot.tmp.cleanOnBoot = true;
zramSwap.enable = true; zramSwap.enable = true;
@ -32,10 +13,7 @@ in {
}; };
services = { services = {
openssh = { openssh.enable = true;
enable = true;
};
tailscale.enable = true; tailscale.enable = true;
}; };

View File

@ -1,7 +1,7 @@
{pkgs, ...}: let {pkgs, ...}: let
username = "jolheiser"; username = "jolheiser";
in { in {
imports = [./hardware.nix ../common]; imports = [./hardware.nix ../common/gui];
boot = { boot = {
kernelPackages = pkgs.linuxPackages_latest; kernelPackages = pkgs.linuxPackages_latest;