initial commit

This commit is contained in:
Astreaprtcl 2025-12-17 12:59:28 +01:00
commit ddd861496e
16 changed files with 361 additions and 0 deletions

7
users/all.nix Normal file
View file

@ -0,0 +1,7 @@
{ ... }:
{
imports = [
./mara/config.nix
];
}

11
users/home-default.nix Normal file
View file

@ -0,0 +1,11 @@
{ osConfig, ... }:
{
programs.home-manager.enable = true;
nixpkgs.config.allowUnfree = true;
home = {
stateVersion = osConfig.system.stateVersion;
enableNixpkgsReleaseCheck = false;
};
}

41
users/mara/config.nix Normal file
View file

@ -0,0 +1,41 @@
{ config, lib, pkgs, home-manager, ... }:
let
cfg = config.users.mara;
in
with lib;
{
options.users.mara.enable = mkEnableOption "Enable the user Mara";
config = mkIf cfg.enable {
home-manager.users.mara = { config, pkgs, ... }:
{
imports = [
../home-default.nix
./config/all.nix
];
home = {
username = "mara";
homeDirectory = "/home/mara";
};
};
programs.fish.enable = true;
users.users.mara = {
isNormalUser = true;
description = "Mara";
extraGroups = [
"networkmanager"
"wheel"
"docker"
"adbusers"
];
shell = pkgs.fish;
};
};
}

View file

@ -0,0 +1,8 @@
{ ... }:
{
imports = [
./fish.nix
./helix.nix
];
}

View file

@ -0,0 +1,24 @@
{ ... }:
{
programs.fish = {
enable = true;
interactiveShellInit = ''
set fish_greeting
'';
functions = {
fish_prompt.body = ''
printf '%s %s > ' (set_color purple)(whoami)@(prompt_hostname) (set_color blue)(prompt_pwd)(set_color normal)
'';
fish_right_prompt.body = ''
set stat $status
set -g __fish_git_prompt_showupstream verbose
set -g __fish_git_prompt_showcolorhints 1
printf '%s %s' (fish_vcs_prompt) [(set_color red)$stat(set_color normal)]
'';
};
};
}

View file

@ -0,0 +1,32 @@
{ pkgs, ... }:
{
programs.helix = {
enable = true;
defaultEditor = true;
settings = {
theme = "catppuccin_macchiato";
editor = {
cursorline = true;
color-modes = true;
true-color = true;
cursor-shape.insert = "bar";
indent-guides.render = true;
};
};
languages.language = [
{
name = "nix";
auto-format = true;
formatter.command = "${pkgs.nixfmt}/bin/nixfmt";
}
];
themes.catppuccin_macchiato = {
inherits = "catppuccin_macchiato";
"ui.background" = { };
};
};
}