initial nixos-config

This commit is contained in:
2023-08-01 05:06:16 +00:00
parent 0a7012b316
commit 6cc6a1f32c
17 changed files with 366 additions and 0 deletions

16
home/modules/cli/bash.nix Normal file
View File

@ -0,0 +1,16 @@
{ config, lib, pkgs, ...}:
let
inherit (lib) mkIf;
hasNeovim = config.programs.neovim.enable;
in
{
programs.bash = {
enable = true;
shellAliases = {
ll = "ls -lisah --color=auto";
".." = "cd ..";
vim = mkIf hasNeovim "nvim";
vi = mkIf hasNeovim "nvim";
};
};
}

6
home/modules/cli/bat.nix Normal file
View File

@ -0,0 +1,6 @@
{
programs.bat = {
enable = true;
config.theme = "base16";
};
}

View File

@ -0,0 +1,8 @@
{
imports = [
./bash.nix
./git.nix
./bat.nix
];
}

8
home/modules/cli/git.nix Normal file
View File

@ -0,0 +1,8 @@
{
programs.git = {
enable = true;
userName = "crurak";
userEmail = "s.spangenberg@posteo.de";
ignores = [ ".direnv" "result"];
};
}

View File

@ -0,0 +1,3 @@
{
}

View File

@ -0,0 +1,3 @@
{
}

View File

@ -0,0 +1,4 @@
{ config, pkgs, ... }: {
hyprland.homeManagerModules.default
}

View File

@ -0,0 +1,8 @@
{
programs.librewolf = {
enable = true;
settings = {
};
};
}

View File

@ -0,0 +1,23 @@
{ config, pkgs, ...}:
{
home.sessionVariables.Editor = "nvim";
programs = {
neovim = {
enable = true;
extraConfig = ''
syntax enable
colorscheme gruvbox
set number relativenumber
highlight Comment cterm=italic gui=italic
hi Normal guibg=NONE ctermbg=NONE
'';
plugins = with pkgs.vimPlugins; [
vim-nix
gruvbox
];
};
};
}

View File

@ -0,0 +1,27 @@
{ inputs, lib, config, pkgs, outputs, ... }: {
imports = [
../modules/neovim
../modules/cli
];
nixpkgs = {
config = {
allowUnfree = true; # Allow unfree packages
allowUnfreePredicate = (_: true); # Workaround for https://github.com/nix-community/home-manager/issues/2942
};
};
home = {
username = "stefan";
homeDirectory = "/home/stefan";
stateVersion = "23.05"; # https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion
};
programs = {
home-manager.enable = true; # Enable home-manager
};
systemd.user.startServices = "sd-switch"; # Reload system units when changing configs
}