formatting
This commit is contained in:
parent
6d04251eb7
commit
e6f2aa347e
28
flake.nix
28
flake.nix
|
|
@ -14,12 +14,19 @@
|
|||
};
|
||||
};
|
||||
|
||||
outputs = { nixpkgs, nixpkgs-stable, home-manager, flake-programs-sqlite, ... }@inputs:
|
||||
let
|
||||
outputs = {
|
||||
nixpkgs,
|
||||
nixpkgs-stable,
|
||||
home-manager,
|
||||
flake-programs-sqlite,
|
||||
...
|
||||
} @ inputs: let
|
||||
system = "x86_64-linux";
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
pkgs-stable = nixpkgs-stable.legacyPackages.${system};
|
||||
in with builtins; with nixpkgs.lib.attrsets; {
|
||||
in
|
||||
with builtins;
|
||||
with nixpkgs.lib.attrsets; {
|
||||
nixosConfigurations = mapAttrs' (host: _: {
|
||||
name = host;
|
||||
value = nixpkgs.lib.nixosSystem {
|
||||
|
|
@ -28,20 +35,25 @@
|
|||
inherit pkgs-stable;
|
||||
inherit flake-programs-sqlite;
|
||||
};
|
||||
modules = [ (./hosts + "/${host}") ];
|
||||
modules = [(./hosts + "/${host}")];
|
||||
};
|
||||
}) (readDir ./hosts);
|
||||
homeConfigurations = foldl' (a: b: a//b) {} (map (host: let users = ./hosts + "/${host}/users"; in
|
||||
homeConfigurations = foldl' (a: b: a // b) {} (map (
|
||||
host: let
|
||||
users = ./hosts + "/${host}/users";
|
||||
in
|
||||
if pathExists users
|
||||
then mapAttrs' (user: _: {
|
||||
then
|
||||
mapAttrs' (user: _: {
|
||||
name = "${user}@${host}";
|
||||
value = home-manager.lib.homeManagerConfiguration {
|
||||
inherit pkgs;
|
||||
extraSpecialArgs = {
|
||||
inherit pkgs-stable;
|
||||
};
|
||||
modules = [ (users + "/${user}") ];
|
||||
};}) (readDir users)
|
||||
modules = [(users + "/${user}")];
|
||||
};
|
||||
}) (readDir users)
|
||||
else {}
|
||||
) (attrNames (readDir ./hosts)));
|
||||
};
|
||||
|
|
|
|||
|
|
@ -1,6 +1,4 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
{...}: {
|
||||
imports = [
|
||||
../../system
|
||||
./hardware-configuration.nix
|
||||
|
|
@ -9,7 +7,7 @@
|
|||
networking.hostName = "hyuganatsu";
|
||||
time.timeZone = "America/Chicago";
|
||||
services.xserver = {
|
||||
videoDrivers = [ "amdgpu" ];
|
||||
videoDrivers = ["amdgpu"];
|
||||
deviceSection = ''Option "TearFree" "true"'';
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,29 +1,33 @@
|
|||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||
# and may be overwritten by future invocations. Please make changes
|
||||
# to /etc/nixos/configuration.nix instead.
|
||||
{ config, lib, pkgs, modulesPath, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
[ (modulesPath + "/installer/scan/not-detected.nix")
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
modulesPath,
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-amd" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod"];
|
||||
boot.initrd.kernelModules = [];
|
||||
boot.kernelModules = ["kvm-amd"];
|
||||
boot.extraModulePackages = [];
|
||||
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-uuid/37229430-3b89-413e-9f9d-f36b3d2935bf";
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-uuid/37229430-3b89-413e-9f9d-f36b3d2935bf";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
fileSystems."/boot" =
|
||||
{ device = "/dev/disk/by-uuid/1FF4-8F2A";
|
||||
fileSystems."/boot" = {
|
||||
device = "/dev/disk/by-uuid/1FF4-8F2A";
|
||||
fsType = "vfat";
|
||||
};
|
||||
|
||||
swapDevices = [ ];
|
||||
swapDevices = [];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||
|
|
|
|||
|
|
@ -1,6 +1,4 @@
|
|||
{ config, ... }:
|
||||
|
||||
{
|
||||
{config, ...}: {
|
||||
imports = [
|
||||
../../../../user
|
||||
];
|
||||
|
|
|
|||
|
|
@ -1,6 +1,4 @@
|
|||
{ lib, ... }:
|
||||
|
||||
{
|
||||
{lib, ...}: {
|
||||
imports = [
|
||||
../common
|
||||
./hardware-configuration.nix
|
||||
|
|
@ -9,7 +7,7 @@
|
|||
networking.hostName = "iyokan";
|
||||
time.timeZone = "America/Chicago";
|
||||
services.xserver = {
|
||||
videoDrivers = [ "nvidia" ];
|
||||
videoDrivers = ["nvidia"];
|
||||
deviceSection = ''Option "TearFree" "true"'';
|
||||
};
|
||||
hardware.nvidia.open = false;
|
||||
|
|
|
|||
|
|
@ -1,36 +1,40 @@
|
|||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||
# and may be overwritten by future invocations. Please make changes
|
||||
# to /etc/nixos/configuration.nix instead.
|
||||
{ config, lib, pkgs, modulesPath, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
[ (modulesPath + "/installer/scan/not-detected.nix")
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
modulesPath,
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "nvme" "usbhid" "sd_mod" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-intel" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
boot.initrd.availableKernelModules = ["xhci_pci" "ahci" "nvme" "usbhid" "sd_mod"];
|
||||
boot.initrd.kernelModules = [];
|
||||
boot.kernelModules = ["kvm-intel"];
|
||||
boot.extraModulePackages = [];
|
||||
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-uuid/6c86675c-7428-4a34-98e2-7fa2b423b53e";
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-uuid/6c86675c-7428-4a34-98e2-7fa2b423b53e";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
fileSystems."/home" =
|
||||
{ device = "/dev/disk/by-uuid/d376771f-3dd5-4d8a-94d3-dcb75aae146d";
|
||||
fileSystems."/home" = {
|
||||
device = "/dev/disk/by-uuid/d376771f-3dd5-4d8a-94d3-dcb75aae146d";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
fileSystems."/boot" =
|
||||
{ device = "/dev/disk/by-uuid/4F3D-4702";
|
||||
fileSystems."/boot" = {
|
||||
device = "/dev/disk/by-uuid/4F3D-4702";
|
||||
fsType = "vfat";
|
||||
options = [ "fmask=0022" "dmask=0022" ];
|
||||
options = ["fmask=0022" "dmask=0022"];
|
||||
};
|
||||
|
||||
swapDevices =
|
||||
[ { device = "/dev/disk/by-uuid/8049404d-f5fb-4387-bb75-f308a7f7126f"; }
|
||||
swapDevices = [
|
||||
{device = "/dev/disk/by-uuid/8049404d-f5fb-4387-bb75-f308a7f7126f";}
|
||||
];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
|
|
|
|||
|
|
@ -1,6 +1,4 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
{...}: {
|
||||
services.pipewire = {
|
||||
enable = true;
|
||||
alsa.enable = true;
|
||||
|
|
|
|||
|
|
@ -1,6 +1,4 @@
|
|||
{ lib, ... }:
|
||||
|
||||
{
|
||||
{lib, ...}: {
|
||||
programs.bash = {
|
||||
completion.enable = true;
|
||||
promptInit = ''PS1="[\u \W] \[\e[32;1m\]\$\[\e[0m\] "'';
|
||||
|
|
|
|||
|
|
@ -1,6 +1,4 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
{...}: {
|
||||
boot.loader = {
|
||||
grub.enable = true;
|
||||
grub.device = "nodev";
|
||||
|
|
|
|||
|
|
@ -1,12 +1,16 @@
|
|||
{ config, pkgs, lib, flake-programs-sqlite, ... }:
|
||||
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
flake-programs-sqlite,
|
||||
...
|
||||
}: {
|
||||
nix.settings = {
|
||||
experimental-features = [ "nix-command" "flakes" ];
|
||||
experimental-features = ["nix-command" "flakes"];
|
||||
use-xdg-base-directories = true;
|
||||
};
|
||||
|
||||
environment.pathsToLink = [ "/libexec" ];
|
||||
environment.pathsToLink = ["/libexec"];
|
||||
environment.localBinInPath = true;
|
||||
|
||||
boot.tmp.useTmpfs = true;
|
||||
|
|
@ -29,11 +33,10 @@
|
|||
|
||||
xdg.terminal-exec = {
|
||||
enable = true;
|
||||
settings.default = [ "Alacritty.desktop" ];
|
||||
settings.default = ["Alacritty.desktop"];
|
||||
};
|
||||
|
||||
programs.command-not-found.dbPath = flake-programs-sqlite.packages.${pkgs.system}.programs-sqlite;
|
||||
|
||||
system.stateVersion = "24.05";
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,4 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
{...}: {
|
||||
imports = [
|
||||
./audio.nix
|
||||
./bash.nix
|
||||
|
|
|
|||
|
|
@ -1,6 +1,4 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
{...}: {
|
||||
services.xserver = {
|
||||
enable = true;
|
||||
autorun = false;
|
||||
|
|
|
|||
|
|
@ -1,6 +1,4 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
{pkgs, ...}: {
|
||||
i18n.defaultLocale = "en_US.UTF-8";
|
||||
i18n.supportedLocales = [
|
||||
"en_US.UTF-8/UTF-8"
|
||||
|
|
@ -19,6 +17,6 @@
|
|||
noto-fonts-cjk-sans
|
||||
source-han-sans
|
||||
source-han-serif
|
||||
(nerdfonts.override { fonts = [ "JetBrainsMono" ]; })
|
||||
(nerdfonts.override {fonts = ["JetBrainsMono"];})
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,4 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
{pkgs, ...}: {
|
||||
programs.partition-manager = {
|
||||
enable = true;
|
||||
package = pkgs.libsForQt5.partitionmanager;
|
||||
|
|
|
|||
|
|
@ -1,10 +1,11 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
{...}: {
|
||||
security.doas = {
|
||||
enable = true;
|
||||
extraRules = [
|
||||
{ groups = [ "wheel" ]; persist = true; }
|
||||
{
|
||||
groups = ["wheel"];
|
||||
persist = true;
|
||||
}
|
||||
];
|
||||
};
|
||||
security.polkit.enable = true;
|
||||
|
|
|
|||
|
|
@ -1,8 +1,6 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
{...}: {
|
||||
users.users.ahnwuoa = {
|
||||
isNormalUser = true;
|
||||
extraGroups = [ "wheel" "podman" ];
|
||||
extraGroups = ["wheel" "podman"];
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,4 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
{...}: {
|
||||
virtualisation.containers.enable = true;
|
||||
virtualisation = {
|
||||
podman = {
|
||||
|
|
|
|||
|
|
@ -1,19 +1,23 @@
|
|||
{ config, pkgs, ... }:
|
||||
|
||||
let
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
deps = {
|
||||
bell = [ pkgs.pipewire pkgs.libnotify ];
|
||||
nsxiv-rifle = [ pkgs.nsxiv ];
|
||||
screenshot = [ pkgs.maim pkgs.xclip ];
|
||||
bell = [pkgs.pipewire pkgs.libnotify];
|
||||
nsxiv-rifle = [pkgs.nsxiv];
|
||||
screenshot = [pkgs.maim pkgs.xclip];
|
||||
};
|
||||
mkln = x: config.lib.file.mkOutOfStoreSymlink "${config.home.homeDirectory}/.local/nixos/user/bin/${x}";
|
||||
in {
|
||||
home.file = builtins.listToAttrs (map
|
||||
home.file = builtins.listToAttrs (
|
||||
map
|
||||
(x: {
|
||||
name = ".local/bin/${x}";
|
||||
value = { source = mkln x; };
|
||||
value = {source = mkln x;};
|
||||
})
|
||||
(builtins.filter
|
||||
(
|
||||
builtins.filter
|
||||
(x: x != "default.nix")
|
||||
(builtins.attrNames (builtins.readDir ./.))
|
||||
)
|
||||
|
|
|
|||
|
|
@ -1,6 +1,4 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
{...}: {
|
||||
imports = [
|
||||
./bin
|
||||
./home.nix
|
||||
|
|
|
|||
|
|
@ -1,11 +1,14 @@
|
|||
{ config, pkgs, pkgs-stable, ... }:
|
||||
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
pkgs-stable,
|
||||
...
|
||||
}: {
|
||||
home.packages = with pkgs; [
|
||||
(pkgs.symlinkJoin {
|
||||
name = "firefox";
|
||||
paths = [ pkgs-stable.firefox ];
|
||||
buildInputs = [ pkgs.makeWrapper ];
|
||||
paths = [pkgs-stable.firefox];
|
||||
buildInputs = [pkgs.makeWrapper];
|
||||
postBuild = ''
|
||||
wrapProgram $out/bin/firefox \
|
||||
--set HOME "${config.home.homeDirectory}/.local/share"
|
||||
|
|
@ -72,7 +75,7 @@
|
|||
|
||||
gdb
|
||||
pwndbg
|
||||
(pkgs-stable.cutter.withPlugins (ps: with ps; [ jsdec rz-ghidra sigdb ]))
|
||||
(pkgs-stable.cutter.withPlugins (ps: with ps; [jsdec rz-ghidra sigdb]))
|
||||
ghidra-bin
|
||||
pwninit
|
||||
patchelf
|
||||
|
|
|
|||
|
|
@ -1,6 +1,4 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
{...}: {
|
||||
imports = [
|
||||
./nsxiv-rifle.nix
|
||||
];
|
||||
|
|
|
|||
|
|
@ -1,6 +1,4 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
{...}: {
|
||||
xdg.desktopEntries."nsxiv-rifle" = {
|
||||
exec = "nsxiv-rifle %F";
|
||||
icon = "nsxiv";
|
||||
|
|
|
|||
|
|
@ -1,6 +1,8 @@
|
|||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
qt = {
|
||||
enable = true;
|
||||
platformTheme.name = "qtct";
|
||||
|
|
@ -10,7 +12,7 @@
|
|||
gtk = {
|
||||
enable = true;
|
||||
gtk2.extraConfig = "gtk-recent-files-max-age = 0";
|
||||
gtk3.extraConfig = { gtk-recent-files-limit = 0; };
|
||||
gtk3.extraConfig = {gtk-recent-files-limit = 0;};
|
||||
theme = {
|
||||
name = "Breeze";
|
||||
package = pkgs.libsForQt5.breeze-gtk;
|
||||
|
|
|
|||
16
user/xdg.nix
16
user/xdg.nix
|
|
@ -1,6 +1,8 @@
|
|||
{ config, pkgs, ... }:
|
||||
|
||||
let
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
mkln = x: config.lib.file.mkOutOfStoreSymlink "${config.home.homeDirectory}/.local/nixos/user/${x}";
|
||||
in {
|
||||
xdg.configFile.alacritty.source = mkln "config/alacritty";
|
||||
|
|
@ -22,7 +24,9 @@ in {
|
|||
xdg.configFile.readline.source = config/readline;
|
||||
xdg.configFile."starship.toml".source = config/starship.toml;
|
||||
xdg.configFile.sx.source = mkln "config/sx";
|
||||
xdg.configFile."tmux/tmux.conf".text = (builtins.readFile config/tmux/tmux.conf) + ''
|
||||
xdg.configFile."tmux/tmux.conf".text =
|
||||
(builtins.readFile config/tmux/tmux.conf)
|
||||
+ ''
|
||||
run ${pkgs.tmuxPlugins.vim-tmux-navigator.rtp}
|
||||
run ${pkgs.tmuxPlugins.sessionist.rtp}
|
||||
'';
|
||||
|
|
@ -52,8 +56,8 @@ in {
|
|||
};
|
||||
xdg.portal = {
|
||||
enable = true;
|
||||
configPackages = [ pkgs.libsForQt5.xdg-desktop-portal-kde ];
|
||||
extraPortals = [ pkgs.libsForQt5.xdg-desktop-portal-kde ];
|
||||
configPackages = [pkgs.libsForQt5.xdg-desktop-portal-kde];
|
||||
extraPortals = [pkgs.libsForQt5.xdg-desktop-portal-kde];
|
||||
config.common.default = "kde";
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue