mirror of
https://github.com/js0ny/dotfiles.git
synced 2025-12-21 00:33:00 +00:00
Use the repo as flake for private dots
This commit is contained in:
parent
b76d8a0337
commit
410c5ea38f
14 changed files with 110 additions and 11 deletions
|
|
@ -34,6 +34,9 @@ return {
|
|||
{
|
||||
"NeogitOrg/neogit",
|
||||
config = true,
|
||||
dependencies = {
|
||||
"sindrets/diffview.nvim",
|
||||
},
|
||||
cmd = {
|
||||
"Neogit",
|
||||
},
|
||||
|
|
|
|||
21
nixcfgs/flake.lock
generated
21
nixcfgs/flake.lock
generated
|
|
@ -750,6 +750,26 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nix-index-database": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1763870992,
|
||||
"narHash": "sha256-NPyc76Wxmv/vAsXJ8F+/8fXECHYcv2YGSqdiSHp/F/A=",
|
||||
"owner": "nix-community",
|
||||
"repo": "nix-index-database",
|
||||
"rev": "d7423982c7a26586aa237d130b14c8b302c7a367",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "nix-index-database",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixcord": {
|
||||
"inputs": {
|
||||
"flake-compat": "flake-compat",
|
||||
|
|
@ -1105,6 +1125,7 @@
|
|||
"niri-flake": "niri-flake",
|
||||
"nix-darwin": "nix-darwin",
|
||||
"nix-flatpak": "nix-flatpak",
|
||||
"nix-index-database": "nix-index-database",
|
||||
"nixcord": "nixcord",
|
||||
"nixpkgs": "nixpkgs_5",
|
||||
"nixpkgs-stable": "nixpkgs-stable_2",
|
||||
|
|
|
|||
|
|
@ -47,6 +47,10 @@
|
|||
};
|
||||
nixcord.url = "github:kaylorben/nixcord";
|
||||
catppuccin.url = "github:catppuccin/nix";
|
||||
nix-index-database = {
|
||||
url = "github:nix-community/nix-index-database";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
};
|
||||
|
||||
outputs = {
|
||||
|
|
@ -67,6 +71,7 @@
|
|||
zen-browser,
|
||||
nixcord,
|
||||
catppuccin,
|
||||
nix-index-database,
|
||||
...
|
||||
} @ inputs: let
|
||||
overlays = [
|
||||
|
|
@ -137,6 +142,7 @@
|
|||
betterfox-nix.modules.homeManager.betterfox
|
||||
nixcord.homeModules.nixcord
|
||||
catppuccin.homeModules.catppuccin
|
||||
nix-index-database.homeModules.nix-index
|
||||
];
|
||||
};
|
||||
"js0ny@nixvirt" = home-manager.lib.homeManagerConfiguration {
|
||||
|
|
@ -164,5 +170,16 @@
|
|||
];
|
||||
};
|
||||
};
|
||||
# Export nixos modules for private use
|
||||
nixosModules = {
|
||||
server = {...}: {
|
||||
imports = [
|
||||
./modules/nixos
|
||||
./modules/nixos/server.nix
|
||||
./modules/nixos/core/sshd.nix
|
||||
./modules/nixos/programs/zsh.nix
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -20,14 +20,12 @@
|
|||
../../modules/nixos/hardware/udev/basys3.nix
|
||||
|
||||
# Services
|
||||
../../modules/nixos/desktop/wayvnc.nix
|
||||
../../modules/nixos/core/sshd.nix
|
||||
../../modules/nixos/desktop/xremap.nix
|
||||
|
||||
# desktop environment and display manager
|
||||
../../modules/nixos/desktop/dm/ly.nix
|
||||
../../modules/nixos/desktop/de/niri.nix
|
||||
../../modules/nixos/desktop/de/hyprland.nix
|
||||
|
||||
# desktop programs
|
||||
../../modules/nixos/programs/zsh.nix
|
||||
|
|
|
|||
|
|
@ -6,10 +6,8 @@
|
|||
curl
|
||||
git
|
||||
tmux
|
||||
nix-index
|
||||
file
|
||||
unzip
|
||||
zip
|
||||
pkg-config
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
hardware.nvidia = {
|
||||
modesetting.enable = true;
|
||||
powerManagement.enable = true;
|
||||
open = false;
|
||||
open = true;
|
||||
nvidiaSettings = true;
|
||||
package = config.boot.kernelPackages.nvidiaPackages.stable;
|
||||
# powerManagement.finegrained = true;
|
||||
|
|
|
|||
58
nixcfgs/modules/nixos/server.nix
Normal file
58
nixcfgs/modules/nixos/server.nix
Normal file
|
|
@ -0,0 +1,58 @@
|
|||
{
|
||||
lib,
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
with lib; let
|
||||
cfg = config.my.host;
|
||||
in {
|
||||
options.my.host = {
|
||||
role = mkOption {
|
||||
type = types.enum ["server" "desktop" "laptop"];
|
||||
default = "server";
|
||||
description = "The role of this machine, affects default packages and services.";
|
||||
};
|
||||
|
||||
tailscale = {
|
||||
# Syntax sugar: mkOption type=bool
|
||||
enable = mkEnableOption "Tailscale VPN service";
|
||||
|
||||
ip = mkOption {
|
||||
type = types.nullOr types.str;
|
||||
default = null;
|
||||
description = "Tailscale VPN IP address.";
|
||||
};
|
||||
};
|
||||
|
||||
public = {
|
||||
ipv4 = mkOption {
|
||||
type = types.nullOr types.str;
|
||||
default = null;
|
||||
description = "Public IPv4 address.";
|
||||
};
|
||||
};
|
||||
|
||||
sshKey = mkOption {
|
||||
type = types.nullOr types.str;
|
||||
default = null;
|
||||
description = "Host ED25519 public key.";
|
||||
};
|
||||
};
|
||||
|
||||
config = mkMerge [
|
||||
{
|
||||
time.timeZone = "Etc/UTC";
|
||||
|
||||
services.qemuGuest.enable = true;
|
||||
|
||||
nix.settings.trusted-users = ["root" "@wheel"];
|
||||
}
|
||||
|
||||
(mkIf cfg.tailscale.enable {
|
||||
services.tailscale.enable = true;
|
||||
|
||||
networking.firewall.allowedUDPPorts = [config.services.tailscale.port];
|
||||
})
|
||||
];
|
||||
}
|
||||
|
|
@ -19,5 +19,8 @@ in {
|
|||
enable = true;
|
||||
flavor = "mocha";
|
||||
accent = "pink";
|
||||
zed.enable = false;
|
||||
zsh-syntax-highlighting.enable = false;
|
||||
nvim.enable = false; # Defined in lua config
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -18,7 +18,6 @@
|
|||
beancount
|
||||
gnumake
|
||||
chezmoi
|
||||
cmake
|
||||
curlie
|
||||
duf
|
||||
dust
|
||||
|
|
@ -73,4 +72,8 @@
|
|||
then with pkgs; [duti]
|
||||
else with pkgs; [bluetui]
|
||||
);
|
||||
|
||||
programs.nix-index.enable = true;
|
||||
programs.nix-index.symlinkToCacheHome = true;
|
||||
programs.nix-index-database.comma.enable = true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -280,5 +280,5 @@
|
|||
};
|
||||
};
|
||||
};
|
||||
catppuccin.fcitx5.enable = false;
|
||||
catppuccin.fcitx5.enable = true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -91,6 +91,7 @@ in {
|
|||
|
||||
'';
|
||||
};
|
||||
|
||||
programs.firefox = {
|
||||
policies = {
|
||||
ExtensionSettings = [
|
||||
|
|
|
|||
|
|
@ -16,6 +16,7 @@ in {
|
|||
stylua
|
||||
nodejs-slim_24 # for copilot-lua
|
||||
lua-language-server
|
||||
vimPlugins.nvim-treesitter-parsers.diff
|
||||
];
|
||||
};
|
||||
# home.packages = with pkgs; [lua-language-server];
|
||||
|
|
@ -23,6 +24,4 @@ in {
|
|||
programs.bash.shellAliases = nvimAlias;
|
||||
programs.zsh.shellAliases = nvimAlias;
|
||||
programs.nushell.shellAliases = nvimAlias;
|
||||
|
||||
catppuccin.nvim.enable = false; # Defined in lua config
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,7 +9,6 @@ in {
|
|||
zsh-fzf-tab
|
||||
zsh-nix-shell
|
||||
];
|
||||
catppuccin.zsh-syntax-highlighting.enable = false;
|
||||
programs.zsh = {
|
||||
enable = true;
|
||||
autocd = true;
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
{pkgs, ...}: {
|
||||
catppuccin.zed.enable = false;
|
||||
programs.zed-editor = {
|
||||
enable = true;
|
||||
package =
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue