-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathuser-specific.nix
83 lines (73 loc) · 2.09 KB
/
user-specific.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
# Author: Viacheslav Lotsmanov
# License: MIT https://raw.githubusercontent.com/unclechu/nixos-config/master/LICENSE
args@{ pkgs, lib, ... }:
let
sources = import nix/sources.nix;
inherit (import ./constants.nix)
wenzelUserName
rawdevinputGroupName
backlightcontrolGroupName
cpumodecontrolGroupName
jackaudioGroupName
audioGroupName
;
inherit ((import ./my-packages.nix args).my-apps) wenzels-bash;
in
{
imports = [
(import "${sources.home-manager}/nixos")
user-specific/dunst.nix
user-specific/mouse-cursor
user-specific/gui.nix
];
users = {
# See also “users.users.${wenzelUserName}.packages” in “my-packages.nix”
users.${wenzelUserName} = {
uid = 1989;
isNormalUser = true;
group = wenzelUserName;
shell = wenzels-bash;
extraGroups = [
"users"
"wheel"
"networkmanager"
rawdevinputGroupName
backlightcontrolGroupName
cpumodecontrolGroupName
"docker"
"vboxusers"
jackaudioGroupName
audioGroupName
];
};
groups = {
${wenzelUserName}.gid = 1989;
${rawdevinputGroupName}.gid = 500;
${backlightcontrolGroupName}.gid = 501;
${cpumodecontrolGroupName}.gid = 502;
};
};
home-manager.users.${wenzelUserName} = {
home.stateVersion = "22.05";
programs.git = {
enable = true;
userName = "Viacheslav Lotsmanov";
userEmail = "[email protected]";
signing = {
signByDefault = true;
key = null;
};
extraConfig = {
# Enable support for git-subtrac kind of techniques for managing Git
# Submodules. When submodule path is set to the same repo (e.g. “.”)
# Git fails to do git-submodule-update with an error like this:
# “fatal: transport 'file' not allowed”. This fixes this problem.
# See also https://github.com/apenwarr/git-subtrac
protocol.file.allow = "always";
};
};
home.file.".bashrc".text = ''
. ${lib.escapeShellArg wenzels-bash.history-settings-file-path}
'';
};
}