{ inputs, config, pkgs, lib, ... }: { # These modules are each responsible for responding appropriately to the options imports = [ ./docker.nix ./ghostty.nix ./git.nix ./shell.nix ./sops.nix ./ssh.nix ./vscode.nix ../nixosModules/options.nix inputs._1password-shell-plugins.hmModules.default ]; nixpkgs.config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [ "1password-cli" "discord" "spotify" "steam" "steam-original" "steam-unwrapped" "steam-run" "sublimetext4" "vscode" "vscode-extension-mhutchie-git-graph" "vscode-extension-ms-vscode-remote-vscode-remote-extensionpack" "vscode-extension-MS-python-vscode-pylance" "vscode-extension-github-copilot" ]; nixpkgs.config.permittedInsecurePackages = [ "openssl-1.1.1w" ]; # Home Manager needs a bit of information about you and the paths it should # manage. home.username = config.user; home.homeDirectory = lib.mkIf (config.user != "root") "/home/${config.user}"; home.stateVersion = config.stateVersion; # The home.packages option allows you to install Nix packages into your # environment. home.packages = with pkgs; [ wget curl cacert busybox gnugrep dig gdu lazygit btop yazi uv (writeShellScriptBin "nhmu" '' nix flake update --flake ~/.config/home-manager nix run home-manager -- switch --flake ~/.config/home-manager --impure '') # # It is sometimes useful to fine-tune packages, for example, by applying # # overrides. You can do that directly here, just don't forget the # # parentheses. Maybe you want to install Nerd Fonts with a limited number of # # fonts? # (pkgs.nerdfonts.override { fonts = [ "FantasqueSansMono" ]; }) ] ++ lib.optional config.graphical.discord discord ++ lib.optional config.graphical.joplin joplin-desktop ++ lib.optional config.graphical.sublime sublime4; # Home Manager can also manage your environment variables through # 'home.sessionVariables'. These will be explicitly sourced when using a # shell provided by Home Manager. 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/john/etc/profile.d/hm-session-vars.sh # home.sessionVariables = { # EDITOR = "emacs"; }; # Let Home Manager install and manage itself. programs.home-manager.enable = true; # # https://developer.1password.com/docs/cli/shell-plugins/nix/ # programs._1password-shell-plugins = lib.mkIf config._1password { # # enable 1Password shell plugins for bash, zsh, and fish shell # enable = true; # # the specified packages as well as 1Password CLI will be # # automatically installed and configured to use shell plugins # # https://developer.1password.com/docs/cli/shell-plugins # plugins = with pkgs; [ gh ]; # }; home.file.".config/1Password/ssh/agent.toml" = lib.mkIf config._1password { # https://developer.1password.com/docs/ssh/agent/config text = '' [[ssh-keys]] vault = "Private" ''; }; }