mirror of
https://github.com/js0ny/dotfiles.git
synced 2025-12-21 08:43:00 +00:00
nix: multi-host home-manager
This commit is contained in:
parent
efed8ac3de
commit
4e456383ba
7 changed files with 118 additions and 96 deletions
|
|
@ -22,55 +22,69 @@
|
||||||
nur.url = "github:nix-community/NUR";
|
nur.url = "github:nix-community/NUR";
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = {
|
outputs =
|
||||||
self,
|
{
|
||||||
nixpkgs,
|
self,
|
||||||
nix-flatpak,
|
nixpkgs,
|
||||||
nix-darwin,
|
nix-flatpak,
|
||||||
home-manager,
|
nix-darwin,
|
||||||
plasma-manager,
|
home-manager,
|
||||||
nur,
|
plasma-manager,
|
||||||
...
|
nur,
|
||||||
} @ inputs: let
|
...
|
||||||
overlays = [ nur.overlays.default ];
|
}@inputs:
|
||||||
forSystem = system: import nixpkgs {
|
let
|
||||||
inherit system overlays;
|
overlays = [ nur.overlays.default ];
|
||||||
config.allowUnfree = true;
|
forSystem =
|
||||||
};
|
system:
|
||||||
specialArgs = {inherit inputs;};
|
import nixpkgs {
|
||||||
in {
|
inherit system overlays;
|
||||||
nixosConfigurations.zp = nixpkgs.lib.nixosSystem {
|
config.allowUnfree = true;
|
||||||
system = "x86_64-linux";
|
};
|
||||||
inherit specialArgs;
|
specialArgs = { inherit inputs; };
|
||||||
modules = [
|
in
|
||||||
nix-flatpak.nixosModules.nix-flatpak
|
{
|
||||||
./hosts/zp
|
nixosConfigurations.zp = nixpkgs.lib.nixosSystem {
|
||||||
];
|
system = "x86_64-linux";
|
||||||
};
|
inherit specialArgs;
|
||||||
|
modules = [
|
||||||
|
nix-flatpak.nixosModules.nix-flatpak
|
||||||
|
./hosts/zp
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
nixosConfigurations.zephyrus = nixpkgs.lib.nixosSystem {
|
nixosConfigurations.zephyrus = nixpkgs.lib.nixosSystem {
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
inherit specialArgs;
|
inherit specialArgs;
|
||||||
modules = [
|
modules = [
|
||||||
./hosts/zephyrus
|
./hosts/zephyrus
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
darwinConfigurations."zen" = nix-darwin.lib.darwinSystem {
|
darwinConfigurations."zen" = nix-darwin.lib.darwinSystem {
|
||||||
system = "aarch64-darwin";
|
system = "aarch64-darwin";
|
||||||
inherit specialArgs;
|
inherit specialArgs;
|
||||||
modules = [
|
modules = [
|
||||||
./hosts/zen
|
./hosts/zen
|
||||||
];
|
];
|
||||||
|
};
|
||||||
|
homeConfigurations.js0ny = home-manager.lib.homeManagerConfiguration {
|
||||||
|
pkgs = forSystem "x86_64-linux";
|
||||||
|
extraSpecialArgs = specialArgs;
|
||||||
|
modules = [
|
||||||
|
./users/js0ny
|
||||||
|
plasma-manager.homeModules.plasma-manager
|
||||||
|
nix-flatpak.homeManagerModules.nix-flatpak
|
||||||
|
];
|
||||||
|
};
|
||||||
|
homeConfigurations."js0ny@zephyrus" = home-manager.lib.homeManagerConfiguration {
|
||||||
|
pkgs = forSystem "x86_64-linux";
|
||||||
|
extraSpecialArgs = specialArgs;
|
||||||
|
modules = [
|
||||||
|
./users/js0ny/zephyrus.nix
|
||||||
|
plasma-manager.homeModules.plasma-manager
|
||||||
|
nix-flatpak.homeManagerModules.nix-flatpak
|
||||||
|
];
|
||||||
|
};
|
||||||
};
|
};
|
||||||
homeConfigurations.js0ny = home-manager.lib.homeManagerConfiguration {
|
|
||||||
pkgs = forSystem "x86_64-linux";
|
|
||||||
extraSpecialArgs = specialArgs;
|
|
||||||
modules = [
|
|
||||||
./users/js0ny
|
|
||||||
plasma-manager.homeModules.plasma-manager
|
|
||||||
nix-flatpak.homeManagerModules.nix-flatpak
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
9
nixcfgs/modules/home/gnome-keyrings.nix
Normal file
9
nixcfgs/modules/home/gnome-keyrings.nix
Normal file
|
|
@ -0,0 +1,9 @@
|
||||||
|
{ pkgs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
gcr
|
||||||
|
];
|
||||||
|
|
||||||
|
services.gnome-keyring.enable = true;
|
||||||
|
}
|
||||||
|
|
@ -7,31 +7,10 @@
|
||||||
}:
|
}:
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./packages/cli.nix
|
|
||||||
./packages/gui.nix
|
|
||||||
./packages/flatpak.nix
|
|
||||||
./programs/chromium.nix
|
|
||||||
./programs/gnome.nix
|
|
||||||
./programs/plasma.nix
|
|
||||||
./programs/shell.nix
|
|
||||||
./programs/vscode.nix
|
|
||||||
./programs/git.nix
|
./programs/git.nix
|
||||||
./programs/firefox.nix
|
|
||||||
./programs/distrobox.nix
|
|
||||||
# ./programs/floorp.nix
|
|
||||||
../../modules/home/dev/c.nix
|
|
||||||
../../modules/home/dev/java.nix
|
|
||||||
../../modules/home/dev/nix.nix
|
|
||||||
../../modules/home/dev/python.nix
|
|
||||||
../../modules/home/programs/eza.nix
|
|
||||||
../../modules/home/programs/fzf.nix
|
../../modules/home/programs/fzf.nix
|
||||||
../../modules/home/programs/lsd.nix
|
../../modules/home/programs/lsd.nix
|
||||||
../../modules/home/programs/nvim.nix
|
|
||||||
# ../../modules/home/programs/rime.nix
|
|
||||||
../../modules/home/programs/starship.nix
|
|
||||||
../../modules/home/programs/zed-editor.nix
|
|
||||||
../../modules/home/programs/zoxide.nix
|
../../modules/home/programs/zoxide.nix
|
||||||
# ./flatpak.nix
|
|
||||||
];
|
];
|
||||||
nixpkgs.config.allowUnfree = true;
|
nixpkgs.config.allowUnfree = true;
|
||||||
home.username = "js0ny";
|
home.username = "js0ny";
|
||||||
|
|
@ -39,16 +18,7 @@
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
home-manager
|
home-manager
|
||||||
gcr
|
|
||||||
];
|
];
|
||||||
|
|
||||||
services.gnome-keyring.enable = true;
|
|
||||||
|
|
||||||
xdg.mimeApps = {
|
|
||||||
defaultApplications = {
|
|
||||||
"application/pdf" = "org.kde.okular.desktop";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
home.stateVersion = "25.05";
|
home.stateVersion = "25.05";
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,16 +0,0 @@
|
||||||
{pkgs, ...}: {
|
|
||||||
imports = [
|
|
||||||
./shell.nix
|
|
||||||
./vscodium.nix
|
|
||||||
../../../modules/home/dev/java.nix
|
|
||||||
../../../modules/home/dev/python.nix
|
|
||||||
../../../modules/home/programs/eza.nix
|
|
||||||
../../../modules/home/programs/fzf.nix
|
|
||||||
../../../modules/home/programs/lsd.nix
|
|
||||||
../../../modules/home/programs/nvim.nix
|
|
||||||
../../../modules/home/programs/rime.nix
|
|
||||||
../../../modules/home/programs/starship.nix
|
|
||||||
../../../modules/home/programs/zed-editor.nix
|
|
||||||
../../../modules/home/programs/zoxide.nix
|
|
||||||
];
|
|
||||||
}
|
|
||||||
7
nixcfgs/users/js0ny/programs/mime.nix
Normal file
7
nixcfgs/users/js0ny/programs/mime.nix
Normal file
|
|
@ -0,0 +1,7 @@
|
||||||
|
{
|
||||||
|
xdg.mimeApps = {
|
||||||
|
defaultApplications = {
|
||||||
|
"application/pdf" = "org.kde.okular.desktop";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
40
nixcfgs/users/js0ny/zephyrus.nix
Normal file
40
nixcfgs/users/js0ny/zephyrus.nix
Normal file
|
|
@ -0,0 +1,40 @@
|
||||||
|
# ~/.config/nixcfgs/users/js0ny/default.nix
|
||||||
|
{
|
||||||
|
pkgs,
|
||||||
|
nix-flatpak,
|
||||||
|
plasma-manager,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
{
|
||||||
|
imports = [
|
||||||
|
./default.nix
|
||||||
|
./packages/cli.nix
|
||||||
|
./packages/gui.nix
|
||||||
|
./packages/flatpak.nix
|
||||||
|
./programs/chromium.nix
|
||||||
|
./programs/gnome.nix
|
||||||
|
./programs/plasma.nix
|
||||||
|
./programs/shell.nix
|
||||||
|
./programs/vscode.nix
|
||||||
|
./programs/git.nix
|
||||||
|
./programs/firefox.nix
|
||||||
|
./programs/distrobox.nix
|
||||||
|
./programs/mime.nix
|
||||||
|
# ./programs/floorp.nix
|
||||||
|
../../modules/home/gnome-keyrings.nix
|
||||||
|
../../modules/home/dev/c.nix
|
||||||
|
../../modules/home/dev/java.nix
|
||||||
|
../../modules/home/dev/nix.nix
|
||||||
|
../../modules/home/dev/python.nix
|
||||||
|
../../modules/home/programs/eza.nix
|
||||||
|
../../modules/home/programs/fzf.nix
|
||||||
|
../../modules/home/programs/lsd.nix
|
||||||
|
../../modules/home/programs/nvim.nix
|
||||||
|
../../modules/home/programs/starship.nix
|
||||||
|
../../modules/home/programs/zoxide.nix
|
||||||
|
../../modules/home/programs/zed-editor.nix
|
||||||
|
# ./flatpak.nix
|
||||||
|
];
|
||||||
|
|
||||||
|
home.stateVersion = "25.05";
|
||||||
|
}
|
||||||
|
|
@ -1,2 +0,0 @@
|
||||||
aaa
|
|
||||||
d:
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue