Add tools.coding option
This commit is contained in:
31
common/coding.nix
Normal file
31
common/coding.nix
Normal file
@@ -0,0 +1,31 @@
|
||||
{ lib, config, ... }:
|
||||
with lib;
|
||||
{
|
||||
options = {
|
||||
tools.coding = {
|
||||
enable = mkEnableOption "Enable coding tools";
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf config.tools.coding.enable {
|
||||
programs.git = {
|
||||
enable = true;
|
||||
lfs.enable = true;
|
||||
config = {
|
||||
init.defaultBranch = "master";
|
||||
user = {
|
||||
email = "git@nettika.cat";
|
||||
name = "Nettika";
|
||||
};
|
||||
credential.helper = "store";
|
||||
};
|
||||
};
|
||||
programs.nano = {
|
||||
enable = true;
|
||||
nanorc = ''
|
||||
set autoindent
|
||||
set linenumbers
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
@@ -1,11 +1,7 @@
|
||||
{ pkgs, lib, config, ... }:
|
||||
with lib;
|
||||
{
|
||||
options.tools.secrets = {
|
||||
enable = mkEnableOption "Enable secret-management tools";
|
||||
};
|
||||
|
||||
config = mkIf config.tools.secrets.enable {
|
||||
environment.systemPackages = [ pkgs.git-crypt ];
|
||||
};
|
||||
imports = [
|
||||
./coding.nix
|
||||
./secrets.nix
|
||||
];
|
||||
}
|
||||
|
13
common/secrets.nix
Normal file
13
common/secrets.nix
Normal file
@@ -0,0 +1,13 @@
|
||||
{ lib, config, pkgs, ... }:
|
||||
with lib;
|
||||
{
|
||||
options = {
|
||||
tools.secrets = {
|
||||
enable = mkEnableOption "Enable secret-management tools";
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf config.tools.secrets.enable {
|
||||
environment.systemPackages = [ pkgs.git-crypt ];
|
||||
};
|
||||
}
|
@@ -53,7 +53,6 @@
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
users.users = {
|
||||
nettika = {
|
||||
isNormalUser = true;
|
||||
@@ -69,6 +68,10 @@
|
||||
enable = true;
|
||||
};
|
||||
|
||||
tools.coding = {
|
||||
enable = true;
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
# Chat clients
|
||||
discord
|
||||
@@ -93,27 +96,6 @@
|
||||
obsidian
|
||||
];
|
||||
|
||||
programs.git = {
|
||||
enable = true;
|
||||
lfs.enable = true;
|
||||
config = {
|
||||
init.defaultBranch = "master";
|
||||
user = {
|
||||
email = "git@nettika.cat";
|
||||
name = "Nettika";
|
||||
};
|
||||
credential.helper = "store";
|
||||
};
|
||||
};
|
||||
|
||||
programs.nano = {
|
||||
enable = true;
|
||||
nanorc = ''
|
||||
set autoindent
|
||||
set linenumbers
|
||||
'';
|
||||
};
|
||||
|
||||
programs.steam = {
|
||||
enable = true;
|
||||
remotePlay.openFirewall = true;
|
||||
|
@@ -41,25 +41,8 @@
|
||||
enable = true;
|
||||
};
|
||||
|
||||
programs.git = {
|
||||
tools.coding = {
|
||||
enable = true;
|
||||
lfs.enable = true;
|
||||
config = {
|
||||
init.defaultBranch = "master";
|
||||
user = {
|
||||
email = "git@nettika.cat";
|
||||
name = "Nettika";
|
||||
};
|
||||
credential.helper = "store";
|
||||
};
|
||||
};
|
||||
|
||||
programs.nano = {
|
||||
enable = true;
|
||||
nanorc = ''
|
||||
set autoindent
|
||||
set linenumbers
|
||||
'';
|
||||
};
|
||||
|
||||
services.openssh = {
|
||||
|
Reference in New Issue
Block a user