Compare commits
17 commits
ed7d2374d8
...
5e7347ad26
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5e7347ad26 | ||
|
|
a3ac063e28 | ||
|
|
c6b1107a78 | ||
|
|
31f95124c9 | ||
|
|
5105087d65 | ||
|
|
6959d0a591 | ||
|
|
41de43403a | ||
|
|
b2f44b7d17 | ||
|
|
bcc20c9c03 | ||
|
|
76909b3202 | ||
|
|
ef467fb842 | ||
|
|
02c4f6ec4e | ||
|
|
7ddfd59f6b | ||
|
|
1d76564f73 | ||
|
|
b933f28c81 | ||
|
|
38289d986c | ||
|
|
da5572e47d |
4 changed files with 226 additions and 1 deletions
|
|
@ -277,7 +277,7 @@
|
||||||
".direnv"
|
".direnv"
|
||||||
];
|
];
|
||||||
hooks = {
|
hooks = {
|
||||||
pre-commit = ./git-pre-commit-hook;
|
pre-commit = ../git-pre-commit-hook;
|
||||||
};
|
};
|
||||||
signing.signByDefault = true;
|
signing.signByDefault = true;
|
||||||
signing.key = null; # "let GnuPG decide what signing key to use depending on commit's author"
|
signing.key = null; # "let GnuPG decide what signing key to use depending on commit's author"
|
||||||
|
|
|
||||||
186
sam/configuration.nix
Normal file
186
sam/configuration.nix
Normal file
|
|
@ -0,0 +1,186 @@
|
||||||
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
imports =
|
||||||
|
[
|
||||||
|
./hardware-configuration.nix
|
||||||
|
(import "${builtins.fetchTarball https://github.com/nix-community/home-manager/archive/release-25.05.tar.gz}/nixos")
|
||||||
|
];
|
||||||
|
|
||||||
|
# https://discourse.nixos.org/t/github-strategies-for-configuration-nix/1983/14
|
||||||
|
nix.nixPath = [
|
||||||
|
"nixpkgs=/nix/var/nix/profiles/per-user/root/channels/nixos"
|
||||||
|
"nixos-config=/home/chandler/projects/machine-config/${config.networking.hostName}/configuration.nix"
|
||||||
|
"/nix/var/nix/profiles/per-user/root/channels"
|
||||||
|
];
|
||||||
|
|
||||||
|
services.spice-vdagentd.enable = true;
|
||||||
|
services.qemuGuest.enable = true;
|
||||||
|
|
||||||
|
# Bootloader.
|
||||||
|
boot.loader.systemd-boot.enable = true;
|
||||||
|
boot.loader.efi.canTouchEfiVariables = true;
|
||||||
|
|
||||||
|
# Use latest kernel.
|
||||||
|
boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||||
|
|
||||||
|
networking.hostName = "sam"; # Define your hostname.
|
||||||
|
|
||||||
|
# Enable networking
|
||||||
|
networking.networkmanager.enable = true;
|
||||||
|
|
||||||
|
# Set your time zone.
|
||||||
|
time.timeZone = "America/Chicago";
|
||||||
|
|
||||||
|
# Select internationalisation properties.
|
||||||
|
i18n.defaultLocale = "en_US.UTF-8";
|
||||||
|
|
||||||
|
i18n.extraLocaleSettings = {
|
||||||
|
LC_ADDRESS = "en_US.UTF-8";
|
||||||
|
LC_IDENTIFICATION = "en_US.UTF-8";
|
||||||
|
LC_MEASUREMENT = "en_US.UTF-8";
|
||||||
|
LC_MONETARY = "en_US.UTF-8";
|
||||||
|
LC_NAME = "en_US.UTF-8";
|
||||||
|
LC_NUMERIC = "en_US.UTF-8";
|
||||||
|
LC_PAPER = "en_US.UTF-8";
|
||||||
|
LC_TELEPHONE = "en_US.UTF-8";
|
||||||
|
LC_TIME = "en_US.UTF-8";
|
||||||
|
};
|
||||||
|
|
||||||
|
services.displayManager.sddm.enable = true;
|
||||||
|
services.displayManager.sddm.wayland.enable = true;
|
||||||
|
services.desktopManager.plasma6.enable = true;
|
||||||
|
|
||||||
|
# Enable sound with pipewire.
|
||||||
|
services.pulseaudio.enable = false;
|
||||||
|
security.rtkit.enable = true;
|
||||||
|
services.pipewire = {
|
||||||
|
enable = true;
|
||||||
|
alsa.enable = true;
|
||||||
|
alsa.support32Bit = true;
|
||||||
|
pulse.enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
security.sudo.wheelNeedsPassword = false;
|
||||||
|
users.users.chandler = {
|
||||||
|
isNormalUser = true;
|
||||||
|
description = "Chandler Swift";
|
||||||
|
extraGroups = [ "networkmanager" "wheel" "docker"];
|
||||||
|
};
|
||||||
|
home-manager.users.chandler = { pkgs, ... }: {
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
kdePackages.kate
|
||||||
|
gh
|
||||||
|
];
|
||||||
|
|
||||||
|
programs.bash = {
|
||||||
|
enable = true;
|
||||||
|
historyControl = [ "ignoredups" "ignorespace" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.direnv = {
|
||||||
|
enable = true;
|
||||||
|
enableBashIntegration = true;
|
||||||
|
nix-direnv.enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.git = {
|
||||||
|
enable = true;
|
||||||
|
userName = "Chandler Swift";
|
||||||
|
lfs.enable = true;
|
||||||
|
# TODO: delta or diff-so-fancy or difftastic
|
||||||
|
extraConfig = {
|
||||||
|
init.defaultBranch = "main";
|
||||||
|
diff.wsErrorHighlight = "all";
|
||||||
|
pull.ff = "only";
|
||||||
|
url."ssh://git@github.com/ChandlerSwift/".insteadOf = "gh:";
|
||||||
|
url."ssh://forgejo@bert/chandlerswift/".insteadOf = "forgejo:";
|
||||||
|
push.autoSetupRemote = true;
|
||||||
|
rebase.autosquash = true;
|
||||||
|
rebase.autostash = true;
|
||||||
|
fetch.parallel = 0; # "some reasonable default"
|
||||||
|
fetch.prune = true;
|
||||||
|
merge.conflictstyle = "diff3";
|
||||||
|
};
|
||||||
|
ignores = [
|
||||||
|
"*.kate-swp"
|
||||||
|
"*.swp"
|
||||||
|
"*~"
|
||||||
|
"\\#*\\#"
|
||||||
|
"venv"
|
||||||
|
".direnv"
|
||||||
|
];
|
||||||
|
includes = [
|
||||||
|
{
|
||||||
|
condition = "gitdir:/home/chandler/work/";
|
||||||
|
contents.user.email = "chandler.swift@pearson.com";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
condition = "gitdir:/home/chandler/projects/";
|
||||||
|
contents.user.email = "chandler+pearson@chandlerswift.com";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
condition = "gitdir:/home/chandler/work/github-vue/";
|
||||||
|
contents.core.sshCommand = "ssh -i ~/.ssh/github-vue";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
hooks = {
|
||||||
|
pre-commit = ../git-pre-commit-hook;
|
||||||
|
};
|
||||||
|
signing.signByDefault = true;
|
||||||
|
signing.key = null; # "let GnuPG decide what signing key to use depending on commit's author"
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.ssh = {
|
||||||
|
enable = true;
|
||||||
|
addKeysToAgent = "yes";
|
||||||
|
includes = [
|
||||||
|
"config.d/*"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.firefox.enable = true;
|
||||||
|
|
||||||
|
programs.chromium = {
|
||||||
|
enable = true;
|
||||||
|
extensions = [
|
||||||
|
{ id = "cjpalhdlnbpafiamejdnhcphjbkeiagm"; } # ublock origin
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.atuin = {
|
||||||
|
enable = true;
|
||||||
|
flags = [
|
||||||
|
"--disable-up-arrow"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
home.stateVersion = "25.05";
|
||||||
|
};
|
||||||
|
|
||||||
|
services.displayManager.autoLogin.enable = true;
|
||||||
|
services.displayManager.autoLogin.user = "chandler";
|
||||||
|
|
||||||
|
virtualisation.docker.enable = true;
|
||||||
|
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
git
|
||||||
|
];
|
||||||
|
|
||||||
|
# Some programs need SUID wrappers, can be configured further or are
|
||||||
|
# started in user sessions.
|
||||||
|
# programs.mtr.enable = true;
|
||||||
|
programs.gnupg.agent = {
|
||||||
|
enable = true;
|
||||||
|
# enableSSHSupport = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
# This value determines the NixOS release from which the default
|
||||||
|
# settings for stateful data, like file locations and database versions
|
||||||
|
# on your system were taken. It‘s perfectly fine and recommended to leave
|
||||||
|
# this value at the release version of the first install of this system.
|
||||||
|
# Before changing this value read the documentation for this option
|
||||||
|
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
||||||
|
system.stateVersion = "25.05"; # Did you read the comment?
|
||||||
|
|
||||||
|
}
|
||||||
39
sam/hardware-configuration.nix
Normal file
39
sam/hardware-configuration.nix
Normal file
|
|
@ -0,0 +1,39 @@
|
||||||
|
# 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 + "/profiles/qemu-guest.nix")
|
||||||
|
];
|
||||||
|
|
||||||
|
boot.initrd.availableKernelModules = [ "xhci_pci" "virtio_pci" "usbhid" "usb_storage" "sr_mod" ];
|
||||||
|
boot.initrd.kernelModules = [ ];
|
||||||
|
boot.kernelModules = [ ];
|
||||||
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
|
fileSystems."/" =
|
||||||
|
{ device = "/dev/disk/by-uuid/9f5ccd27-a09e-41d0-88a5-142d5cfb89fe";
|
||||||
|
fsType = "ext4";
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/boot" =
|
||||||
|
{ device = "/dev/disk/by-uuid/0FF4-D39B";
|
||||||
|
fsType = "vfat";
|
||||||
|
options = [ "fmask=0077" "dmask=0077" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
swapDevices =
|
||||||
|
[ { device = "/dev/disk/by-uuid/6c923fd7-5b0a-4dd5-b1ce-6cd4ea144275"; }
|
||||||
|
];
|
||||||
|
|
||||||
|
# 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
|
||||||
|
# still possible to use this option, but it's recommended to use it in conjunction
|
||||||
|
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
||||||
|
networking.useDHCP = lib.mkDefault true;
|
||||||
|
# networking.interfaces.enp0s1.useDHCP = lib.mkDefault true;
|
||||||
|
|
||||||
|
nixpkgs.hostPlatform = lib.mkDefault "aarch64-linux";
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue