1
0
Fork 0

Let alejandra do it’s thing

This commit is contained in:
Malte 2022-11-25 11:55:12 +01:00
parent 91e3578346
commit bdc8882022
13 changed files with 134 additions and 94 deletions

View file

@ -157,13 +157,13 @@ in {
(import ./roles/state.nix "default")
];
hera.default = makeConfig "hera" (on-my-machines
++ [
./roles/fetch-banking-timer.nix
./roles/weechat
./roles/mail-sort.nix
./roles/mail2rss.nix
./roles/headless-mpd.nix
./roles/headless.nix
./roles/create-plans.nix
]);
++ [
./roles/fetch-banking-timer.nix
./roles/weechat
./roles/mail-sort.nix
./roles/mail2rss.nix
./roles/headless-mpd.nix
./roles/headless.nix
./roles/create-plans.nix
]);
}

View file

@ -20,12 +20,14 @@
inherit
(pkgs)
# web
chromium
mumble
upower
speedtest-cli
acpi
# tools & office
feh
gimp
imagemagick
@ -38,6 +40,7 @@
beets
zbar
# media
ncpamixer
pavucontrol
playerctl

View file

@ -35,10 +35,13 @@
rust-analyzer
taplo
# toml
nil
# nix
texlab
# latex
lean
yaml-language-server
;
@ -100,61 +103,88 @@ in {
inherit
(pkgs.vimPlugins)
# coc-tabnine (TODO: Why doesnt it work?)
# TODO: tabnine config in home-manager
# TODO: tabnine lsp: nix, rust, pandoc/latex lsp? was noch?
# ===
# Basic IDE plugins
coc-nvim
airline
# same word highlighting when not supported by language
coc-highlight
coc-explorer
# searches
coc-fzf
fzf-vim
# general whitespace
vim-trailing-whitespace
vim-autoformat
# Git
coc-git
# statusline, numberline and explorer infos
fugitive
# various git commands
# Commenting and Uncommenting
nerdcommenter
# Theme
papercolor-theme
vim-airline-themes
LanguageTool-nvim
vim-css-color
vista-vim
# ===
# Languages
# haskell syntax highlighting
haskell-vim
vim-hoogle
# nix syntax highlighting
vim-nix
vim-markdown
# latex
vimtex
coc-vimtex
# not sure if I need two
# ledger
vim-ledger
# rust
coc-rls
# python
coc-python
# css
coc-css
# yaml
coc-yaml
# json
coc-json
# html
coc-html
# dhall
dhall-vim
;
};

View file

@ -8,11 +8,11 @@ with lib; let
weechat = pkgs.wrapWeechat pkgs.weechat-unwrapped {
configure = {availablePlugins, ...}: {
plugins = builtins.attrValues (availablePlugins
// {
python =
availablePlugins.python.withPackages
(_: [pkgs.weechatScripts.weechat-matrix]);
});
// {
python =
availablePlugins.python.withPackages
(_: [pkgs.weechatScripts.weechat-matrix]);
});
scripts = [pkgs.weechatScripts.weechat-matrix];
};
};
@ -74,12 +74,12 @@ in {
[server]
${
lib.concatStringsSep "\n" (lib.mapAttrsToList
(server: serverConfig: ''
${server}.address = "${serverConfig.address}"
${server}.autoconnect = on
${server}.username = "${serverConfig.user}"
${server}.password = "${serverConfig.password}"
'') (pkgs.privateValue {} "weechat/matrix"))
(server: serverConfig: ''
${server}.address = "${serverConfig.address}"
${server}.autoconnect = on
${server}.username = "${serverConfig.user}"
${server}.password = "${serverConfig.password}"
'') (pkgs.privateValue {} "weechat/matrix"))
}
'';
};

View file

@ -3,12 +3,12 @@ let
modes = import home-manager/machines.nix;
in
lib.listToAttrs (lib.flatten (lib.mapAttrsToList
(
host:
lib.mapAttrsToList
(mode: config: {
name = "${host}-${mode}";
value = config;
})
)
modes))
(
host:
lib.mapAttrsToList
(mode: config: {
name = "${host}-${mode}";
value = config;
})
)
modes))

View file

@ -52,7 +52,7 @@
"nix-output-monitor": {
"branch": "main",
"repo": "git@hera.m-0.eu:nix-output-monitor",
"rev": "a5f5f07de6c62b5b9dad32be2b0b6e0bab90f9ed",
"rev": "b29729f14621d13f9c8fa2b54ae00b052fbc30d9",
"type": "git"
},
"nixos-19.09": {
@ -73,10 +73,10 @@
"homepage": "",
"owner": "nixos",
"repo": "nixos-hardware",
"rev": "1108c1b8614017c8b52005054fd27a00e4feb51b",
"sha256": "05xdslgfbk6s1szswdl9iqdkc738xi2vvvhs10n1h8clvd2ynx0f",
"rev": "0099253ad0b5283f06ffe31cf010af3f9ad7837d",
"sha256": "1mav9fdr5rjipl97jp5m7cb44kx2myh7p69xl6ssmjdm87ng4ihw",
"type": "tarball",
"url": "https://github.com/nixos/nixos-hardware/archive/1108c1b8614017c8b52005054fd27a00e4feb51b.tar.gz",
"url": "https://github.com/nixos/nixos-hardware/archive/0099253ad0b5283f06ffe31cf010af3f9ad7837d.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz"
},
"nixos-mailserver": {
@ -91,10 +91,10 @@
"homepage": null,
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "cf63ade6f74bbc9d2a017290f1b2e33e8fbfa70a",
"sha256": "1aw4avc6mp3v1gwjlax6yn8984c92y56s4h7qrygxagpchkwq06j",
"rev": "68ba2f40991e79a2e4e5c5b242e175a1ad270ab9",
"sha256": "1rj54dsa1qliiwsk0jjcc0i8szm6fc6zm6lpbsr65hk0abs8fsr1",
"type": "tarball",
"url": "https://github.com/NixOS/nixpkgs/archive/cf63ade6f74bbc9d2a017290f1b2e33e8fbfa70a.tar.gz",
"url": "https://github.com/NixOS/nixpkgs/archive/68ba2f40991e79a2e4e5c5b242e175a1ad270ab9.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz"
},
"nixos-unstable": {
@ -103,10 +103,10 @@
"homepage": null,
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "af50806f7c6ab40df3e6b239099e8f8385f6c78b",
"sha256": "19sgfjdzqkigajbns6jiyqr6yvacqjx5xqbz6p6aghzjfblb2nnn",
"rev": "27ccd29078f974ddbdd7edc8e38c8c8ae003c877",
"sha256": "1lsjmwbs3nfmknnvqiqbhh103qzxyy3z1950vqmzgn5m0zx7048h",
"type": "tarball",
"url": "https://github.com/NixOS/nixpkgs/archive/af50806f7c6ab40df3e6b239099e8f8385f6c78b.tar.gz",
"url": "https://github.com/NixOS/nixpkgs/archive/27ccd29078f974ddbdd7edc8e38c8c8ae003c877.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz"
},
"nixpkgs-bot": {
@ -121,10 +121,10 @@
"homepage": "",
"owner": "cachix",
"repo": "pre-commit-hooks.nix",
"rev": "e6c8efee1c108bb27522b9fd25b1cd0eb3288681",
"sha256": "0kj05b4kbhi0vkgw73vk2ikblhw6yxdhpxv99cr3acv8mbxjxd7i",
"rev": "078b0dee35e2da01334af682ec347463b70a9986",
"sha256": "10d2bylrxgzhff3iw8dawgp181clh2kfsa6vf3br2n6bhixd2h0l",
"type": "tarball",
"url": "https://github.com/cachix/pre-commit-hooks.nix/archive/e6c8efee1c108bb27522b9fd25b1cd0eb3288681.tar.gz",
"url": "https://github.com/cachix/pre-commit-hooks.nix/archive/078b0dee35e2da01334af682ec347463b70a9986.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz"
},
"wizards-dialog": {

View file

@ -96,10 +96,10 @@ in {
};
}
// lib.listToAttrs (map (name: {
inherit name;
value = {serviceConfig.Type = "oneshot";};
})
backupJobNames);
inherit name;
value = {serviceConfig.Type = "oneshot";};
})
backupJobNames);
services = {
postgresql = {
enable = true;

View file

@ -45,7 +45,7 @@ in {
cert = "${key_dir}/fullchain.pem";
static-auth-secret =
(pkgs.privateValue {turn_shared_secret = "";}
"matrix/server-secrets")
"matrix/server-secrets")
.turn_shared_secret;
realm = fqdn;
listening-ips = [config.m-0.hosts.hera config.m-0.hosts.hera-v4];

View file

@ -20,21 +20,21 @@
Matrix = {
Mappings = [
(default_mailbox
// {
MailboxName = "notify";
MatrixRoomId = "!kTKVQjRwxjaoMQmcve:maralorn.de";
})
// {
MailboxName = "notify";
MatrixRoomId = "!kTKVQjRwxjaoMQmcve:maralorn.de";
})
(default_mailbox
// {
MailboxName = "subjects";
MatrixRoomId = "!kTKVQjRwxjaoMQmcve:maralorn.de";
IgnoreBody = true;
})
// {
MailboxName = "subjects";
MatrixRoomId = "!kTKVQjRwxjaoMQmcve:maralorn.de";
IgnoreBody = true;
})
(default_mailbox
// {
MailboxName = "weather";
MatrixRoomId = "!ELeFcSrHXgMqOmwnxg:maralorn.de";
})
// {
MailboxName = "weather";
MatrixRoomId = "!ELeFcSrHXgMqOmwnxg:maralorn.de";
})
];
};
Misc = {Debug = true;};

