nixos: add home-manager

This commit is contained in:
Maciej Jur 2024-06-28 00:49:04 +02:00
parent aef79fbef9
commit 206bd48fb2
Signed by: kamov
GPG key ID: 191CBFF5F72ECAFD
2 changed files with 73 additions and 40 deletions

View file

@ -12,10 +12,12 @@ let
wget wget
gnumake gnumake
gcc gcc
nodejs_22
# Language servers # Lua
(luajit.withPackages (p: with p; [ luarocks ]))
lua-language-server lua-language-server
# Nix
nixd nixd
# Neovim # Neovim
@ -30,11 +32,11 @@ let
in in
{ {
imports = imports =
[ # Include the results of the hardware scan. [
<home-manager/nixos>
./hardware-configuration.nix ./hardware-configuration.nix
./nvidia.nix ./nvidia.nix
./boot.nix ./boot.nix
./home.nix
./gaming.nix ./gaming.nix
]; ];
@ -119,26 +121,34 @@ in
# started in user sessions. # started in user sessions.
# programs.mtr.enable = true; # programs.mtr.enable = true;
programs = { programs = {
fish.enable = true;
gnupg = { gnupg = {
agent = { agent = {
enable = true; enable = true;
enableSSHSupport = true; enableSSHSupport = true;
}; };
}; };
fish.enable = true; firefox = {
git = {
enable = true; enable = true;
config = { package = pkgs.firefox-devedition;
user.name = "Maciej Jur"; preferences = {
user.email = "maciej@kamoshi.org"; "widget.use-xdg-desktop-portal.file-picker" = 1;
user.signingkey = "191CBFF5F72ECAFD!"; "widget.use-xdg-desktop-portal.mime-handler" = 1;
commit.gpgsign = true;
init.defaultBranch = "main";
core.editor = "vim";
}; };
}; };
}; };
users.users.kamov = {
isNormalUser = true;
extraGroups = [ "wheel" ]; # Enable sudo
shell = pkgs.fish;
};
home-manager = {
useGlobalPkgs = true;
users.kamov = import ./home.nix;
};
# List services that you want to enable: # List services that you want to enable:
# Enable the OpenSSH daemon. # Enable the OpenSSH daemon.

View file

@ -1,4 +1,4 @@
{ config, lib, pkgs, ... }: { pkgs, ... }:
let let
unstable = import <unstable> {}; unstable = import <unstable> {};
packages = (with pkgs; [ packages = (with pkgs; [
@ -9,24 +9,47 @@ let
qbittorrent qbittorrent
spotify spotify
vlc vlc
obs-studio
audacity
]) ++ (with unstable; [ ]) ++ (with unstable; [
neovide neovide
]); ]);
in in
{ {
programs.firefox = { home = {
# Home Manager needs a bit of information about you and the
# paths it should manage.
username = "kamov";
homeDirectory = "/home/kamov";
# Packages that should be installed to the user profile.
packages = packages;
};
programs = {
# default shell
fish.enable = true;
git = {
enable = true; enable = true;
package = pkgs.firefox-devedition; userName = "Maciej Jur";
preferences = { userEmail = "maciej@kamoshi.org";
"widget.use-xdg-desktop-portal.file-picker" = 1; signing = {
"widget.use-xdg-desktop-portal.mime-handler" = 1; signByDefault = true;
key = "191CBFF5F72ECAFD!";
};
}; };
}; };
users.users.kamov = { services.kdeconnect.enable = true;
isNormalUser = true;
extraGroups = [ "wheel" ]; # Enable sudo # This value determines the Home Manager release that your
packages = packages; # configuration is compatible with. This helps avoid breakage
shell = pkgs.fish; # when a new Home Manager release introduces backwards
}; # incompatible changes.
#
# You can update Home Manager without changing this value. See
# the Home Manager release notes for a list of state version
# changes in each release.
home.stateVersion = "24.05";
} }