Compare commits
68 Commits
78990e6414
...
flake-upda
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ae8979ecac | ||
|
|
6ac05c77b0 | ||
|
|
f10670f2be | ||
|
|
123612e4b3 | ||
|
|
b67666ac19 | ||
|
|
c403e02878 | ||
|
|
6b3d94e787 | ||
|
|
4802dcc0e0 | ||
|
|
3fec4d8c72 | ||
|
|
1390c1ca8b | ||
|
|
cb024f6f11 | ||
|
|
04684dcf6b | ||
|
|
e57a577182 | ||
|
|
4cbf77ef20 | ||
|
|
f338454ef1 | ||
|
|
f0c6c990e4 | ||
|
|
0f4e26660e | ||
|
|
844e698dfb | ||
|
|
8d72ed2b3b | ||
|
|
1713a086a1 | ||
|
|
79c944f7a8 | ||
|
|
222849e75c | ||
|
|
d6c07272e7 | ||
|
|
5014f64ed7 | ||
|
|
a9a023a8ff | ||
|
|
e0613fafa1 | ||
|
|
20679985ad | ||
|
|
2b41d1934e | ||
|
|
0da9684522 | ||
|
|
d16e295469 | ||
|
|
1c4116bc3d | ||
|
|
03c9db6ea4 | ||
|
|
3188aeb85f | ||
|
|
0fbdf4f481 | ||
|
|
4102e76f44 | ||
|
|
e41f2cbf7d | ||
|
|
511755748e | ||
| 349181f35b | |||
| 0b8b7564a1 | |||
| 54e0f94af5 | |||
| 977aa539a3 | |||
| d56605e37a | |||
| 7d013c83bc | |||
| d42f38531d | |||
| af54219f5f | |||
| b6f59055d8 | |||
| cb990c0cd4 | |||
| c896e02bf1 | |||
| c1e031efa9 | |||
| 19f213ca8c | |||
| a0ebb3f259 | |||
| 3a994a3b8d | |||
| 3b4c0e4a63 | |||
| b15dd4ce86 | |||
| db5514062c | |||
| 7b500ee994 | |||
| 07eb4664f9 | |||
| 872f80e92c | |||
| 562f873f97 | |||
| 2f5868fcca | |||
| e1c1f6e104 | |||
| 3bdf73557b | |||
| bb9988245a | |||
| 713f5bfe8c | |||
| c26f4ccd9a | |||
| d84bfd4628 | |||
| fb6ac408e1 | |||
| f01b079931 |
@@ -1,7 +1,12 @@
|
|||||||
#+title: My dotfiles
|
#+title: My dotfiles
|
||||||
|
|
||||||
My dotfiles for which I am using =nix=.
|
* Quick start for home-manger only (no need to pull this repo)
|
||||||
The structure is managed by [[https://snowfall.org/guides/lib/quickstart/][Snowfall lib]]
|
- Install nix using the https://github.com/DeterminateSystems/nix-installer
|
||||||
|
- Then run
|
||||||
|
#+begin_src shell
|
||||||
|
nix run nixpkgs#home-manager -- switch --flake git+https://gitlab.julian-mutter.de/julian/dotfiles.git#julian@quickstart
|
||||||
|
#+end_src
|
||||||
|
- Done
|
||||||
|
|
||||||
* Machine selection
|
* Machine selection
|
||||||
=home-manager= automatically searches for =user= or =user@hostname= config in the flake, so specify one of those or you will have to manually specify them:
|
=home-manager= automatically searches for =user= or =user@hostname= config in the flake, so specify one of those or you will have to manually specify them:
|
||||||
|
|||||||
860
flake.lock
generated
860
flake.lock
generated
File diff suppressed because it is too large
Load Diff
68
flake.nix
68
flake.nix
@@ -19,6 +19,10 @@
|
|||||||
url = "github:nix-community/home-manager/release-25.11";
|
url = "github:nix-community/home-manager/release-25.11";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
nix-index-database = {
|
||||||
|
url = "github:nix-community/nix-index-database";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
sops-nix = {
|
sops-nix = {
|
||||||
url = "github:Mic92/sops-nix";
|
url = "github:Mic92/sops-nix";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
@@ -94,18 +98,20 @@
|
|||||||
nixosConfigurations = {
|
nixosConfigurations = {
|
||||||
# Main laptop
|
# Main laptop
|
||||||
aspi = lib.nixosSystem {
|
aspi = lib.nixosSystem {
|
||||||
modules = [./hosts/aspi];
|
modules = [
|
||||||
|
./hosts/aspi
|
||||||
|
];
|
||||||
specialArgs = {
|
specialArgs = {
|
||||||
inherit inputs outputs;
|
inherit inputs outputs;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
# Piano raspberry pi
|
# Piano raspberry pi
|
||||||
pianonix = lib.nixosSystem {
|
# pianonix = lib.nixosSystem {
|
||||||
modules = [./hosts/pianonix];
|
# modules = [./hosts/pianonix];
|
||||||
specialArgs = {
|
# specialArgs = {
|
||||||
inherit inputs outputs;
|
# inherit inputs outputs;
|
||||||
};
|
# };
|
||||||
};
|
# };
|
||||||
kardorf = lib.nixosSystem {
|
kardorf = lib.nixosSystem {
|
||||||
modules = [./hosts/kardorf];
|
modules = [./hosts/kardorf];
|
||||||
specialArgs = {
|
specialArgs = {
|
||||||
@@ -134,16 +140,16 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
# Media server (RPi)
|
# Media server (RPi)
|
||||||
"julian@pianonix" = lib.homeManagerConfiguration {
|
# "julian@pianonix" = lib.homeManagerConfiguration {
|
||||||
modules = [
|
# modules = [
|
||||||
./homes/julian/pianonix.nix
|
# ./homes/julian/pianonix.nix
|
||||||
./homes/julian/hm-standalone-config.nix
|
# ./homes/julian/hm-standalone-config.nix
|
||||||
];
|
# ];
|
||||||
pkgs = pkgsFor.aarch64-linux;
|
# pkgs = pkgsFor.aarch64-linux;
|
||||||
extraSpecialArgs = {
|
# extraSpecialArgs = {
|
||||||
inherit inputs outputs;
|
# inherit inputs outputs;
|
||||||
};
|
# };
|
||||||
};
|
# };
|
||||||
"julian@kardorf" = lib.homeManagerConfiguration {
|
"julian@kardorf" = lib.homeManagerConfiguration {
|
||||||
modules = [
|
modules = [
|
||||||
./homes/julian/kardorf.nix
|
./homes/julian/kardorf.nix
|
||||||
@@ -164,19 +170,29 @@
|
|||||||
inherit inputs outputs;
|
inherit inputs outputs;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
"julian@quickstart" = lib.homeManagerConfiguration {
|
||||||
|
modules = [
|
||||||
|
./homes/julian/quickstart.nix
|
||||||
|
./homes/julian/hm-standalone-config.nix
|
||||||
|
];
|
||||||
|
pkgs = pkgsFor.x86_64-linux;
|
||||||
|
extraSpecialArgs = {
|
||||||
|
inherit inputs outputs;
|
||||||
|
};
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
# deploy-rs node configuration
|
# deploy-rs node configuration
|
||||||
deploy.nodes = {
|
deploy.nodes = {
|
||||||
pianonix = {
|
# pianonix = {
|
||||||
hostname = "pianonix.local";
|
# hostname = "pianonix.local";
|
||||||
profiles.system = {
|
# profiles.system = {
|
||||||
sshUser = "root";
|
# sshUser = "root";
|
||||||
user = "root";
|
# user = "root";
|
||||||
path = inputs.deploy-rs.lib.aarch64-linux.activate.nixos self.nixosConfigurations.pianonix;
|
# path = inputs.deploy-rs.lib.aarch64-linux.activate.nixos self.nixosConfigurations.pianonix;
|
||||||
confirmTimeout = 90; # default: 30s; raspberrypi takes a little longer restarting services
|
# confirmTimeout = 90; # default: 30s; raspberrypi takes a little longer restarting services
|
||||||
};
|
# };
|
||||||
};
|
# };
|
||||||
|
|
||||||
builder = {
|
builder = {
|
||||||
hostname = "builder.julian-mutter.de";
|
hostname = "builder.julian-mutter.de";
|
||||||
|
|||||||
@@ -68,6 +68,26 @@ in {
|
|||||||
|
|
||||||
emacs-all-the-icons-fonts
|
emacs-all-the-icons-fonts
|
||||||
frajul.typst-languagetool
|
frajul.typst-languagetool
|
||||||
|
ltex-ls-plus
|
||||||
|
|
||||||
|
(texlive.combine {
|
||||||
|
inherit
|
||||||
|
(texlive)
|
||||||
|
scheme-basic
|
||||||
|
# for rendering latex in inkscape
|
||||||
|
standalone
|
||||||
|
amsmath
|
||||||
|
preview
|
||||||
|
# needed for org mode preview
|
||||||
|
dvisvgm
|
||||||
|
dvipng # for preview and export as html
|
||||||
|
wrapfig
|
||||||
|
# amsmath
|
||||||
|
ulem
|
||||||
|
hyperref
|
||||||
|
capt-of
|
||||||
|
;
|
||||||
|
})
|
||||||
]
|
]
|
||||||
++ lib.optional config.is-nixos emacs;
|
++ lib.optional config.is-nixos emacs;
|
||||||
|
|
||||||
|
|||||||
@@ -27,6 +27,11 @@ with lib; {
|
|||||||
enableFishIntegration = true;
|
enableFishIntegration = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
programs.zoxide = {
|
||||||
|
enable = true;
|
||||||
|
enableFishIntegration = true;
|
||||||
|
};
|
||||||
|
|
||||||
programs.fish = {
|
programs.fish = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
||||||
@@ -38,14 +43,14 @@ with lib; {
|
|||||||
cd $argv
|
cd $argv
|
||||||
'';
|
'';
|
||||||
run = ''
|
run = ''
|
||||||
nix run nixpkgs#"$argv[1]" -- $argv[2..-1]
|
nix run --impure nixpkgs#"$argv[1]" -- $argv[2..-1]
|
||||||
'';
|
'';
|
||||||
shell = ''
|
shell = ''
|
||||||
set args
|
set args
|
||||||
for arg in $argv
|
for arg in $argv
|
||||||
set args $args nixpkgs#$arg
|
set args $args nixpkgs#$arg
|
||||||
end
|
end
|
||||||
nix shell $args
|
nix shell --impure $args
|
||||||
'';
|
'';
|
||||||
fish_user_key_bindings = ''
|
fish_user_key_bindings = ''
|
||||||
bind ctrl-space 'zi; commandline -f repaint'
|
bind ctrl-space 'zi; commandline -f repaint'
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
{
|
{
|
||||||
lib,
|
lib,
|
||||||
pkgs,
|
pkgs,
|
||||||
config,
|
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
with lib; {
|
with lib; {
|
||||||
|
|||||||
@@ -152,6 +152,37 @@ in {
|
|||||||
# hyprlandPlugins.hyprbars
|
# hyprlandPlugins.hyprbars
|
||||||
];
|
];
|
||||||
|
|
||||||
|
submaps = {
|
||||||
|
"resize".settings = {
|
||||||
|
binde = [
|
||||||
|
", right, resizeactive, 20"
|
||||||
|
", left, resizeactive, -20 0"
|
||||||
|
", up, resizeactive, 0 -20"
|
||||||
|
", down, resizeactive, 0 20"
|
||||||
|
", l, resizeactive, 20"
|
||||||
|
", h, resizeactive, -20 0"
|
||||||
|
", k, resizeactive, 0 -20"
|
||||||
|
", j, resizeactive, 0 20"
|
||||||
|
];
|
||||||
|
|
||||||
|
bind = [
|
||||||
|
", q, submap, reset"
|
||||||
|
", escape, submap, reset"
|
||||||
|
|
||||||
|
", catchall, submap, reset" # make any other keypress cancel the submap
|
||||||
|
];
|
||||||
|
};
|
||||||
|
"open, reset".settings = {
|
||||||
|
bind = [
|
||||||
|
", e, exec, emacs"
|
||||||
|
", m, exec, open-messaging"
|
||||||
|
", b, exec, firefox"
|
||||||
|
|
||||||
|
", catchall, submap, reset" # make any other keypress cancel the submap
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
settings = {
|
settings = {
|
||||||
"$mod" = "SUPER";
|
"$mod" = "SUPER";
|
||||||
|
|
||||||
@@ -250,6 +281,7 @@ in {
|
|||||||
"workspace 1, class:firefox"
|
"workspace 1, class:firefox"
|
||||||
"workspace 8, class:Zotero"
|
"workspace 8, class:Zotero"
|
||||||
"workspace 9, class:nheko"
|
"workspace 9, class:nheko"
|
||||||
|
"workspace 9, class:Element"
|
||||||
"workspace 9, class:discord"
|
"workspace 9, class:discord"
|
||||||
"workspace 9, class:org.telegram.desktop"
|
"workspace 9, class:org.telegram.desktop"
|
||||||
"workspace 10, class:thunderbird"
|
"workspace 10, class:thunderbird"
|
||||||
@@ -280,12 +312,18 @@ in {
|
|||||||
bind =
|
bind =
|
||||||
[
|
[
|
||||||
# compositor commands
|
# compositor commands
|
||||||
"$mod, Space, focuswindow, floating"
|
#
|
||||||
"$mod SHIFT, Space, togglefloating,"
|
#
|
||||||
|
"$mod, R, submap, resize"
|
||||||
|
"$mod, O, submap, open"
|
||||||
|
#
|
||||||
|
|
||||||
|
"$mod, SPACE, focuswindow, floating"
|
||||||
|
"$mod SHIFT, SPACE, togglefloating,"
|
||||||
"$mod, F, fullscreen,"
|
"$mod, F, fullscreen,"
|
||||||
"$mod, X, killactive,"
|
"$mod, X, killactive,"
|
||||||
|
|
||||||
"$mod, O, togglesplit," # dwindle
|
"$mod, -, togglesplit," # dwindle
|
||||||
|
|
||||||
# opening applications
|
# opening applications
|
||||||
"$mod, D, exec, wofi --show drun,run"
|
"$mod, D, exec, wofi --show drun,run"
|
||||||
|
|||||||
@@ -1,11 +1,9 @@
|
|||||||
{
|
{
|
||||||
lib,
|
|
||||||
pkgs,
|
pkgs,
|
||||||
inputs,
|
inputs,
|
||||||
...
|
...
|
||||||
}:
|
}: {
|
||||||
{
|
imports = [inputs.nixvim.homeModules.nixvim];
|
||||||
imports = [ inputs.nixvim.homeModules.nixvim ];
|
|
||||||
|
|
||||||
home.sessionVariables = {
|
home.sessionVariables = {
|
||||||
EDITOR = "nvim";
|
EDITOR = "nvim";
|
||||||
@@ -92,10 +90,10 @@
|
|||||||
# Code formatting
|
# Code formatting
|
||||||
conform-nvim = {
|
conform-nvim = {
|
||||||
enable = true;
|
enable = true;
|
||||||
settings.formatters_by_ft = with pkgs; {
|
settings.formatters_by_ft = {
|
||||||
lua = [ "stylua" ];
|
lua = ["stylua"];
|
||||||
python = [ "black" ];
|
python = ["black"];
|
||||||
nix = [ "nixfmt" ];
|
nix = ["nixfmt"];
|
||||||
};
|
};
|
||||||
# extraOptions = {
|
# extraOptions = {
|
||||||
# default_format_opts.lsp_format = "fallback";
|
# default_format_opts.lsp_format = "fallback";
|
||||||
@@ -107,9 +105,9 @@
|
|||||||
enable = true;
|
enable = true;
|
||||||
autoEnableSources = true;
|
autoEnableSources = true;
|
||||||
settings.sources = [
|
settings.sources = [
|
||||||
{ name = "nvim_lsp"; }
|
{name = "nvim_lsp";}
|
||||||
{ name = "path"; }
|
{name = "path";}
|
||||||
{ name = "buffer"; }
|
{name = "buffer";}
|
||||||
];
|
];
|
||||||
settings.mapping = {
|
settings.mapping = {
|
||||||
"<Tab>" = "cmp.mapping(cmp.mapping.select_next_item(), {'i', 's'})";
|
"<Tab>" = "cmp.mapping(cmp.mapping.select_next_item(), {'i', 's'})";
|
||||||
|
|||||||
@@ -19,7 +19,6 @@
|
|||||||
links2 # Tui web-browser
|
links2 # Tui web-browser
|
||||||
lnav # log analyzing tool
|
lnav # log analyzing tool
|
||||||
mc # Tui file browser
|
mc # Tui file browser
|
||||||
# nix-index
|
|
||||||
nmap
|
nmap
|
||||||
p7zip # unzip 7zip archives
|
p7zip # unzip 7zip archives
|
||||||
parted
|
parted
|
||||||
|
|||||||
@@ -30,9 +30,9 @@
|
|||||||
telegram-desktop # telegram
|
telegram-desktop # telegram
|
||||||
# schildichat-desktop # not updated regularly
|
# schildichat-desktop # not updated regularly
|
||||||
nheko
|
nheko
|
||||||
|
element-desktop
|
||||||
evince # Simple pdf reader, good for focusing on document content
|
evince # Simple pdf reader, good for focusing on document content
|
||||||
firefox
|
firefox
|
||||||
vivaldi
|
|
||||||
# geogebra
|
# geogebra
|
||||||
cheese
|
cheese
|
||||||
handbrake
|
handbrake
|
||||||
|
|||||||
@@ -1,4 +1,9 @@
|
|||||||
{pkgs, ...}: {
|
{pkgs, ...}: {
|
||||||
|
programs.opencode = {
|
||||||
|
enable = true;
|
||||||
|
package = pkgs.unstable.opencode;
|
||||||
|
};
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
watchexec # Run command when any file in current dir changes
|
watchexec # Run command when any file in current dir changes
|
||||||
android-tools # adb
|
android-tools # adb
|
||||||
@@ -63,7 +68,7 @@
|
|||||||
|
|
||||||
## My scripts
|
## My scripts
|
||||||
frajul.deploy-to-pianopi
|
frajul.deploy-to-pianopi
|
||||||
frajul.rtklib
|
# frajul.rtklib
|
||||||
|
|
||||||
(pkgs.writeShellScriptBin "matlab-rsp" ''
|
(pkgs.writeShellScriptBin "matlab-rsp" ''
|
||||||
matlab -desktop -sd "/home/julian/git/uwa-channel-model" -softwareopengl
|
matlab -desktop -sd "/home/julian/git/uwa-channel-model" -softwareopengl
|
||||||
|
|||||||
@@ -3,9 +3,6 @@
|
|||||||
inputs,
|
inputs,
|
||||||
...
|
...
|
||||||
}: {
|
}: {
|
||||||
programs.zoxide.enable = true;
|
|
||||||
programs.zoxide.enableFishIntegration = true;
|
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
exiftool
|
exiftool
|
||||||
unar # extract archives
|
unar # extract archives
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
lib,
|
lib,
|
||||||
pkgs,
|
pkgs,
|
||||||
config,
|
config,
|
||||||
|
inputs,
|
||||||
outputs,
|
outputs,
|
||||||
...
|
...
|
||||||
}: {
|
}: {
|
||||||
@@ -9,6 +10,7 @@
|
|||||||
[
|
[
|
||||||
../features/fonts
|
../features/fonts
|
||||||
../features/nix-helper
|
../features/nix-helper
|
||||||
|
inputs.nix-index-database.homeModules.default # nix-locate
|
||||||
]
|
]
|
||||||
++ (builtins.attrValues outputs.homeManagerModules);
|
++ (builtins.attrValues outputs.homeManagerModules);
|
||||||
|
|
||||||
@@ -24,13 +26,28 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# To allow unfree with 'nix run'
|
||||||
|
xdg.configFile."nixpkgs/config.nix".text = ''
|
||||||
|
{ allowUnfree = true; }
|
||||||
|
'';
|
||||||
|
|
||||||
colorscheme.name = "catppuccin-mocha";
|
colorscheme.name = "catppuccin-mocha";
|
||||||
|
|
||||||
# systemd.user.startServices = "sd-switch"; # TODO: what is this
|
# systemd.user.startServices = "sd-switch"; # TODO: what is this
|
||||||
|
|
||||||
|
# Expire old hm generations
|
||||||
|
hm-expire = {
|
||||||
|
enable = true;
|
||||||
|
dates = "weekly";
|
||||||
|
expire = "-30 days";
|
||||||
|
};
|
||||||
|
|
||||||
programs = {
|
programs = {
|
||||||
home-manager.enable = true;
|
home-manager.enable = true;
|
||||||
git.enable = true;
|
git.enable = true;
|
||||||
|
|
||||||
|
nix-index.enable = true; # allows command-not-found
|
||||||
|
nix-index-database.comma.enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
home = {
|
home = {
|
||||||
|
|||||||
@@ -39,6 +39,20 @@
|
|||||||
"ca-derivations"
|
"ca-derivations"
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# Expire old hm generations
|
||||||
|
hm-expire = {
|
||||||
|
enable = true;
|
||||||
|
dates = "weekly";
|
||||||
|
expire = "-30 days";
|
||||||
|
};
|
||||||
|
# Remove unused packets
|
||||||
|
services.nix-gc = {
|
||||||
|
enable = true;
|
||||||
|
automatic = true;
|
||||||
|
frequency = "weekly";
|
||||||
|
persistent = true;
|
||||||
|
};
|
||||||
|
|
||||||
# nix.settings. # warn-dirty = false; # TODO: do I want this
|
# nix.settings. # warn-dirty = false; # TODO: do I want this
|
||||||
#
|
#
|
||||||
# Ensure we can still build when missing-server is not accessible
|
# Ensure we can still build when missing-server is not accessible
|
||||||
|
|||||||
32
homes/julian/quickstart.nix
Normal file
32
homes/julian/quickstart.nix
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
# Quick configuration for setting up basic things on a standalone home-manager device
|
||||||
|
# If you want to adapt it to a specific device, copy this file with the correct hostname
|
||||||
|
{pkgs, ...}: {
|
||||||
|
imports = [
|
||||||
|
./global
|
||||||
|
|
||||||
|
./features/fish
|
||||||
|
./features/direnv
|
||||||
|
./features/neovim
|
||||||
|
./features/yazi
|
||||||
|
./features/emacs
|
||||||
|
./features/nix-helper
|
||||||
|
./features/tmux
|
||||||
|
];
|
||||||
|
|
||||||
|
is-nixos = false;
|
||||||
|
|
||||||
|
home.sessionPath = ["/snap/bin"];
|
||||||
|
|
||||||
|
# Essential packages
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
bat
|
||||||
|
dust
|
||||||
|
fd
|
||||||
|
ripgrep
|
||||||
|
fzf
|
||||||
|
lazygit
|
||||||
|
mc
|
||||||
|
tree
|
||||||
|
wget
|
||||||
|
];
|
||||||
|
}
|
||||||
@@ -21,6 +21,7 @@
|
|||||||
|
|
||||||
../common/optional/podman.nix
|
../common/optional/podman.nix
|
||||||
../common/optional/wireguard.nix
|
../common/optional/wireguard.nix
|
||||||
|
../common/optional/wireshark.nix
|
||||||
../common/optional/flatpak.nix
|
../common/optional/flatpak.nix
|
||||||
|
|
||||||
../common/optional/avahi.nix
|
../common/optional/avahi.nix
|
||||||
|
|||||||
@@ -101,10 +101,17 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
# Ollama used by open-webui as llm backend
|
# Ollama used by open-webui as llm backend
|
||||||
# services.ollama = {
|
services.ollama = {
|
||||||
# enable = true;
|
enable = true;
|
||||||
# # acceleration = "rocm";
|
# acceleration = "rocm";
|
||||||
# };
|
openFirewall = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
services.nextjs-ollama-llm-ui = {
|
||||||
|
enable = true;
|
||||||
|
hostname = "192.168.3.118";
|
||||||
|
port = 3001;
|
||||||
|
};
|
||||||
# services.open-webui = {
|
# services.open-webui = {
|
||||||
# enable = true;
|
# enable = true;
|
||||||
# port = 8080;
|
# port = 8080;
|
||||||
@@ -114,6 +121,7 @@
|
|||||||
|
|
||||||
networking.firewall.allowedTCPPorts = [
|
networking.firewall.allowedTCPPorts = [
|
||||||
80
|
80
|
||||||
|
3001 # ollama-ui
|
||||||
];
|
];
|
||||||
|
|
||||||
services.openssh = {
|
services.openssh = {
|
||||||
|
|||||||
@@ -30,12 +30,9 @@
|
|||||||
networkmanager-openconnect
|
networkmanager-openconnect
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
services.resolved.enable = true;
|
services.resolved.enable = false;
|
||||||
# MDNS Taken by avahi
|
# MDNS Taken by avahi
|
||||||
services.resolved.extraConfig = ''
|
# networking.networkmanager.dns = "none";
|
||||||
MulticastDNS=false
|
|
||||||
'';
|
|
||||||
|
|
||||||
networking.nameservers = lib.mkDefault [
|
networking.nameservers = lib.mkDefault [
|
||||||
"1.1.1.1"
|
"1.1.1.1"
|
||||||
"8.8.8.8"
|
"8.8.8.8"
|
||||||
|
|||||||
@@ -1,9 +1,4 @@
|
|||||||
{
|
{outputs, ...}: {
|
||||||
lib,
|
|
||||||
outputs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
# Apply overlays
|
# Apply overlays
|
||||||
nixpkgs = {
|
nixpkgs = {
|
||||||
# TODO: apply this to hm and nixos without duplicate code
|
# TODO: apply this to hm and nixos without duplicate code
|
||||||
@@ -33,10 +28,12 @@
|
|||||||
automatic = true;
|
automatic = true;
|
||||||
dates = "weekly";
|
dates = "weekly";
|
||||||
options = "--delete-older-than 30d";
|
options = "--delete-older-than 30d";
|
||||||
|
persistent = true;
|
||||||
};
|
};
|
||||||
nix.optimise = {
|
nix.optimise = {
|
||||||
automatic = true;
|
automatic = true;
|
||||||
dates = [ "weekly" ]; # Optional; allows customizing optimisation schedule
|
dates = ["weekly"]; # Optional; allows customizing optimisation schedule
|
||||||
|
persistent = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
programs.nix-ld.enable = true;
|
programs.nix-ld.enable = true;
|
||||||
|
|||||||
9
hosts/common/optional/wireshark.nix
Normal file
9
hosts/common/optional/wireshark.nix
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
programs.wireshark = {
|
||||||
|
enable = true;
|
||||||
|
dumpcap.enable = true;
|
||||||
|
usbmon.enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
users.users.julian.extraGroups = ["wireshark"];
|
||||||
|
}
|
||||||
@@ -1,5 +1,4 @@
|
|||||||
{ pkgs, ... }:
|
{pkgs, ...}: {
|
||||||
{
|
|
||||||
imports = [
|
imports = [
|
||||||
./hardware-configuration.nix
|
./hardware-configuration.nix
|
||||||
|
|
||||||
@@ -34,9 +33,10 @@
|
|||||||
# Not using the drivers leads to way better results
|
# Not using the drivers leads to way better results
|
||||||
# services.xserver.videoDrivers = [ "nvidia" ];
|
# services.xserver.videoDrivers = [ "nvidia" ];
|
||||||
|
|
||||||
networking.networkmanager.insertNameservers = [ "192.168.3.252" ];
|
networking.networkmanager.insertNameservers = ["192.168.3.252"];
|
||||||
|
|
||||||
programs.kdeconnect.enable = true;
|
programs.kdeconnect.enable = true;
|
||||||
|
programs.steam.enable = true;
|
||||||
|
|
||||||
programs.hyprland.enable = true;
|
programs.hyprland.enable = true;
|
||||||
services.desktopManager.plasma6.enable = true;
|
services.desktopManager.plasma6.enable = true;
|
||||||
@@ -44,7 +44,7 @@
|
|||||||
# Enable CUPS to print documents.
|
# Enable CUPS to print documents.
|
||||||
services.printing.enable = true;
|
services.printing.enable = true;
|
||||||
services.printing.browsing = true;
|
services.printing.browsing = true;
|
||||||
services.printing.drivers = with pkgs; [ gutenprint ];
|
services.printing.drivers = with pkgs; [gutenprint];
|
||||||
|
|
||||||
services.libinput.enable = true;
|
services.libinput.enable = true;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,4 +5,5 @@
|
|||||||
colors = import ./colors.nix;
|
colors = import ./colors.nix;
|
||||||
hostname = import ./hostname.nix;
|
hostname = import ./hostname.nix;
|
||||||
non-nixos = import ./non-nixos.nix;
|
non-nixos = import ./non-nixos.nix;
|
||||||
|
hm-expire = import ./hm-expire.nix;
|
||||||
}
|
}
|
||||||
|
|||||||
46
modules/home-manager/hm-expire.nix
Normal file
46
modules/home-manager/hm-expire.nix
Normal file
@@ -0,0 +1,46 @@
|
|||||||
|
{
|
||||||
|
config,
|
||||||
|
lib,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: let
|
||||||
|
cfg = config.hm-expire;
|
||||||
|
in {
|
||||||
|
options.hm-expire = {
|
||||||
|
enable = lib.mkEnableOption "Whether to enable hm-expire";
|
||||||
|
dates = lib.mkOption {
|
||||||
|
type = lib.types.str;
|
||||||
|
default = "weekly";
|
||||||
|
};
|
||||||
|
expire = lib.mkOption {
|
||||||
|
type = lib.types.str;
|
||||||
|
default = "-30 days";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config = lib.mkIf cfg.enable {
|
||||||
|
# This creates a user-level systemd service
|
||||||
|
systemd.user.services.cleanup-home-manager = {
|
||||||
|
Unit = {
|
||||||
|
Description = "Cleanup old Home Manager generations";
|
||||||
|
};
|
||||||
|
Service = {
|
||||||
|
Type = "oneshot";
|
||||||
|
ExecStart = "${pkgs.bash}/bin/bash -c '${pkgs.home-manager}/bin/home-manager expire-generations \"${cfg.expire}\"'";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
systemd.user.timers.cleanup-home-manager = {
|
||||||
|
Unit = {
|
||||||
|
Description = "Weekly cleanup of Home Manager generations";
|
||||||
|
};
|
||||||
|
Timer = {
|
||||||
|
OnCalendar = cfg.dates;
|
||||||
|
Persistent = true;
|
||||||
|
};
|
||||||
|
Install = {
|
||||||
|
WantedBy = ["timers.target"];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -2,19 +2,19 @@
|
|||||||
# For every flake input, aliases 'pkgs.inputs.${flake}' to
|
# For every flake input, aliases 'pkgs.inputs.${flake}' to
|
||||||
# 'inputs.${flake}.packages.${pkgs.system}' or
|
# 'inputs.${flake}.packages.${pkgs.system}' or
|
||||||
# 'inputs.${flake}.legacyPackages.${pkgs.system}'
|
# 'inputs.${flake}.legacyPackages.${pkgs.system}'
|
||||||
flake-inputs = final: _: {
|
# flake-inputs = final: _: {
|
||||||
inputs =
|
# inputs =
|
||||||
builtins.mapAttrs (
|
# builtins.mapAttrs (
|
||||||
_: flake: let
|
# _: flake: let
|
||||||
legacyPackages = (flake.legacyPackages or {}).${final.system} or {};
|
# legacyPackages = (flake.legacyPackages or {}).${final.system} or {};
|
||||||
packages = (flake.packages or {}).${final.system} or {};
|
# packages = (flake.packages or {}).${final.system} or {};
|
||||||
in
|
# in
|
||||||
if legacyPackages != {}
|
# if legacyPackages != {}
|
||||||
then legacyPackages
|
# then legacyPackages
|
||||||
else packages
|
# else packages
|
||||||
)
|
# )
|
||||||
inputs;
|
# inputs;
|
||||||
};
|
# };
|
||||||
|
|
||||||
input-flake-packages = final: prev: {
|
input-flake-packages = final: prev: {
|
||||||
sheet-organizer = inputs.sheet-organizer.packages.${prev.system}.default; # TODO: change sheet-organizer package output
|
sheet-organizer = inputs.sheet-organizer.packages.${prev.system}.default; # TODO: change sheet-organizer package output
|
||||||
@@ -26,11 +26,11 @@
|
|||||||
|
|
||||||
nixpkgs-stable-unstable = final: prev: {
|
nixpkgs-stable-unstable = final: prev: {
|
||||||
unstable = import inputs.nixpkgs-unstable {
|
unstable = import inputs.nixpkgs-unstable {
|
||||||
system = prev.system;
|
system = prev.stdenv.hostPlatform.system;
|
||||||
config.allowUnfree = true;
|
config.allowUnfree = true;
|
||||||
};
|
};
|
||||||
stable = import inputs.nixpkgs {
|
stable = import inputs.nixpkgs {
|
||||||
system = prev.system;
|
system = prev.stdenv.hostPlatform.system;
|
||||||
config.allowUnfree = true;
|
config.allowUnfree = true;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -16,6 +16,6 @@
|
|||||||
typst-languagetool = pkgs.callPackage ./typst-languagetool {};
|
typst-languagetool = pkgs.callPackage ./typst-languagetool {};
|
||||||
pob2-frajul = pkgs.callPackage ./pob2-frajul {};
|
pob2-frajul = pkgs.callPackage ./pob2-frajul {};
|
||||||
|
|
||||||
rpi-ws281x-python = pkgs.callPackage ./rpi-ws281x-python {};
|
# rpi-ws281x-python = pkgs.callPackage ./rpi-ws281x-python {};
|
||||||
piano-led-visualizer = pkgs.callPackage ./piano-led-visualizer {};
|
# piano-led-visualizer = pkgs.callPackage ./piano-led-visualizer {};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
writeShellApplication,
|
writeShellApplication,
|
||||||
nheko,
|
element-desktop,
|
||||||
telegram-desktop,
|
telegram-desktop,
|
||||||
thunderbird,
|
thunderbird,
|
||||||
discord, # TODO: discord not available for aarch64, this leads to flake evaluation for this arch fail.
|
discord, # TODO: discord not available for aarch64, this leads to flake evaluation for this arch fail.
|
||||||
@@ -9,7 +9,7 @@ writeShellApplication {
|
|||||||
name = "open-messaging";
|
name = "open-messaging";
|
||||||
|
|
||||||
runtimeInputs = [
|
runtimeInputs = [
|
||||||
nheko
|
element-desktop
|
||||||
telegram-desktop
|
telegram-desktop
|
||||||
thunderbird
|
thunderbird
|
||||||
discord
|
discord
|
||||||
@@ -18,7 +18,7 @@ writeShellApplication {
|
|||||||
text = ''
|
text = ''
|
||||||
thunderbird &
|
thunderbird &
|
||||||
sleep 0.1
|
sleep 0.1
|
||||||
nheko &
|
element-desktop &
|
||||||
sleep 0.1
|
sleep 0.1
|
||||||
Telegram &
|
Telegram &
|
||||||
sleep 0.1
|
sleep 0.1
|
||||||
|
|||||||
Reference in New Issue
Block a user