View file

@ -21,14 +21,19 @@
(pkgs)
nerdfonts
# For all my terminal needs.
libertinus
# nice text font
material-icons
# icons in my app
b612
# sans font, very good for displays
noto-fonts
# for unicode fallback
;
};
};
@ -40,9 +45,9 @@
font_sources = map (v: v.src) (lib.filter (v: v ? src) config.fonts.fonts);
in
builtins.listToAttrs (lib.imap0
(n: source:
lib.nameValuePair "src-cache/fonts/${toString n}" {
inherit source;
})
font_sources);
(n: source:
lib.nameValuePair "src-cache/fonts/${toString n}" {
inherit source;
})
font_sources);
}

View file

@ -378,26 +378,26 @@ in {
}
]
++ (map
(minutes: {
alias = "Warnung bei ${minutes} Minuten offenem Fenster oder offener Tür";
trigger =
map
(name:
triggers.stateTrigger name
// {
to = "on";
for = "00:${minutes}:00";
})
fenster;
#condition = {
# condition = "numeric_state";
# entity_id = "weather.dwd_darmstadt";
# attribute = "temperature";
# below = 15;
#};
action = [(actions.notify "{{ trigger.to_state.name }} ist seit mehr als ${minutes} Minuten offen.")];
})
(map toString [10 20 30 40 50 60]));
(minutes: {
alias = "Warnung bei ${minutes} Minuten offenem Fenster oder offener Tür";
trigger =
map
(name:
triggers.stateTrigger name
// {
to = "on";
for = "00:${minutes}:00";
})
fenster;
#condition = {
# condition = "numeric_state";
# entity_id = "weather.dwd_darmstadt";
# attribute = "temperature";
# below = 15;
#};
action = [(actions.notify "{{ trigger.to_state.name }} ist seit mehr als ${minutes} Minuten offen.")];
})
(map toString [10 20 30 40 50 60]));
history = {};
image = {};
sun = {};

View file

@ -30,15 +30,15 @@
environment = {
# Put these into an extra file so the essential packages can also be included on non selfadminstrated systems from home-manager
systemPackages = builtins.attrValues ({
inherit
(import ../../../lib/update-system.nix {
inherit pkgs;
inherit (config.system.build) nixos-rebuild;
})
update-system
;
}
// pkgs.system-pkgs);
inherit
(import ../../../lib/update-system.nix {
inherit pkgs;
inherit (config.system.build) nixos-rebuild;
})
update-system
;
}
// pkgs.system-pkgs);
};
programs = {

View file

@ -93,8 +93,10 @@ self: super: {
(self)
esphome
# To flash devices
esptool
# provides esptool.py
dconf
lm_sensors
xwayland