This commit is contained in:
sadan 2024-11-26 17:01:58 -05:00
parent 59ee516926
commit 5a3af882ec
No known key found for this signature in database
61 changed files with 705 additions and 562 deletions

View file

@ -9,6 +9,7 @@
# Include the results of the hardware scan.
./hardware-configuration.nix
../../common/systemModules/boot.nix
../../common/systemModules/kernel.nix
../../common/systemModules/audio.nix
../../common/systemModules/kde.nix
../../common/systemModules/tailscale.nix
@ -44,11 +45,11 @@
environment.systemPackages = with pkgs; [
ddcutil
clinfo
i2c-tools
fuse
ifuse
ddcutil
i2c-tools
gcc
neovim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
curl

View file

@ -7,131 +7,74 @@
{
imports = [
inputs.sops-nix.nixosModules.sops
../../common/users/meyer-wsl
../../common/systemModules/wsl.nix
../../common/systemModules/kernel.nix
../../common/systemModules/crypt.nix
../../common/systemModules/stylix.nix
];
sops.defaultSopsFile = ../../secrets.yaml;
sops.defaultSopsFormat = "yaml";
sops.age.keyFile = "/home/meyer/.config/sops/age/keys.txt";
sops.secrets.password.neededForUsers = true;
wsl.enable = true;
wsl.defaultUser = "meyer";
# Use the systemd-boot EFI boot loader.
users.users.meyer = {
isNormalUser = true;
hashedPasswordFile = config.sops.secrets.password.path;
extraGroups = [
"wheel" # Enable sudo for the user.
"input"
"tty"
];
shell = pkgs.zsh;
};
home-manager = {
extraSpecialArgs = { inherit inputs; };
users = {
"meyer" = import ./home.nix;
};
};
boot.kernelPackages = pkgs.linuxPackages_zen;
hardware.i2c.enable = true;
networking.hostName = "nix-wsl"; # Define your hostname.
hardware.i2c.enable = true;
networking.hostName = "arm-laptop-evo4b5"; # Define your hostname.
nixpkgs.config.allowUnfree = true;
nix.settings.experimental-features = [ "nix-command" "flakes" ];
# Set your time zone.
time.timeZone = "America/New_York";
# Select internationalisation properties.
# i18n.defaultLocale = "en_US.UTF-8";
# console = {
# font = "Lat2-Terminus16";
# keyMap = "us";
# useXkbConfig = true; # use xkb.options in tty.
# };
# Enable the X11 windowing system.
# servives.desktopManager.plasma6.enable = true;
# services.desktopManager.plasma6.enable = true;
# Configure keymap in X11
# services.xserver.xkb.layout = "us";
# services.xserver.xkb.options = "eurosign:e,caps:escape";
# Enable CUPS to print documents.
nix.settings.experimental-features = [ "nix-command" "flakes" ];
# Enable sound.
# hardware.pulseaudio.enable = true;
# Enable touchpad support (enabled default in most desktopManager).
# services.xserver.libinput.enable = true;
# Define a user account. Don't forget to set a password with passwd.
programs.zsh.enable = true;
nixpkgs.config.allowUnfree = true;
# networking.nameservers = ["10.0.0.97" "1.1.1.1"];
networking.nameservers = [ "10.0.0.97" ];
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
ddcutil
i2c-tools
# python311
# python311Packages.evdev
# python311Packages.xlib
fuse
gcc
neovim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
curl
wget
git
ripgrep
tldr
gnupg
openssh
pinentry-curses
pinentry
libnotify
file
];
#LD fix
programs.nix-ld.enable = true;
programs.nix-ld.libraries = with pkgs; [
pkgs.curlWithGnuTls
libGL
alsa-lib
expat
mesa
libxkbcommon
xorg.libxcb
xorg.libXrandr
xorg.libXfixes
xorg.libXext
xorg.libXdamage
xorg.libXcomposite
xorg.libX11
cairo
pango
gtk3
libdrm
cups
at-spi2-atk
lzo
dbus
nspr
nss
glib
curlWithGnuTls
fuse
fuse3
mimalloc
libstdcxx5
];
programs.ssh.startAgent = true;
# programs.ssh.askPassword = pkgs.lib.mkForce "${pkgs.ksshaskpass.out}/bin/ksshaskpass";
programs.gnupg.agent = {
enable = true;
};
# 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;
# };
# List services that you want to enable:
# Enable the OpenSSH daemon.
# services.openssh.enable = true;
# Open ports in the firewall.
# networking.firewall.allowedTCPPorts = [ ... ];
# networking.firewall.allowedUDPPorts = [ ... ];
# Or disable the firewall altogether.
# networking.firewall.enable = false;
# Copy the NixOS configuration file and link it from the resulting system
# (/run/current-system/configuration.nix). This is useful in case you
# accidentally delete configuration.nix.
# system.copySystemConfiguration = true;
# This option defines the first version of NixOS you have installed on this particular machine,
# and is used to maintain compatibility with application data (e.g. databases) created on older NixOS versions.
#

View file

@ -1,99 +0,0 @@
{ config, lib, pkgs, inputs, ... }:
let
_s1 = import ../../common/sops.nix {inherit config; };
files = import ../../common/files.nix { inherit config; };
shell = import ../../common/shell.nix { inherit config pkgs; };
p = import ../../common/pkgs.nix { inherit pkgs config; };
_p1 = p.dev ++ p.general ++ p.scripts ++ p.wsl;
zshInitArgs = [
"source ${pkgs.zsh-powerlevel10k}/share/zsh-powerlevel10k/powerlevel10k.zsh-theme"
"source ${pkgs.zsh-syntax-highlighting}/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh"
"[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh"
"setopt globstarshort"
];
_z1 = lib.concatMapStrings (x: x + "\n") zshInitArgs;
in
{
imports = [
inputs.sops-nix.homeManagerModules.sops
];
sops = _s1;
programs.zsh.enable = true;
programs.zsh.oh-my-zsh.enable = true;
programs.zsh.initExtra = builtins.trace _z1 _z1;
programs.java.enable = true;
programs.java.package = pkgs.temurin-bin-17;
programs.zoxide.enable = true;
programs.zoxide.enableZshIntegration = true;
programs.git.enable = true;
programs.git.userName = "sadan";
programs.git.userEmail = "117494111+sadan4@users.noreply.github.com";
programs.git.extraConfig = {
gpg.format = "ssh";
user = {
signingkey = "~/.ssh/id_ed25519";
};
commit.gpgsign = true;
core.autocrlf = "input";
pull.rebase = true;
push.autoSetupRemote = true;
init.defaultBranch = "main";
rerere.enabled = true;
};
nixpkgs.config.allowUnfreePredicate = (pkg: true);
# Home Manager needs a bit of information about you and the paths it should
# nixpkg.config.allowUnfree = true;
# manage.
home.username = "meyer";
home.homeDirectory = "/home/meyer";
services = {
flameshot = {
enable = true;
settings.General.showDesktopNotification = false;
settings.General.startupLaunch = false;
# settings.Shortcuts.TYPE_IMAGEUPLOADER = "";
# settings.Shortcuts.TYPE_COPY = "Return";
};
};
# This value determines the Home Manager release that your configuration is
# compatible with. This helps avoid breakage when a new Home Manager release
# introduces backwards incompatible changes.
#
# You should not change this value, even if you update Home Manager. If you do
# want to update the value, then make sure to first check the Home Manager
# release notes.
home.stateVersion = "23.11"; # Please read the comment before changing.
# The home.packages option allows you to install Nix packages into your
# environment.
home.packages = _p1;
# Home Manager is pretty good at managing dotfiles. The primary way to manage
# plain files is through 'home.file'.
home.file = files;
# Home Manager can also manage your environment variables through
# 'home.sessionVariables'. If you don't want to manage your shell through Home
# Manager then you have to manually source 'hm-session-vars.sh' located at
# either
#
# ~/.nix-profile/etc/profile.d/hm-session-vars.sh
#
# or
#
# ~/.local/state/nix/profiles/profile/etc/profile.d/hm-session-vars.sh
#
# or
#
# /etc/profiles/per-user/meyer/etc/profile.d/hm-session-vars.sh
#
home.shellAliases = shell.dev.aliases;
home.sessionPath = shell.dev.path;
home.sessionVariables = shell.dev.env;
# Let Home Manager install and manage itself.
programs.home-manager.enable = true;
}