mirror of
https://github.com/ellmau/nixos.git
synced 2025-12-19 09:29:36 +01:00
Add base, local, and zsh configuration modules
This commit is contained in:
parent
0b7566e486
commit
b77a255a38
11
README.md
11
README.md
@ -12,3 +12,14 @@
|
|||||||
* `nix-shell -p nixFlakes`
|
* `nix-shell -p nixFlakes`
|
||||||
* `sudo _NIXOS_REBUILD_REEXEC=1 nixos-install --no-root-passwd --flake .#hostname`
|
* `sudo _NIXOS_REBUILD_REEXEC=1 nixos-install --no-root-passwd --flake .#hostname`
|
||||||
* ~~`nixos-install --no-root-passwd --flake .#hostname`~~
|
* ~~`nixos-install --no-root-passwd --flake .#hostname`~~
|
||||||
|
|
||||||
|
|
||||||
|
# redesign checklist
|
||||||
|
- [ ] lorri or similar
|
||||||
|
- [ ] whole home manager stuff
|
||||||
|
- [ ] baseconfiguration handled
|
||||||
|
- [ ] programs handled
|
||||||
|
- [X] locale/fonts
|
||||||
|
- [X] zsh
|
||||||
|
- [ ] gnupg agent
|
||||||
|
|
||||||
|
|||||||
52
modules/base.nix
Normal file
52
modules/base.nix
Normal file
@ -0,0 +1,52 @@
|
|||||||
|
{ config, lib, pkgs, ...} :
|
||||||
|
with lib; {
|
||||||
|
options.elss.base.enable = mkEnableOption "Set the base configuration for the system";
|
||||||
|
config = mkIf config.elss.base.enable {
|
||||||
|
services = {
|
||||||
|
dbus = {
|
||||||
|
enable = true;
|
||||||
|
packages = with pkgs; [ gnome3.dconf ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
programs = {
|
||||||
|
mtr.enable = true;
|
||||||
|
dconf.enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
documentation = {
|
||||||
|
enable = true;
|
||||||
|
man.enable = true;
|
||||||
|
dev.enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
alacritty.terminfo
|
||||||
|
bintools
|
||||||
|
clang
|
||||||
|
elfutils
|
||||||
|
emacs-all-the-icon-fonts
|
||||||
|
gdb
|
||||||
|
git
|
||||||
|
procs
|
||||||
|
rnis-lsp
|
||||||
|
sysstat
|
||||||
|
tcpdump
|
||||||
|
unzip
|
||||||
|
wget
|
||||||
|
];
|
||||||
|
|
||||||
|
elss = {
|
||||||
|
locale.enable = mkDefault true;
|
||||||
|
zsh.enable = mkdDefault true;
|
||||||
|
};
|
||||||
|
|
||||||
|
boot = {
|
||||||
|
loader = {
|
||||||
|
systemd-boot.enable = mkDefault true;
|
||||||
|
efi.canTouchEfiVariables = mkDefault true;
|
||||||
|
};
|
||||||
|
kernelPackages = mkDefault pkgs.linuxPackages_latest;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
40
modules/locale.nix
Normal file
40
modules/locale.nix
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
{ config, pkgs, lib, ...}:
|
||||||
|
with lib; {
|
||||||
|
options.elss.locale.enable = mkEnableOption "setup default locale and font-handling";
|
||||||
|
|
||||||
|
config = mkIf config.elss.locale.enable {
|
||||||
|
time.timeZone = "Europe/Berlin";
|
||||||
|
i18n.defaultLocale = "en_GB.UTF-8";
|
||||||
|
|
||||||
|
fonts = {
|
||||||
|
enableDefaultFonts = true;
|
||||||
|
fonts = with pkgs; [
|
||||||
|
hasklig
|
||||||
|
# corefonts # not free
|
||||||
|
liberation_ttf
|
||||||
|
comic-relief
|
||||||
|
dejavu_fonts
|
||||||
|
gyre-fonts
|
||||||
|
open-sans
|
||||||
|
noto-fonts
|
||||||
|
noto-fonts-emoji
|
||||||
|
noto-fonts-extra
|
||||||
|
roboto
|
||||||
|
roboto-mono
|
||||||
|
(nerdfonts.override { fonts = [ "Hasklig" ]; })
|
||||||
|
material-icons
|
||||||
|
weather-icons
|
||||||
|
];
|
||||||
|
|
||||||
|
fontconfig = {
|
||||||
|
enable = true;
|
||||||
|
# defaultFonts = {
|
||||||
|
# serif = [ "TeX Gyre Heros" ];
|
||||||
|
# emoji = [ "Noto Color Emoji" ];
|
||||||
|
# sansSerif = [ "TeX Gyre Pagella" ];
|
||||||
|
# monospace = [ "Hasklug Nerd Font Mono" ];
|
||||||
|
# };
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
34
modules/zsh.nix
Normal file
34
modules/zsh.nix
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
{ config, pkgs, lib, ...}:
|
||||||
|
with lib; {
|
||||||
|
options.elss.zsh.enable = mkEnableOption "Setup systemwide zsh";
|
||||||
|
config = {
|
||||||
|
environment = {
|
||||||
|
shells = [ pkgs.zsh ];
|
||||||
|
pathsToLink = [ "/share/zsh/" ];
|
||||||
|
sessionVariables = rec {
|
||||||
|
XDG_CACHE_HOME = "\${HOME}/.cache";
|
||||||
|
XDG_CONFIG_HOME = "\${HOME}/.config";
|
||||||
|
XDG_BIN_HOME = "\${HOME}/.local/bin";
|
||||||
|
XDG_DATA_HOME = "\${HOME}/.local/share";
|
||||||
|
|
||||||
|
PATH = [
|
||||||
|
"\${XDG_BIN_HOME}"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
programs = {
|
||||||
|
zsh = {
|
||||||
|
enable = true;
|
||||||
|
enableCompletion = true;
|
||||||
|
enableGlobalCompInit = true;
|
||||||
|
autosuggestions.enable = true;
|
||||||
|
syntaxHighlighting = {
|
||||||
|
enable = true;
|
||||||
|
highlighters = [ "main" "brackets" "root" "line" ];
|
||||||
|
#styles = { cursor = "standout,underline"; };
|
||||||
|
};
|
||||||
|
setOptions = [ "auto_pushd" "correct" "nocaseglob" "rcexpandparam" "numericglobsort" "nobeep" "appendhistory" ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
Loading…
x
Reference in New Issue
Block a user