Compare commits
10 commits
77663c229f
...
53a2609204
Author | SHA1 | Date | |
---|---|---|---|
Alexandre Cavalheiro | 53a2609204 | ||
Alexandre Cavalheiro | d735060641 | ||
Alexandre Cavalheiro | 7fa92a1413 | ||
Alexandre Cavalheiro | adbf245fa6 | ||
Alexandre Cavalheiro | 57ac56951f | ||
Alexandre Cavalheiro | 91098d29eb | ||
Alexandre Cavalheiro | eacc272b69 | ||
Alexandre Cavalheiro | e57b4a00ab | ||
Alexandre Cavalheiro | d7cc470fab | ||
Alexandre Cavalheiro | 19f4ff7bf3 |
156
flake.lock
156
flake.lock
|
@ -20,11 +20,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1725199881,
|
||||
"narHash": "sha256-jsmipf/u1GFZE5tBUkr56CHMN6VpUWCAjfLIhvQijU0=",
|
||||
"lastModified": 1725753098,
|
||||
"narHash": "sha256-/NO/h/qD/eJXAQr/fHA4mdDgYsNT9thHQ+oT6KPi2ac=",
|
||||
"owner": "hyprwm",
|
||||
"repo": "aquamarine",
|
||||
"rev": "f8a687dd29ff019657498f1bd14da2fbbf0e604b",
|
||||
"rev": "e4a13203112a036fc7f437d391c7810f3dd5ab52",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -34,22 +34,6 @@
|
|||
}
|
||||
},
|
||||
"flake-compat": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1673956053,
|
||||
"narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=",
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-compat_2": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1696426674,
|
||||
|
@ -65,24 +49,6 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-utils": {
|
||||
"inputs": {
|
||||
"systems": "systems_2"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1681202837,
|
||||
"narHash": "sha256-H+Rh19JDwRtpVPAWp64F+rlEtxUWBAQW28eAi3SRSzg=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "cfacdce06f30d2b68473a46042957675eebb3401",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"home-manager": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
|
@ -90,11 +56,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1725694918,
|
||||
"narHash": "sha256-+HsjshXpqNiJHLaJaK0JnIicJ/a1NquKcfn4YZ3ILgg=",
|
||||
"lastModified": 1726440980,
|
||||
"narHash": "sha256-ChhIrjtdu5d83W+YDRH+Ec5g1MmM0xk6hJnkz15Ot7M=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "aaebdea769a5c10f1c6e50ebdf5924c1a13f0cda",
|
||||
"rev": "a9c9cc6e50f7cbd2d58ccb1cd46a1e06e9e445ff",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -144,11 +110,11 @@
|
|||
"xdph": "xdph"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1725752806,
|
||||
"narHash": "sha256-UwmsA7O9Wofu6YWldyR8NDv1bzxNICIg85/uOrVq69Y=",
|
||||
"lastModified": 1726430622,
|
||||
"narHash": "sha256-50vt1snpVwS5lqvvH4p6DHiEWspJUZuJ1kYy1DKtrfM=",
|
||||
"ref": "refs/heads/main",
|
||||
"rev": "312411fc7073143a8bf1fc3ba23ef403b7d15eee",
|
||||
"revCount": 5195,
|
||||
"rev": "9e356562446f44c471ae38a80506a9df039305d6",
|
||||
"revCount": 5224,
|
||||
"submodules": true,
|
||||
"type": "git",
|
||||
"url": "https://github.com/hyprwm/Hyprland"
|
||||
|
@ -202,11 +168,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1725188252,
|
||||
"narHash": "sha256-yBH8c4GDaEAtBrh+BqIlrx5vp6gG/Gu8fQQK63KAQgs=",
|
||||
"lastModified": 1725997860,
|
||||
"narHash": "sha256-d/rZ/fHR5l1n7PeyLw0StWMNLXVU9c4HFyfskw568so=",
|
||||
"owner": "hyprwm",
|
||||
"repo": "hyprlang",
|
||||
"rev": "c12ab785ce1982f82594aff03b3104c598186ddd",
|
||||
"rev": "dfeb5811dd6485490cce18d6cc1e38a055eea876",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -265,48 +231,13 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"myneovim": {
|
||||
"locked": {
|
||||
"lastModified": 1725776584,
|
||||
"narHash": "sha256-OjyGCf08yEIHprN2QIpCL2+dee6xyQJvemhNEFAytL8=",
|
||||
"ref": "refs/heads/main",
|
||||
"rev": "43f0e5f1b318cf5f6dee6b26398ffd19d5153c8a",
|
||||
"revCount": 24,
|
||||
"type": "git",
|
||||
"url": "https://git.thewizard.link/wizardlink/neovim"
|
||||
},
|
||||
"original": {
|
||||
"type": "git",
|
||||
"url": "https://git.thewizard.link/wizardlink/neovim"
|
||||
}
|
||||
},
|
||||
"nix-minecraft": {
|
||||
"inputs": {
|
||||
"flake-compat": "flake-compat",
|
||||
"flake-utils": "flake-utils",
|
||||
"nixpkgs": "nixpkgs_2"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1725760053,
|
||||
"narHash": "sha256-DS9B2q9nSPh07CgNRQwCybRWhgf1QV5KDRU/umVcuUc=",
|
||||
"owner": "Infinidoge",
|
||||
"repo": "nix-minecraft",
|
||||
"rev": "065be4d743d9a0caa83196b6c570e70aec042944",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "Infinidoge",
|
||||
"repo": "nix-minecraft",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1725103162,
|
||||
"narHash": "sha256-Ym04C5+qovuQDYL/rKWSR+WESseQBbNAe5DsXNx5trY=",
|
||||
"lastModified": 1725983898,
|
||||
"narHash": "sha256-4b3A9zPpxAxLnkF9MawJNHDtOOl6ruL0r6Og1TEDGCE=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "12228ff1752d7b7624a54e9c1af4b222b3c1073b",
|
||||
"rev": "1355a0cbfeac61d785b7183c0caaec1f97361b43",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -318,27 +249,11 @@
|
|||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1715266358,
|
||||
"narHash": "sha256-doPgfj+7FFe9rfzWo1siAV2mVCasW+Bh8I1cToAXEE4=",
|
||||
"lastModified": 1726243404,
|
||||
"narHash": "sha256-sjiGsMh+1cWXb53Tecsm4skyFNag33GPbVgCdfj3n9I=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "f1010e0469db743d14519a1efd37e23f8513d714",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nixos",
|
||||
"ref": "nixos-unstable",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs_3": {
|
||||
"locked": {
|
||||
"lastModified": 1725634671,
|
||||
"narHash": "sha256-v3rIhsJBOMLR8e/RNWxr828tB+WywYIoajrZKFM+0Gg=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "574d1eac1c200690e27b8eb4e24887f8df7ac27c",
|
||||
"rev": "345c263f2f53a3710abe117f28a5cb86d0ba4059",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -352,25 +267,23 @@
|
|||
"inputs": {
|
||||
"home-manager": "home-manager",
|
||||
"hyprland": "hyprland",
|
||||
"myneovim": "myneovim",
|
||||
"nix-minecraft": "nix-minecraft",
|
||||
"nixpkgs": "nixpkgs_3",
|
||||
"nixpkgs": "nixpkgs_2",
|
||||
"spicetify-nix": "spicetify-nix"
|
||||
}
|
||||
},
|
||||
"spicetify-nix": {
|
||||
"inputs": {
|
||||
"flake-compat": "flake-compat_2",
|
||||
"flake-compat": "flake-compat",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1725768938,
|
||||
"narHash": "sha256-Lmd6L/hF0hjid0ThYH8vYdyjkor95NvwzptlexdFmto=",
|
||||
"lastModified": 1726460241,
|
||||
"narHash": "sha256-wslbKgh6ZEqHzZJj1eHGRENZQ4r1C4LmAvaBKvbiGzg=",
|
||||
"owner": "Gerg-L",
|
||||
"repo": "spicetify-nix",
|
||||
"rev": "f972e25c903479e175b1730292536de219e9b0c3",
|
||||
"rev": "fe1722602352cba0448f3961df90b5d1f55d5675",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -394,21 +307,6 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"systems_2": {
|
||||
"locked": {
|
||||
"lastModified": 1681028828,
|
||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"xdph": {
|
||||
"inputs": {
|
||||
"hyprland-protocols": "hyprland-protocols",
|
||||
|
@ -426,11 +324,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1725203932,
|
||||
"narHash": "sha256-VLULC/OnI+6R9KEP2OIGk+uLJJsfRlaLouZ5gyFd2+Y=",
|
||||
"lastModified": 1726046979,
|
||||
"narHash": "sha256-6SEsjurq9cdTkITA6d49ncAJe4O/8CgRG5/F//s6Xh8=",
|
||||
"owner": "hyprwm",
|
||||
"repo": "xdg-desktop-portal-hyprland",
|
||||
"rev": "2425e8f541525fa7409d9f26a8ffaf92a3767251",
|
||||
"rev": "e695669fd8e1d1be9eaae40f35e00f8bd8b64c18",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
41
flake.nix
41
flake.nix
|
@ -15,8 +15,6 @@
|
|||
};
|
||||
|
||||
hyprland.url = "git+https://github.com/hyprwm/Hyprland?submodules=1";
|
||||
|
||||
myneovim.url = "git+https://git.thewizard.link/wizardlink/neovim";
|
||||
};
|
||||
|
||||
outputs =
|
||||
|
@ -26,20 +24,45 @@
|
|||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
in
|
||||
{
|
||||
nixosConfigurations.wizdesk =
|
||||
let
|
||||
specialArgs = inputs;
|
||||
modules = [ ./nixos.nix ];
|
||||
in
|
||||
nixpkgs.lib.nixosSystem { inherit system specialArgs modules; };
|
||||
nixosConfigurations = {
|
||||
wizdesk =
|
||||
let
|
||||
specialArgs = inputs;
|
||||
modules = [
|
||||
./modules/nixos
|
||||
./specific/wizdesk/nixos.nix
|
||||
];
|
||||
in
|
||||
nixpkgs.lib.nixosSystem { inherit system specialArgs modules; };
|
||||
|
||||
wizlap =
|
||||
let
|
||||
specialArgs = inputs;
|
||||
modules = [
|
||||
./modules/nixos
|
||||
./specific/wizlap/nixos.nix
|
||||
];
|
||||
in
|
||||
nixpkgs.lib.nixosSystem { inherit system specialArgs modules; };
|
||||
};
|
||||
|
||||
homeConfigurations.wizardlink = home-manager.lib.homeManagerConfiguration {
|
||||
inherit pkgs;
|
||||
|
||||
extraSpecialArgs = inputs;
|
||||
modules = [ ./home-manager.nix ];
|
||||
modules = [ ./specific/home-manager.nix ];
|
||||
};
|
||||
|
||||
formatter."${system}" = pkgs.nixfmt-rfc-style;
|
||||
|
||||
homeManagerModules = {
|
||||
emacs = import ./modules/home-manager/programs/emacs;
|
||||
hyprlandConfig = import ./modules/home-manager/programs/hyprland;
|
||||
neovim = import ./modules/home-manager/programs/neovim;
|
||||
};
|
||||
|
||||
nixosModules = {
|
||||
default = import ./modules/nixos;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
323
home-manager.nix
323
home-manager.nix
|
@ -1,323 +0,0 @@
|
|||
{ pkgs, myneovim, ... }:
|
||||
|
||||
{
|
||||
#
|
||||
## HOME CONFIGURATION #
|
||||
#
|
||||
|
||||
# Import configurations for better modularity.
|
||||
imports = [
|
||||
./programs/alacritty.nix
|
||||
./programs/emacs
|
||||
./programs/fish
|
||||
./programs/git.nix
|
||||
./programs/hyprland
|
||||
./programs/mangohud.nix
|
||||
./programs/obs-studio.nix
|
||||
./programs/rofi
|
||||
./programs/spotify
|
||||
./programs/tmux
|
||||
./programs/waybar.nix
|
||||
./services/openttd.nix
|
||||
myneovim.homeManagerModules.default
|
||||
];
|
||||
|
||||
# Home Manager needs a bit of information about you and the paths it should
|
||||
# manage.
|
||||
home.username = "wizardlink";
|
||||
home.homeDirectory = "/home/wizardlink";
|
||||
|
||||
# This value determines the Home Manager release that your configuration is
|
||||
# compatible with. This helps avoid breakage when a new Home Manager release
|
||||
# introduces backwards incompatible changes.
|
||||
#
|
||||
# You should not change this value, even if you update Home Manager. If you do
|
||||
# want to update the value, then make sure to first check the Home Manager
|
||||
# release notes.
|
||||
home.stateVersion = "23.05"; # Please read the comment before changing.
|
||||
|
||||
# You can also manage environment variables but you will have to manually
|
||||
# source
|
||||
#
|
||||
# ~/.nix-profile/etc/profile.d/hm-session-vars.sh
|
||||
#
|
||||
# or
|
||||
#
|
||||
# /etc/profiles/per-user/wizardlink/etc/profile.d/hm-session-vars.sh
|
||||
# if you don't want to manage your shell through Home Manager.
|
||||
home.sessionVariables = {
|
||||
EDITOR = "nvim";
|
||||
|
||||
NIXOS_OZONE_WL = "1";
|
||||
QT_QPA_PLATFORM = "wayland";
|
||||
};
|
||||
|
||||
##
|
||||
## PACKAGES #
|
||||
##
|
||||
|
||||
# Let Home Manager install and manage itself.
|
||||
programs.home-manager.enable = true;
|
||||
|
||||
# Allow unfree packages
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
||||
# The home.packages option allows you to install Nix packages into your
|
||||
# environment.
|
||||
home.packages = with pkgs; [
|
||||
# # You can also create simple shell scripts directly inside your
|
||||
# # configuration. For example, this adds a command 'my-hello' to your
|
||||
# # environment:
|
||||
# (pkgs.writeShellScriptBin "my-hello" ''
|
||||
# echo "Hello, ${config.home.username}!"
|
||||
# '')
|
||||
|
||||
## Tools
|
||||
# Utilities
|
||||
brightnessctl
|
||||
fastfetch
|
||||
firefox
|
||||
pavucontrol
|
||||
protonvpn-gui
|
||||
qbittorrent
|
||||
qdirstat
|
||||
speedcrunch
|
||||
vlc
|
||||
yt-dlp
|
||||
zathura
|
||||
|
||||
# Personal utilities
|
||||
anki
|
||||
ledger
|
||||
vesktop
|
||||
|
||||
# Editing
|
||||
libreoffice
|
||||
|
||||
# Creative work
|
||||
blender
|
||||
krita
|
||||
lmms
|
||||
orca-slicer
|
||||
shotcut
|
||||
vcv-rack
|
||||
|
||||
## Entertainment
|
||||
jellyfin-media-player
|
||||
|
||||
# Gaming
|
||||
protontricks
|
||||
wineWowPackages.stagingFull
|
||||
winetricks
|
||||
|
||||
# Games
|
||||
openttd
|
||||
prismlauncher
|
||||
shattered-pixel-dungeon
|
||||
xonotic
|
||||
|
||||
## Libraries
|
||||
libsForQt5.kdegraphics-thumbnailers
|
||||
libsForQt5.kio-extras
|
||||
rnnoise-plugin
|
||||
xwaylandvideobridge
|
||||
|
||||
## Development
|
||||
beekeeper-studio
|
||||
lazygit
|
||||
|
||||
## Desktop environment
|
||||
cliphist
|
||||
grim
|
||||
libsForQt5.ark
|
||||
mako
|
||||
slurp
|
||||
swww
|
||||
|
||||
# Mail client
|
||||
thunderbird
|
||||
|
||||
## Theming
|
||||
(nerdfonts.override {
|
||||
fonts = [
|
||||
"FantasqueSansMono"
|
||||
"NerdFontsSymbolsOnly"
|
||||
];
|
||||
})
|
||||
libsForQt5.qtstyleplugin-kvantum
|
||||
libsForQt5.qtwayland
|
||||
qt6Packages.qtstyleplugin-kvantum
|
||||
qt6Packages.qtwayland
|
||||
|
||||
# Create an FHS environment using the command `fhs`, enabling the execution of non-NixOS packages in NixOS!
|
||||
(
|
||||
let
|
||||
base = appimageTools.defaultFhsEnvArgs;
|
||||
in
|
||||
buildFHSUserEnv (
|
||||
base
|
||||
// {
|
||||
name = "fhs";
|
||||
targetPkgs =
|
||||
pkgs:
|
||||
(
|
||||
# pkgs.buildFHSUserEnv provides only a minimal FHS environment,
|
||||
# lacking many basic packages needed by most software.
|
||||
# Therefore, we need to add them manually.
|
||||
#
|
||||
# pkgs.appimageTools provides basic packages required by most software.
|
||||
(base.targetPkgs pkgs) ++ (with pkgs; [ nodejs ])
|
||||
);
|
||||
profile = "export FHS=1";
|
||||
runScript = "bash";
|
||||
extraOutputsToInstall = [ "dev" ];
|
||||
}
|
||||
)
|
||||
)
|
||||
];
|
||||
|
||||
#
|
||||
## DOTFILES #
|
||||
#
|
||||
|
||||
# Home Manager is pretty good at managing dotfiles. The primary way to manage
|
||||
# plain files is through 'home.file'.
|
||||
home.file = {
|
||||
# Cattpuccin theme for fish shell.
|
||||
".config/fish/themes/Catppuccin-Frappe.theme".source = ./programs/fish/Catppuccin-Frappe.theme;
|
||||
|
||||
# Configuration for gamemode, for running games with optimizations.
|
||||
".config/gamemode.ini".source = ./programs/gamemode.ini;
|
||||
|
||||
# Configuration for mako, a notification daemon.
|
||||
".config/mako".source = ./programs/mako;
|
||||
|
||||
## Kvantum's theme configuration.
|
||||
".config/Kvantum/Catppuccin-Frappe-Lavender" = {
|
||||
source = "${
|
||||
pkgs.catppuccin-kvantum.override {
|
||||
accent = "Lavender";
|
||||
variant = "Frappe";
|
||||
}
|
||||
}/share/Kvantum/Catppuccin-Frappe-Lavender";
|
||||
};
|
||||
|
||||
".config/Kvantum/kvantum.kvconfig".text = ''
|
||||
[General]
|
||||
theme=Catppuccin-Frappe-Lavender
|
||||
'';
|
||||
##
|
||||
|
||||
## Themeing configuration for qt5 and qt6
|
||||
".config/qt5ct/colors".source = ./theming/qt5ct;
|
||||
|
||||
".config/qt6ct/colors".source = ./theming/qt5ct; # We use the qt5ct because it's the SAME spec
|
||||
##
|
||||
|
||||
# Configure pipewire for microphone noise supression.
|
||||
".config/pipewire/pipewire.conf.d/99-input-denoising.conf".text = ''
|
||||
context.modules = [
|
||||
{ name = libpipewire-module-filter-chain
|
||||
args = {
|
||||
node.description = "Noise Canceling source"
|
||||
media.name = "Noise Canceling source"
|
||||
filter.graph = {
|
||||
nodes = [
|
||||
{
|
||||
type = ladspa
|
||||
name = rnnoise
|
||||
plugin = ${pkgs.rnnoise-plugin}/lib/ladspa/librnnoise_ladspa.so
|
||||
label = noise_suppressor_mono
|
||||
control = {
|
||||
"VAD Threshold (%)" = 60.0
|
||||
"VAD Grace Period (ms)" = 175
|
||||
"Retroactive VAD Grace (ms)" = 50
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
capture.props = {
|
||||
node.name = "capture.rnnoise_source"
|
||||
node.passive = true
|
||||
audio.rate = 48000
|
||||
}
|
||||
playback.props = {
|
||||
node.name = "rnnoise_source"
|
||||
media.class = Audio/Source
|
||||
audio.rate = 48000
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
'';
|
||||
|
||||
# Configure DXVK
|
||||
".config/dxvk.conf".text = ''
|
||||
dxgi.tearFree = True
|
||||
dxvk.enableGraphicsPipelineLibrary = True
|
||||
|
||||
dxvk.enableAsync = True
|
||||
'';
|
||||
|
||||
".local/share/SpeedCrunch/color-schemes/catppuccin-frappe.json" = {
|
||||
recursive = true;
|
||||
source = builtins.fetchurl {
|
||||
url = "https://raw.githubusercontent.com/catppuccin/speedcrunch/34f2b382de0188d2fd85f59a8a366f313fc30a71/themes/catppuccin-frappe.json";
|
||||
sha256 = "sha256:0imx5a53p3ls5kddplgr7mbpbidrmzl9qiwpv7r8jjmsf8yxs0i4";
|
||||
};
|
||||
};
|
||||
|
||||
# My utility scripts
|
||||
".local/share/scripts" = {
|
||||
source = ./scripts;
|
||||
recursive = true;
|
||||
};
|
||||
};
|
||||
|
||||
#
|
||||
## THEMING #
|
||||
#
|
||||
home.pointerCursor = {
|
||||
package = pkgs.catppuccin-cursors.frappeLavender;
|
||||
name = "catppuccin-frappe-lavender-cursors";
|
||||
|
||||
gtk.enable = true;
|
||||
x11.enable = true;
|
||||
};
|
||||
|
||||
# Configure GTK.
|
||||
gtk = {
|
||||
enable = true;
|
||||
|
||||
gtk3.extraConfig = {
|
||||
gtk-application-prefer-dark-theme = true;
|
||||
};
|
||||
|
||||
gtk4.extraConfig = {
|
||||
gtk-application-prefer-dark-theme = true;
|
||||
};
|
||||
|
||||
iconTheme = {
|
||||
name = "Papirus-Dark";
|
||||
package = pkgs.papirus-icon-theme.override { color = "violet"; };
|
||||
};
|
||||
};
|
||||
|
||||
# Configure QT
|
||||
qt = {
|
||||
enable = true;
|
||||
platformTheme.name = "qtct";
|
||||
};
|
||||
|
||||
# Configure XDG
|
||||
xdg.mimeApps.defaultApplications = {
|
||||
"inode/directory" = [ "thunar.desktop" ];
|
||||
"text/html" = [ "firefox.desktop" ];
|
||||
"video/mp4" = [ "vlc.desktop" ];
|
||||
"video/x-matroska" = [ "vlc.desktop" ];
|
||||
"x-scheme-handler/about" = [ "firefox.desktop" ];
|
||||
"x-scheme-handler/http" = [ "firefox.desktop" ];
|
||||
"x-scheme-handler/https" = [ "firefox.desktop" ];
|
||||
"x-scheme-handler/unknown" = [ "firefox.desktop" ];
|
||||
};
|
||||
}
|
79
modules/home-manager/common.nix
Normal file
79
modules/home-manager/common.nix
Normal file
|
@ -0,0 +1,79 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
home.sessionVariables = {
|
||||
NIXOS_OZONE_WL = "1";
|
||||
QT_QPA_PLATFORM = "wayland";
|
||||
};
|
||||
|
||||
home.file = {
|
||||
# Configuration for gamemode, for running games with optimizations.
|
||||
".config/gamemode.ini".source = ./programs/gamemode.ini;
|
||||
|
||||
# Configuration for mako, a notification daemon.
|
||||
".config/mako".source = ./programs/mako;
|
||||
|
||||
# Configure pipewire for microphone noise supression.
|
||||
".config/pipewire/pipewire.conf.d/99-input-denoising.conf".text = ''
|
||||
context.modules = [
|
||||
{ name = libpipewire-module-filter-chain
|
||||
args = {
|
||||
node.description = "Noise Canceling source"
|
||||
media.name = "Noise Canceling source"
|
||||
filter.graph = {
|
||||
nodes = [
|
||||
{
|
||||
type = ladspa
|
||||
name = rnnoise
|
||||
plugin = ${pkgs.rnnoise-plugin}/lib/ladspa/librnnoise_ladspa.so
|
||||
label = noise_suppressor_mono
|
||||
control = {
|
||||
"VAD Threshold (%)" = 60.0
|
||||
"VAD Grace Period (ms)" = 175
|
||||
"Retroactive VAD Grace (ms)" = 50
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
capture.props = {
|
||||
node.name = "capture.rnnoise_source"
|
||||
node.passive = true
|
||||
audio.rate = 48000
|
||||
}
|
||||
playback.props = {
|
||||
node.name = "rnnoise_source"
|
||||
media.class = Audio/Source
|
||||
audio.rate = 48000
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
'';
|
||||
|
||||
# Configure DXVK
|
||||
".config/dxvk.conf".text = ''
|
||||
dxgi.tearFree = True
|
||||
dxvk.enableGraphicsPipelineLibrary = True
|
||||
|
||||
dxvk.enableAsync = True
|
||||
'';
|
||||
|
||||
# My utility scripts
|
||||
".local/share/scripts" = {
|
||||
source = ./scripts;
|
||||
recursive = true;
|
||||
};
|
||||
};
|
||||
|
||||
# Configure XDG
|
||||
xdg.mimeApps.defaultApplications = {
|
||||
"inode/directory" = [ "thunar.desktop" ];
|
||||
"text/html" = [ "firefox.desktop" ];
|
||||
"video/mp4" = [ "vlc.desktop" ];
|
||||
"video/x-matroska" = [ "vlc.desktop" ];
|
||||
"x-scheme-handler/about" = [ "firefox.desktop" ];
|
||||
"x-scheme-handler/http" = [ "firefox.desktop" ];
|
||||
"x-scheme-handler/https" = [ "firefox.desktop" ];
|
||||
"x-scheme-handler/unknown" = [ "firefox.desktop" ];
|
||||
};
|
||||
}
|
9
modules/home-manager/default.nix
Normal file
9
modules/home-manager/default.nix
Normal file
|
@ -0,0 +1,9 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./common.nix
|
||||
./packages.nix
|
||||
./theming.nix
|
||||
];
|
||||
}
|
127
modules/home-manager/packages.nix
Normal file
127
modules/home-manager/packages.nix
Normal file
|
@ -0,0 +1,127 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./programs
|
||||
];
|
||||
|
||||
# Let Home Manager install and manage itself.
|
||||
programs.home-manager.enable = true;
|
||||
|
||||
# Allow unfree packages
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
||||
# The home.packages option allows you to install Nix packages into your
|
||||
# environment.
|
||||
home.packages = with pkgs; [
|
||||
# # You can also create simple shell scripts directly inside your
|
||||
# # configuration. For example, this adds a command 'my-hello' to your
|
||||
# # environment:
|
||||
# (pkgs.writeShellScriptBin "my-hello" ''
|
||||
# echo "Hello, ${config.home.username}!"
|
||||
# '')
|
||||
|
||||
## Tools
|
||||
# Utilities
|
||||
brightnessctl
|
||||
fastfetch
|
||||
firefox
|
||||
pavucontrol
|
||||
protonvpn-gui
|
||||
qbittorrent
|
||||
qdirstat
|
||||
speedcrunch
|
||||
vlc
|
||||
yt-dlp
|
||||
zathura
|
||||
|
||||
# Personal utilities
|
||||
anki
|
||||
ledger
|
||||
vesktop
|
||||
|
||||
# Editing
|
||||
libreoffice
|
||||
|
||||
# Creative work
|
||||
blender
|
||||
krita
|
||||
lmms
|
||||
orca-slicer
|
||||
shotcut
|
||||
vcv-rack
|
||||
|
||||
## Entertainment
|
||||
jellyfin-media-player
|
||||
|
||||
# Gaming
|
||||
protontricks
|
||||
wineWowPackages.unstableFull
|
||||
winetricks
|
||||
|
||||
# Games
|
||||
openttd
|
||||
prismlauncher
|
||||
shattered-pixel-dungeon
|
||||
xonotic
|
||||
|
||||
## Libraries
|
||||
libsForQt5.kdegraphics-thumbnailers
|
||||
libsForQt5.kio-extras
|
||||
rnnoise-plugin
|
||||
xwaylandvideobridge
|
||||
|
||||
## Development
|
||||
beekeeper-studio
|
||||
lazygit
|
||||
|
||||
## Desktop environment
|
||||
cliphist
|
||||
grim
|
||||
libsForQt5.ark
|
||||
mako
|
||||
slurp
|
||||
swww
|
||||
|
||||
# Mail client
|
||||
thunderbird
|
||||
|
||||
## Theming
|
||||
(nerdfonts.override {
|
||||
fonts = [
|
||||
"FantasqueSansMono"
|
||||
"NerdFontsSymbolsOnly"
|
||||
];
|
||||
})
|
||||
libsForQt5.qtstyleplugin-kvantum
|
||||
libsForQt5.qtwayland
|
||||
qt6Packages.qtstyleplugin-kvantum
|
||||
qt6Packages.qtwayland
|
||||
|
||||
# Create an FHS environment using the command `fhs`, enabling the execution of non-NixOS packages in NixOS!
|
||||
(
|
||||
let
|
||||
base = appimageTools.defaultFhsEnvArgs;
|
||||
in
|
||||
buildFHSUserEnv (
|
||||
base
|
||||
// {
|
||||
name = "fhs";
|
||||
targetPkgs =
|
||||
pkgs:
|
||||
(
|
||||
# pkgs.buildFHSUserEnv provides only a minimal FHS environment,
|
||||
# lacking many basic packages needed by most software.
|
||||
# Therefore, we need to add them manually.
|
||||
#
|
||||
# pkgs.appimageTools provides basic packages required by most software.
|
||||
(base.targetPkgs pkgs) ++ (with pkgs; [ nodejs ])
|
||||
);
|
||||
profile = "export FHS=1";
|
||||
runScript = "bash";
|
||||
extraOutputsToInstall = [ "dev" ];
|
||||
}
|
||||
)
|
||||
)
|
||||
];
|
||||
}
|
19
modules/home-manager/programs/default.nix
Normal file
19
modules/home-manager/programs/default.nix
Normal file
|
@ -0,0 +1,19 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./alacritty.nix
|
||||
./direnv
|
||||
./emacs
|
||||
./fish
|
||||
./git.nix
|
||||
./hyprland
|
||||
./mangohud.nix
|
||||
./obs-studio.nix
|
||||
./rofi
|
||||
./spotify
|
||||
./tmux
|
||||
./waybar.nix
|
||||
./neovim
|
||||
];
|
||||
}
|
19
modules/home-manager/programs/direnv/default.nix
Normal file
19
modules/home-manager/programs/direnv/default.nix
Normal file
|
@ -0,0 +1,19 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
programs.direnv = {
|
||||
enable = true;
|
||||
nix-direnv.enable = true;
|
||||
|
||||
config = {
|
||||
whitelist = {
|
||||
prefix = [
|
||||
"/mnt/internal/personal/projects"
|
||||
"/mnt/internal/repos"
|
||||
"/mnt/internal/shared/projects"
|
||||
"/mnt/internal/shared/work"
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
73
modules/home-manager/programs/neovim/README.md
Normal file
73
modules/home-manager/programs/neovim/README.md
Normal file
|
@ -0,0 +1,73 @@
|
|||
# My [Home Manager] module for neovim configuration
|
||||
|
||||
This is my personal configuration for _[neovim]_ using [Nix](https://nixos.org/), so this will not work outside of it - though it can be made to be.
|
||||
|
||||
In this case, I am outputting a [Home Manager] module to be used directly in your configuration, it currently barely has
|
||||
any
|
||||
options and is opinionated due to it being my personal configuration for daily use... But I plan to slowly add options
|
||||
to make it usable by other people.
|
||||
|
||||
## Installing
|
||||
|
||||
First you add this repository as a flake input:
|
||||
|
||||
```nix
|
||||
{
|
||||
inputs = {
|
||||
home-manager = {
|
||||
url = "github:nix-community/home-manager";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
wizardlink-neovim.url = "git+https://git.thewizard.link/wizardlink/neovim";
|
||||
};
|
||||
|
||||
outputs = { home-manager, ... }@inputs: {
|
||||
homeConfigurations.YOURHOSTNAME = home-manager.lib.homeManagerConfiguration {
|
||||
# ...
|
||||
extraSPecialArgs = inputs;
|
||||
};
|
||||
};
|
||||
}
|
||||
```
|
||||
|
||||
Then in your [Home Manager] configuration you can just import it:
|
||||
|
||||
```nix
|
||||
{ wizardlink-neovim }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
wizardlink-neovim.homeManagerModules.default
|
||||
];
|
||||
}
|
||||
```
|
||||
|
||||
## Configuring
|
||||
|
||||
### [nixd](https://github.com/nix-community/nixd/)
|
||||
|
||||
```nix
|
||||
programs.neovim.flake = {
|
||||
hostname = "nixos"; # Your hostname used to build your system.
|
||||
location = "git+file:///home/wizardlink/.system"; # Where you store your flake.
|
||||
};
|
||||
```
|
||||
|
||||
## My neovim failed because of package X not existing
|
||||
|
||||
My configuration is based off of `nixos-unstable` so sometimes your package may not exist or have a different name, I
|
||||
apologise for that but I don't plan on maintaining backwards compatibility. :(
|
||||
|
||||
## How it looks
|
||||
|
||||
Here's some screenshots of how it currently looks like:
|
||||
|
||||
![image](./docs/example_1.png)
|
||||
![image](./docs/example_2.png)
|
||||
![image](./docs/example_3.png)
|
||||
|
||||
The theme I'm using is [catppuccin](https://github.com/catppuccin) in case you're curious.
|
||||
|
||||
[neovim]: https://neovim.io/
|
||||
[Home Manager]: https://github.com/nix-community/home-manager
|
284
modules/home-manager/programs/neovim/default.nix
Normal file
284
modules/home-manager/programs/neovim/default.nix
Normal file
|
@ -0,0 +1,284 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
inherit (lib) types mkOption;
|
||||
ollamaPackage =
|
||||
if config.programs.neovim.ollama.type == "amd" then pkgs.ollama-rocm else pkgs.ollama-cuda;
|
||||
in
|
||||
{
|
||||
options.programs.neovim = {
|
||||
flake = {
|
||||
hostname = mkOption {
|
||||
default = "wizdesk";
|
||||
description = "Your NixOS hostname, needed for nixd lsp.";
|
||||
example = "nixos";
|
||||
type = types.str;
|
||||
};
|
||||
|
||||
location = mkOption {
|
||||
default = "git+file:///home/wizardlink/.system";
|
||||
description = "Path to your flake location, prepend 'file:///' to it and 'git+' before that if using git.";
|
||||
example = "git+file:///home/wizardlink/.system";
|
||||
type = types.str;
|
||||
};
|
||||
};
|
||||
|
||||
ollama.type = mkOption {
|
||||
default = "amd";
|
||||
description = "The type of ollama package to install, AMD GPU accelerated or NVIDIA GPU accelerated.";
|
||||
example = "amd";
|
||||
type = types.enum [
|
||||
"amd"
|
||||
"nvidia"
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
config = {
|
||||
programs.neovim = {
|
||||
enable = true;
|
||||
withNodeJs = true;
|
||||
withPython3 = true;
|
||||
|
||||
extraLuaConfig = builtins.readFile ./init.lua;
|
||||
|
||||
extraPackages = with pkgs; [
|
||||
# Needed by ollama.nvim
|
||||
curl
|
||||
ollamaPackage
|
||||
|
||||
# CMAKE
|
||||
neocmakelsp
|
||||
|
||||
# C/C++
|
||||
clang-tools
|
||||
gcc # Needed for treesitter
|
||||
|
||||
# HTML/CSS/JSON
|
||||
emmet-ls
|
||||
vscode-langservers-extracted
|
||||
|
||||
# LUA
|
||||
lua-language-server
|
||||
stylua
|
||||
|
||||
# Markdown
|
||||
markdownlint-cli
|
||||
marksman
|
||||
prettierd
|
||||
|
||||
# Nix
|
||||
nixd
|
||||
nixfmt-rfc-style
|
||||
|
||||
# TypeScript
|
||||
typescript-language-server
|
||||
|
||||
# Rust
|
||||
rust-analyzer
|
||||
taplo
|
||||
vscode-extensions.vadimcn.vscode-lldb.adapter
|
||||
|
||||
# Vue
|
||||
vue-language-server
|
||||
|
||||
# Svelte
|
||||
nodePackages.svelte-language-server
|
||||
|
||||
# YAML
|
||||
yaml-language-server
|
||||
];
|
||||
};
|
||||
|
||||
xdg.configFile."nvim/lua" = {
|
||||
recursive = true;
|
||||
source = ./lua;
|
||||
};
|
||||
|
||||
xdg.configFile."nvim/lua/plugins/astrolsp.lua".text =
|
||||
let
|
||||
hostname = config.programs.neovim.flake.hostname;
|
||||
location = config.programs.neovim.flake.location;
|
||||
in
|
||||
#lua
|
||||
''
|
||||
-- AstroLSP allows you to customize the features in AstroNvim's LSP configuration engine
|
||||
-- Configuration documentation can be found with `:h astrolsp`
|
||||
-- NOTE: We highly recommend setting up the Lua Language Server (`:LspInstall lua_ls`)
|
||||
-- as this provides autocomplete and documentation while editing
|
||||
|
||||
---@type LazySpec
|
||||
return {
|
||||
"AstroNvim/astrolsp",
|
||||
---@type AstroLSPOpts
|
||||
opts = {
|
||||
-- Configuration table of features provided by AstroLSP
|
||||
features = {
|
||||
autoformat = true, -- enable or disable auto formatting on start
|
||||
codelens = true, -- enable/disable codelens refresh on start
|
||||
inlay_hints = false, -- enable/disable inlay hints on start
|
||||
semantic_tokens = true, -- enable/disable semantic token highlighting
|
||||
},
|
||||
-- customize lsp formatting options
|
||||
formatting = {
|
||||
-- control auto formatting on save
|
||||
format_on_save = {
|
||||
enabled = true, -- enable or disable format on save globally
|
||||
allow_filetypes = { -- enable format on save for specified filetypes only
|
||||
-- "go",
|
||||
"c",
|
||||
"cpp",
|
||||
"h",
|
||||
"javascript",
|
||||
"jsx",
|
||||
"lua",
|
||||
"nix",
|
||||
"rust",
|
||||
"svelte",
|
||||
"tsx",
|
||||
"typescript",
|
||||
},
|
||||
ignore_filetypes = { -- disable format on save for specified filetypes
|
||||
-- "python",
|
||||
},
|
||||
},
|
||||
disabled = { -- disable formatting capabilities for the listed language servers
|
||||
-- disable lua_ls formatting capability if you want to use StyLua to format your lua code
|
||||
-- "lua_ls",
|
||||
},
|
||||
timeout_ms = 1000, -- default format timeout
|
||||
-- filter = function(client) -- fully override the default formatting function
|
||||
-- return true
|
||||
-- end
|
||||
},
|
||||
-- enable servers that you already have installed without mason
|
||||
servers = {
|
||||
-- "pyright"
|
||||
"clangd",
|
||||
"cmake",
|
||||
"cssls",
|
||||
"eslint",
|
||||
"html",
|
||||
"jsonls",
|
||||
"lua_ls",
|
||||
"marksman",
|
||||
"nixd",
|
||||
"rust_analyzer",
|
||||
"svelte",
|
||||
"taplo",
|
||||
"tsserver",
|
||||
"volar",
|
||||
"yamlls",
|
||||
},
|
||||
-- customize language server configuration options passed to `lspconfig`
|
||||
---@diagnostic disable: missing-fields
|
||||
config = {
|
||||
-- clangd = { capabilities = { offsetEncoding = "utf-8" } },
|
||||
nixd = {
|
||||
settings = {
|
||||
nixd = {
|
||||
options = {
|
||||
nixos = {
|
||||
expr = '(builtins.getFlake ("${location}")).nixosConfigurations.${hostname}.options',
|
||||
},
|
||||
home_manager = {
|
||||
expr =
|
||||
'(builtins.getFlake ("${location}")).homeConfigurations.${hostname}.options',
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
tsserver = {
|
||||
init_options = {
|
||||
plugins = {
|
||||
{
|
||||
name = "@vue/typescript-plugin",
|
||||
location = "${pkgs.vue-language-server}/bin/vue-language-server",
|
||||
languages = { "javascript", "typescript", "vue" },
|
||||
},
|
||||
},
|
||||
},
|
||||
filetypes = {
|
||||
"javascript",
|
||||
"typescript",
|
||||
"vue",
|
||||
},
|
||||
},
|
||||
},
|
||||
-- customize how language servers are attached
|
||||
handlers = {
|
||||
-- a function without a key is simply the default handler, functions take two parameters, the server name and the configured options table for that server
|
||||
-- function(server, opts) require("lspconfig")[server].setup(opts) end
|
||||
|
||||
-- the key is the server that is being setup with `lspconfig`
|
||||
-- rust_analyzer = false, -- setting a handler to false will disable the set up of that language server
|
||||
-- pyright = function(_, opts) require("lspconfig").pyright.setup(opts) end -- or a custom handler function can be passed
|
||||
},
|
||||
-- Configure buffer local auto commands to add when attaching a language server
|
||||
autocmds = {
|
||||
-- first key is the `augroup` to add the auto commands to (:h augroup)
|
||||
lsp_document_highlight = {
|
||||
-- Optional condition to create/delete auto command group
|
||||
-- can either be a string of a client capability or a function of `fun(client, bufnr): boolean`
|
||||
-- condition will be resolved for each client on each execution and if it ever fails for all clients,
|
||||
-- the auto commands will be deleted for that buffer
|
||||
cond = "textDocument/documentHighlight",
|
||||
-- cond = function(client, bufnr) return client.name == "lua_ls" end,
|
||||
-- list of auto commands to set
|
||||
{
|
||||
-- events to trigger
|
||||
event = { "CursorHold", "CursorHoldI" },
|
||||
-- the rest of the autocmd options (:h nvim_create_autocmd)
|
||||
desc = "Document Highlighting",
|
||||
callback = function()
|
||||
vim.lsp.buf.document_highlight()
|
||||
end,
|
||||
},
|
||||
{
|
||||
event = { "CursorMoved", "CursorMovedI", "BufLeave" },
|
||||
desc = "Document Highlighting Clear",
|
||||
callback = function()
|
||||
vim.lsp.buf.clear_references()
|
||||
end,
|
||||
},
|
||||
},
|
||||
},
|
||||
-- mappings to be set up on attaching of a language server
|
||||
mappings = {
|
||||
n = {
|
||||
gl = {
|
||||
function()
|
||||
vim.diagnostic.open_float()
|
||||
end,
|
||||
desc = "Hover diagnostics",
|
||||
},
|
||||
-- a `cond` key can provided as the string of a server capability to be required to attach, or a function with `client` and `bufnr` parameters from the `on_attach` that returns a boolean
|
||||
-- gD = {
|
||||
-- function() vim.lsp.buf.declaration() end,
|
||||
-- desc = "Declaration of current symbol",
|
||||
-- cond = "textDocument/declaration",
|
||||
-- },
|
||||
-- ["<Leader>uY"] = {
|
||||
-- function() require("astrolsp.toggles").buffer_semantic_tokens() end,
|
||||
-- desc = "Toggle LSP semantic highlight (buffer)",
|
||||
-- cond = function(client) return client.server_capabilities.semanticTokensProvider and vim.lsp.semantic_tokens end,
|
||||
-- },
|
||||
},
|
||||
},
|
||||
-- A custom `on_attach` function to be run after the default `on_attach` function
|
||||
-- takes two parameters `client` and `bufnr` (`:h lspconfig-setup`)
|
||||
on_attach = function(client, bufnr)
|
||||
-- this would disable semanticTokensProvider for all clients
|
||||
-- client.server_capabilities.semanticTokensProvider = nil
|
||||
end,
|
||||
},
|
||||
}
|
||||
'';
|
||||
};
|
||||
}
|
BIN
modules/home-manager/programs/neovim/docs/example_1.png
Normal file
BIN
modules/home-manager/programs/neovim/docs/example_1.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.5 MiB |
BIN
modules/home-manager/programs/neovim/docs/example_2.png
Normal file
BIN
modules/home-manager/programs/neovim/docs/example_2.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.6 MiB |
BIN
modules/home-manager/programs/neovim/docs/example_3.png
Normal file
BIN
modules/home-manager/programs/neovim/docs/example_3.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.7 MiB |
19
modules/home-manager/programs/neovim/init.lua
Normal file
19
modules/home-manager/programs/neovim/init.lua
Normal file
|
@ -0,0 +1,19 @@
|
|||
-- This file simply bootstraps the installation of Lazy.nvim and then calls other files for execution
|
||||
-- This file doesn't necessarily need to be touched, BE CAUTIOUS editing this file and proceed at your own risk.
|
||||
local lazypath = vim.env.LAZY or vim.fn.stdpath "data" .. "/lazy/lazy.nvim"
|
||||
if not (vim.env.LAZY or (vim.uv or vim.loop).fs_stat(lazypath)) then
|
||||
-- stylua: ignore
|
||||
vim.fn.system({ "git", "clone", "--filter=blob:none", "https://github.com/folke/lazy.nvim.git", "--branch=stable", lazypath })
|
||||
end
|
||||
vim.opt.rtp:prepend(lazypath)
|
||||
|
||||
-- validate that lazy is available
|
||||
if not pcall(require, "lazy") then
|
||||
-- stylua: ignore
|
||||
vim.api.nvim_echo({ { ("Unable to load lazy from: %s\n"):format(lazypath), "ErrorMsg" }, { "Press any key to exit...", "MoreMsg" } }, true, {})
|
||||
vim.fn.getchar()
|
||||
vim.cmd.quit()
|
||||
end
|
||||
|
||||
require "lazy_setup"
|
||||
require "polish"
|
40
modules/home-manager/programs/neovim/lua/community.lua
Normal file
40
modules/home-manager/programs/neovim/lua/community.lua
Normal file
|
@ -0,0 +1,40 @@
|
|||
-- AstroCommunity: import any community modules here
|
||||
-- We import this file in `lazy_setup.lua` before the `plugins/` folder.
|
||||
-- This guarantees that the specs are processed before any user plugins.
|
||||
|
||||
---@type LazySpec
|
||||
return {
|
||||
"AstroNvim/astrocommunity",
|
||||
{ import = "astrocommunity.colorscheme.catppuccin" },
|
||||
{
|
||||
"catppuccin/nvim",
|
||||
name = "catppuccin",
|
||||
opts = function(_, config)
|
||||
config.flavour = "frappe"
|
||||
config.transparent_background = true
|
||||
end,
|
||||
},
|
||||
|
||||
{ import = "astrocommunity.editing-support.todo-comments-nvim" },
|
||||
{ import = "astrocommunity.editing-support.zen-mode-nvim" },
|
||||
|
||||
{ import = "astrocommunity.motion.flash-nvim" },
|
||||
{ import = "astrocommunity.motion.flit-nvim" },
|
||||
{ import = "astrocommunity.motion.leap-nvim" },
|
||||
{ import = "astrocommunity.motion.mini-ai" },
|
||||
{ import = "astrocommunity.motion.mini-surround" },
|
||||
|
||||
{ import = "astrocommunity.pack.cmake" },
|
||||
{ import = "astrocommunity.pack.cpp" },
|
||||
{ import = "astrocommunity.pack.godot" },
|
||||
{ import = "astrocommunity.pack.html-css" },
|
||||
{ import = "astrocommunity.pack.json" },
|
||||
{ import = "astrocommunity.pack.lua" },
|
||||
{ import = "astrocommunity.pack.markdown" },
|
||||
{ import = "astrocommunity.pack.nix" },
|
||||
{ import = "astrocommunity.pack.rust" },
|
||||
{ import = "astrocommunity.pack.toml" },
|
||||
{ import = "astrocommunity.pack.typescript" },
|
||||
{ import = "astrocommunity.pack.vue" },
|
||||
{ import = "astrocommunity.pack.yaml" },
|
||||
}
|
31
modules/home-manager/programs/neovim/lua/lazy_setup.lua
Normal file
31
modules/home-manager/programs/neovim/lua/lazy_setup.lua
Normal file
|
@ -0,0 +1,31 @@
|
|||
require("lazy").setup({
|
||||
{
|
||||
"AstroNvim/AstroNvim",
|
||||
--version = "^4", -- Remove version tracking to elect for nighly AstroNvim
|
||||
import = "astronvim.plugins",
|
||||
opts = { -- AstroNvim options must be set here with the `import` key
|
||||
mapleader = " ", -- This ensures the leader key must be configured before Lazy is set up
|
||||
maplocalleader = ",", -- This ensures the localleader key must be configured before Lazy is set up
|
||||
icons_enabled = true, -- Set to false to disable icons (if no Nerd Font is available)
|
||||
pin_plugins = nil, -- Default will pin plugins when tracking `version` of AstroNvim, set to true/false to override
|
||||
},
|
||||
},
|
||||
{ import = "community" },
|
||||
{ import = "plugins" },
|
||||
} --[[@as LazySpec]], {
|
||||
-- Configure any other `lazy.nvim` configuration options here
|
||||
install = { colorscheme = { "astrodark", "habamax" } },
|
||||
ui = { backdrop = 100 },
|
||||
performance = {
|
||||
rtp = {
|
||||
-- disable some rtp plugins, add more to your liking
|
||||
disabled_plugins = {
|
||||
"gzip",
|
||||
"netrwPlugin",
|
||||
"tarPlugin",
|
||||
"tohtml",
|
||||
"zipPlugin",
|
||||
},
|
||||
},
|
||||
},
|
||||
} --[[@as LazyConfig]])
|
|
@ -0,0 +1,84 @@
|
|||
-- AstroCore provides a central place to modify mappings, vim options, autocommands, and more!
|
||||
-- Configuration documentation can be found with `:h astrocore`
|
||||
-- NOTE: We highly recommend setting up the Lua Language Server (`:LspInstall lua_ls`)
|
||||
-- as this provides autocomplete and documentation while editing
|
||||
|
||||
---@type LazySpec
|
||||
return {
|
||||
"AstroNvim/astrocore",
|
||||
---@type AstroCoreOpts
|
||||
opts = {
|
||||
-- Configure core features of AstroNvim
|
||||
features = {
|
||||
large_buf = { size = 1024 * 500, lines = 10000 }, -- set global limits for large files for disabling features like treesitter
|
||||
autopairs = true, -- enable autopairs at start
|
||||
cmp = true, -- enable completion at start
|
||||
diagnostics_mode = 3, -- diagnostic mode on start (0 = off, 1 = no signs/virtual text, 2 = no virtual text, 3 = on)
|
||||
highlighturl = true, -- highlight URLs at start
|
||||
notifications = true, -- enable notifications at start
|
||||
},
|
||||
-- Diagnostics configuration (for vim.diagnostics.config({...})) when diagnostics are on
|
||||
diagnostics = {
|
||||
virtual_text = true,
|
||||
underline = true,
|
||||
},
|
||||
-- vim options can be configured here
|
||||
options = {
|
||||
opt = { -- vim.opt.<key>
|
||||
autoindent = true, -- indents automatically based on context
|
||||
expandtab = true, -- use spaces instead of tabs
|
||||
grepprg = "rg --vimgrep", -- use ripgrep on grep actions
|
||||
number = true, -- sets vim.opt.number
|
||||
relativenumber = true, -- sets vim.opt.relativenumber
|
||||
shiftwidth = 2, -- how many spaces after indentation
|
||||
signcolumn = "auto", -- sets vim.opt.signcolumn to auto
|
||||
smartindent = true, -- smartly indent
|
||||
spell = false, -- sets vim.opt.spell
|
||||
tabstop = 2, -- how many spaces to indent when pressing tab
|
||||
wrap = false, -- sets vim.opt.wrap
|
||||
},
|
||||
g = { -- vim.g.<key>
|
||||
-- configure global vim variables (vim.g)
|
||||
-- NOTE: `mapleader` and `maplocalleader` must be set in the AstroNvim opts or before `lazy.setup`
|
||||
-- This can be found in the `lua/lazy_setup.lua` file
|
||||
},
|
||||
},
|
||||
-- Mappings can be configured through AstroCore as well.
|
||||
-- NOTE: keycodes follow the casing in the vimdocs. For example, `<Leader>` must be capitalized
|
||||
mappings = {
|
||||
-- first key is the mode
|
||||
n = {
|
||||
-- second key is the lefthand side of the map
|
||||
|
||||
-- navigate buffer tabs with `H` and `L`
|
||||
-- L = {
|
||||
-- function() require("astrocore.buffer").nav(vim.v.count > 0 and vim.v.count or 1) end,
|
||||
-- desc = "Next buffer",
|
||||
-- },
|
||||
-- H = {
|
||||
-- function() require("astrocore.buffer").nav(-(vim.v.count > 0 and vim.v.count or 1)) end,
|
||||
-- desc = "Previous buffer",
|
||||
-- },
|
||||
|
||||
-- mappings seen under group name "Buffer"
|
||||
["<Leader>bD"] = {
|
||||
function()
|
||||
require("astroui.status.heirline").buffer_picker(function(bufnr)
|
||||
require("astrocore.buffer").close(bufnr)
|
||||
end)
|
||||
end,
|
||||
desc = "Pick to close",
|
||||
},
|
||||
-- tables with just a `desc` key will be registered with which-key if it's installed
|
||||
-- this is useful for naming menus
|
||||
["<Leader>b"] = { desc = "Buffers" },
|
||||
-- quick save
|
||||
-- ["<C-s>"] = { ":w!<cr>", desc = "Save File" }, -- change description but the same command
|
||||
},
|
||||
t = {
|
||||
-- setting a mapping to false will disable it
|
||||
-- ["<esc>"] = false,
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
37
modules/home-manager/programs/neovim/lua/plugins/astroui.lua
Normal file
37
modules/home-manager/programs/neovim/lua/plugins/astroui.lua
Normal file
|
@ -0,0 +1,37 @@
|
|||
-- AstroUI provides the basis for configuring the AstroNvim User Interface
|
||||
-- Configuration documentation can be found with `:h astroui`
|
||||
-- NOTE: We highly recommend setting up the Lua Language Server (`:LspInstall lua_ls`)
|
||||
-- as this provides autocomplete and documentation while editing
|
||||
|
||||
---@type LazySpec
|
||||
return {
|
||||
"AstroNvim/astroui",
|
||||
---@type AstroUIOpts
|
||||
opts = {
|
||||
-- change colorscheme
|
||||
colorscheme = "catppuccin",
|
||||
-- AstroUI allows you to easily modify highlight groups easily for any and all colorschemes
|
||||
highlights = {
|
||||
init = { -- this table overrides highlights in all themes
|
||||
-- Normal = { bg = "#000000" },
|
||||
},
|
||||
astrotheme = { -- a table of overrides/changes when applying the astrotheme theme
|
||||
-- Normal = { bg = "#000000" },
|
||||
},
|
||||
},
|
||||
-- Icons can be configured throughout the interface
|
||||
icons = {
|
||||
-- configure the loading of the lsp in the status line
|
||||
LSPLoading1 = "⠋",
|
||||
LSPLoading2 = "⠙",
|
||||
LSPLoading3 = "⠹",
|
||||
LSPLoading4 = "⠸",
|
||||
LSPLoading5 = "⠼",
|
||||
LSPLoading6 = "⠴",
|
||||
LSPLoading7 = "⠦",
|
||||
LSPLoading8 = "⠧",
|
||||
LSPLoading9 = "⠇",
|
||||
LSPLoading10 = "⠏",
|
||||
},
|
||||
},
|
||||
}
|
31
modules/home-manager/programs/neovim/lua/plugins/mason.lua
Normal file
31
modules/home-manager/programs/neovim/lua/plugins/mason.lua
Normal file
|
@ -0,0 +1,31 @@
|
|||
-- Customize Mason plugins
|
||||
|
||||
---@type LazySpec
|
||||
return {
|
||||
-- use mason-lspconfig to configure LSP installations
|
||||
{
|
||||
"williamboman/mason-lspconfig.nvim",
|
||||
-- overrides `require("mason-lspconfig").setup(...)`
|
||||
opts = function(_, opts)
|
||||
opts.ensure_installed = nil
|
||||
opts.automatic_installation = false
|
||||
end,
|
||||
},
|
||||
-- use mason-null-ls to configure Formatters/Linter installation for null-ls sources
|
||||
{
|
||||
"jay-babu/mason-null-ls.nvim",
|
||||
-- overrides `require("mason-null-ls").setup(...)`
|
||||
opts = function(_, opts)
|
||||
opts.ensure_installed = nil
|
||||
opts.automatic_installation = false
|
||||
end,
|
||||
},
|
||||
{
|
||||
"jay-babu/mason-nvim-dap.nvim",
|
||||
-- overrides `require("mason-nvim-dap").setup(...)`
|
||||
opts = function(_, opts)
|
||||
opts.ensure_installed = nil
|
||||
opts.automatic_installation = false
|
||||
end,
|
||||
},
|
||||
}
|
22
modules/home-manager/programs/neovim/lua/plugins/none-ls.lua
Normal file
22
modules/home-manager/programs/neovim/lua/plugins/none-ls.lua
Normal file
|
@ -0,0 +1,22 @@
|
|||
-- Customize None-ls sources
|
||||
|
||||
---@type LazySpec
|
||||
return {
|
||||
"nvimtools/none-ls.nvim",
|
||||
opts = function(_, config)
|
||||
-- config variable is the default configuration table for the setup function call
|
||||
local null_ls = require("null-ls")
|
||||
|
||||
-- Check supported formatters and linters
|
||||
-- https://github.com/nvimtools/none-ls.nvim/tree/main/lua/null-ls/builtins/formatting
|
||||
-- https://github.com/nvimtools/none-ls.nvim/tree/main/lua/null-ls/builtins/diagnostics
|
||||
config.sources = {
|
||||
-- Set a formatter
|
||||
null_ls.builtins.formatting.clang_format,
|
||||
null_ls.builtins.formatting.nixfmt,
|
||||
null_ls.builtins.formatting.prettier,
|
||||
null_ls.builtins.formatting.stylua,
|
||||
}
|
||||
return config -- return final config table
|
||||
end,
|
||||
}
|
|
@ -0,0 +1,49 @@
|
|||
-- Customize Treesitter
|
||||
|
||||
---@type LazySpec
|
||||
return {
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
opts = function(_, opts)
|
||||
-- add more things to the ensure_installed table protecting against community packs modifying it
|
||||
opts.ensure_installed = require("astrocore").list_insert_unique(opts.ensure_installed, {
|
||||
-- Programming
|
||||
"c",
|
||||
"cmake",
|
||||
"cpp",
|
||||
"css",
|
||||
"gdscript",
|
||||
"godot_resource",
|
||||
"html",
|
||||
"hyprlang",
|
||||
"javascript",
|
||||
"jsdoc",
|
||||
"lua",
|
||||
"nim",
|
||||
"nim_format_string",
|
||||
"objc",
|
||||
"proto",
|
||||
"python",
|
||||
"svelte",
|
||||
"tsx",
|
||||
"typescript",
|
||||
"vue",
|
||||
-- Scripting
|
||||
"bash",
|
||||
"glsl",
|
||||
-- Configuring
|
||||
"dockerfile",
|
||||
"json",
|
||||
"jsonc",
|
||||
"nix",
|
||||
"yaml",
|
||||
-- Misc
|
||||
"cuda",
|
||||
"markdown",
|
||||
"markdown_inline",
|
||||
"query",
|
||||
-- VIM
|
||||
"vim",
|
||||
"vimdoc",
|
||||
})
|
||||
end,
|
||||
}
|
93
modules/home-manager/programs/neovim/lua/plugins/user.lua
Normal file
93
modules/home-manager/programs/neovim/lua/plugins/user.lua
Normal file
|
@ -0,0 +1,93 @@
|
|||
-- You can also add or configure plugins by creating files in this `plugins/` folder
|
||||
-- Here are some examples:
|
||||
|
||||
---@type LazySpec
|
||||
return {
|
||||
|
||||
-- Discord presence
|
||||
"andweeb/presence.nvim",
|
||||
{
|
||||
"ray-x/lsp_signature.nvim",
|
||||
event = "BufRead",
|
||||
config = function()
|
||||
require("lsp_signature").setup()
|
||||
end,
|
||||
},
|
||||
|
||||
-- Customize alpha options
|
||||
{
|
||||
"goolord/alpha-nvim",
|
||||
opts = function(_, opts)
|
||||
-- customize the dashboard header
|
||||
opts.section.header.val = {
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣀⣠⣤⣶⣶⣾⣿⣿⣿⣿⣷⣶⣄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣠⣶⣾⣿⣿⣿⣿⣷⣶⣶⣤⣄⣀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⢀⣠⡴⠾⠟⠋⠉⠉⠀⠀⠀⠀⠀⠀⠀⠈⠉⠉⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⠉⠉⠁⠀⠀⠀⠀⠀⠀⠀⠉⠉⠙⠛⠷⢦⣄⡀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠘⠋⠁⠀⠀⢀⣀⣤⣶⣖⣒⣒⡲⠶⣤⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣤⠶⢖⣒⣒⣲⣶⣤⣀⡀⠀⠀⠈⠙⠂⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⣠⢖⣫⣷⣿⣿⣿⣿⣿⣿⣶⣤⡙⢦⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⡴⢋⣤⣾⣿⣿⣿⣿⣿⣿⣾⣝⡲⣄⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⣄⣀⣠⢿⣿⣿⣿⣿⣿⣿⣿⡿⠟⠻⢿⣿⣿⣦⣳⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣟⣴⣿⣿⡿⠟⠻⢿⣿⣿⣿⣿⣿⣿⣿⡻⣄⣀⣤⠀⠀⠀",
|
||||
"⠀⠀⠀⠈⠟⣿⣿⣿⡿⢻⣿⣿⣿⠃⠀⠀⠀⠀⠙⣿⣿⣿⠓⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠚⣿⣿⣿⠋⠀⠀⠀⠀⠘⣿⣿⣿⡟⢿⣿⣿⣟⠻⠁⠀⠀⠀",
|
||||
"⠤⣤⣶⣶⣿⣿⣿⡟⠀⣿⣿⣿⡇⠀⠀⠀⠀⠀⠀⢻⣿⣿⡇⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⣿⣿⡏⠀⠀⠀⠀⠀⠀⣹⣿⣿⣷⠈⢻⣿⣿⣿⣶⣦⣤⠤",
|
||||
"⠀⠀⠀⠀⠀⢻⣟⠀⠀⣿⣿⣿⣿⡀⠀⠀⠀⠀⢀⣿⣿⡟⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⢻⣿⣿⡀⠀⠀⠀⠀⢀⣿⣿⣿⣿⠀⠀⣿⡟⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠻⣆⠀⢹⣿⠟⢿⣿⣦⣤⣤⣴⣿⣿⣿⠃⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠘⣿⡿⢷⣤⣤⣤⣴⣿⣿⣿⣿⡇⠀⣰⠟⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠙⠂⠀⠙⢀⣀⣿⣿⣿⣿⣿⣿⣿⠟⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠻⠁⠀⣻⣿⣿⣿⣿⣿⣿⠏⠀⠘⠃⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⡈⠻⠿⣿⣿⣿⡿⠟⠋⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠘⠻⢿⣿⣿⣿⠿⠛⢁⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠚⠛⣶⣦⣤⣤⣤⡤⠆⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠰⢤⣤⣤⣤⣶⣾⠛⠓⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
}
|
||||
return opts
|
||||
end,
|
||||
},
|
||||
|
||||
-- Adds highlighting and lsp features for embedded code in documents.
|
||||
{
|
||||
"jmbuhr/otter.nvim",
|
||||
dependencies = {
|
||||
"hrsh7th/nvim-cmp",
|
||||
"neovim/nvim-lspconfig",
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
},
|
||||
},
|
||||
|
||||
-- Adds highlighting and custom commands for ledger files
|
||||
{
|
||||
"ledger/vim-ledger",
|
||||
},
|
||||
|
||||
-- Better UI hooks
|
||||
{
|
||||
"stevearc/dressing.nvim",
|
||||
},
|
||||
|
||||
-- Add Ollama support in-editor
|
||||
{
|
||||
"nomnivore/ollama.nvim",
|
||||
dependencies = {
|
||||
"nvim-lua/plenary.nvim",
|
||||
},
|
||||
|
||||
-- All the user commands added by the plugin
|
||||
cmd = { "Ollama", "OllamaModel", "OllamaServe", "OllamaServeStop" },
|
||||
|
||||
keys = {
|
||||
-- Sample keybind for prompt menu. Note that the <c-u> is important for selections to work properly.
|
||||
{
|
||||
"<leader>oo",
|
||||
":<c-u>lua require('ollama').prompt()<cr>",
|
||||
desc = "ollama prompt",
|
||||
mode = { "n", "v" },
|
||||
},
|
||||
|
||||
-- Sample keybind for direct prompting. Note that the <c-u> is important for selections to work properly.
|
||||
{
|
||||
"<leader>oG",
|
||||
":<c-u>lua require('ollama').prompt('Generate_Code')<cr>",
|
||||
desc = "ollama Generate Code",
|
||||
mode = { "n", "v" },
|
||||
},
|
||||
},
|
||||
|
||||
---@type Ollama.Config
|
||||
opts = {
|
||||
-- your configuration overrides
|
||||
},
|
||||
},
|
||||
}
|
39
modules/home-manager/programs/neovim/lua/polish.lua
Normal file
39
modules/home-manager/programs/neovim/lua/polish.lua
Normal file
|
@ -0,0 +1,39 @@
|
|||
-- This will run last in the setup process and is a good place to configure
|
||||
-- things like custom filetypes. This just pure lua so anything that doesn't
|
||||
-- fit in the normal config locations above can go here
|
||||
|
||||
-- Set up custom filetypes
|
||||
vim.filetype.add {
|
||||
extension = {
|
||||
foo = "fooscript",
|
||||
},
|
||||
filename = {
|
||||
["Foofile"] = "fooscript",
|
||||
},
|
||||
pattern = {
|
||||
["~/%.config/foo/.*"] = "fooscript",
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
local dap = require "dap"
|
||||
|
||||
dap.adapters.codelldb = {
|
||||
port = "${port}",
|
||||
type = "server",
|
||||
executable = {
|
||||
command = "codelldb",
|
||||
args = { "--port", "${port}" },
|
||||
},
|
||||
}
|
||||
|
||||
dap.configurations.rust = {
|
||||
{
|
||||
name = "Launch file",
|
||||
type = "codelldb",
|
||||
request = "launch",
|
||||
program = function() return vim.fn.input("Path to executable: ", vim.fn.getcwd() .. "/", "file") end,
|
||||
cwd = "${workspaceFolder}",
|
||||
stopOnEntry = false,
|
||||
},
|
||||
}
|
53
modules/home-manager/services.nix
Normal file
53
modules/home-manager/services.nix
Normal file
|
@ -0,0 +1,53 @@
|
|||
{
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
openttd
|
||||
];
|
||||
|
||||
systemd.user.services.openttd = {
|
||||
Install.WantedBy = [ "default.target" ];
|
||||
|
||||
Unit.Description = "OpenTTD Tmux server";
|
||||
|
||||
Service = {
|
||||
ExecStart = "${pkgs.tmux}/bin/tmux new -s OpenTTD -d '${pkgs.openttd}/bin/openttd -g /home/wizardlink/.local/share/openttd/save/hyfy.sav -D'";
|
||||
ExecStop = "${pkgs.tmux}/bin/tmux kill-server";
|
||||
Restart = "on-failure";
|
||||
Type = "forking";
|
||||
};
|
||||
};
|
||||
|
||||
systemd.user.services.openttd-rcon = {
|
||||
Install.WantedBy = [ "default.target" ];
|
||||
|
||||
Unit = {
|
||||
Description = "OpenTTD RCON Password set";
|
||||
After = [ "openttd.service" ];
|
||||
};
|
||||
|
||||
Service = {
|
||||
ExecStart = "${pkgs.tmux}/bin/tmux send-keys -t OpenTTD 'rcon_pw aaaa' Enter";
|
||||
Type = "oneshot";
|
||||
};
|
||||
};
|
||||
|
||||
systemd.user.services.openttd-save = {
|
||||
Install.WantedBy = [ "default.target" ];
|
||||
|
||||
Unit = {
|
||||
Description = "OpenTTD RCON Password set";
|
||||
After = [ "openttd.service" ];
|
||||
};
|
||||
|
||||
Service = {
|
||||
ExecStart = "${pkgs.tmux}/bin/tmux send-keys -t OpenTTD 'save hyfy' Enter";
|
||||
Type = "simple";
|
||||
Restart = "always";
|
||||
RestartSec = "1800s";
|
||||
};
|
||||
};
|
||||
}
|
70
modules/home-manager/theming.nix
Normal file
70
modules/home-manager/theming.nix
Normal file
|
@ -0,0 +1,70 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
home.file = {
|
||||
# Cattpuccin theme for fish shell.
|
||||
".config/fish/themes/Catppuccin-Frappe.theme".source = ./theming/Catppuccin-Frappe.theme;
|
||||
|
||||
## Kvantum's theme configuration.
|
||||
".config/Kvantum/Catppuccin-Frappe-Lavender" = {
|
||||
source = "${
|
||||
pkgs.catppuccin-kvantum.override {
|
||||
accent = "Lavender";
|
||||
variant = "Frappe";
|
||||
}
|
||||
}/share/Kvantum/Catppuccin-Frappe-Lavender";
|
||||
};
|
||||
|
||||
".config/Kvantum/kvantum.kvconfig".text = ''
|
||||
[General]
|
||||
theme=Catppuccin-Frappe-Lavender
|
||||
'';
|
||||
##
|
||||
|
||||
## Themeing configuration for qt5 and qt6
|
||||
".config/qt5ct/colors".source = ./theming/qt5ct;
|
||||
|
||||
".config/qt6ct/colors".source = ./theming/qt5ct; # We use the qt5ct because it's the SAME spec
|
||||
##
|
||||
|
||||
".local/share/SpeedCrunch/color-schemes/catppuccin-frappe.json" = {
|
||||
recursive = true;
|
||||
source = builtins.fetchurl {
|
||||
url = "https://raw.githubusercontent.com/catppuccin/speedcrunch/34f2b382de0188d2fd85f59a8a366f313fc30a71/themes/catppuccin-frappe.json";
|
||||
sha256 = "sha256:0imx5a53p3ls5kddplgr7mbpbidrmzl9qiwpv7r8jjmsf8yxs0i4";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
home.pointerCursor = {
|
||||
package = pkgs.catppuccin-cursors.frappeLavender;
|
||||
name = "catppuccin-frappe-lavender-cursors";
|
||||
|
||||
gtk.enable = true;
|
||||
x11.enable = true;
|
||||
};
|
||||
|
||||
# Configure GTK.
|
||||
gtk = {
|
||||
enable = true;
|
||||
|
||||
gtk3.extraConfig = {
|
||||
gtk-application-prefer-dark-theme = true;
|
||||
};
|
||||
|
||||
gtk4.extraConfig = {
|
||||
gtk-application-prefer-dark-theme = true;
|
||||
};
|
||||
|
||||
iconTheme = {
|
||||
name = "Papirus-Dark";
|
||||
package = pkgs.papirus-icon-theme.override { color = "violet"; };
|
||||
};
|
||||
};
|
||||
|
||||
# Configure QT
|
||||
qt = {
|
||||
enable = true;
|
||||
platformTheme.name = "qtct";
|
||||
};
|
||||
}
|
30
modules/nixos/common.nix
Normal file
30
modules/nixos/common.nix
Normal file
|
@ -0,0 +1,30 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
# Enable experimental features
|
||||
nix.settings.experimental-features = [
|
||||
"nix-command"
|
||||
"flakes"
|
||||
];
|
||||
|
||||
# Enable nh, a bundle of CLI utilities for NixOS
|
||||
programs.nh = {
|
||||
enable = true;
|
||||
|
||||
# Enable automatic garbage collection.
|
||||
clean.enable = true;
|
||||
clean.extraArgs = "--keep-since 4d --keep 3";
|
||||
|
||||
flake = "/home/wizardlink/.system";
|
||||
};
|
||||
|
||||
# Optimize storage
|
||||
nix.optimise.automatic = true;
|
||||
nix.settings.auto-optimise-store = true;
|
||||
|
||||
# Enable Hyprland's cachix
|
||||
nix.settings.substituters = [ "https://hyprland.cachix.org" ];
|
||||
nix.settings.trusted-public-keys = [
|
||||
"hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="
|
||||
];
|
||||
}
|
13
modules/nixos/default.nix
Normal file
13
modules/nixos/default.nix
Normal file
|
@ -0,0 +1,13 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./common.nix
|
||||
./desktop.nix
|
||||
./hardware.nix
|
||||
./packages.nix
|
||||
./services.nix
|
||||
./sound.nix
|
||||
./system.nix
|
||||
];
|
||||
}
|
83
modules/nixos/desktop.nix
Normal file
83
modules/nixos/desktop.nix
Normal file
|
@ -0,0 +1,83 @@
|
|||
{ pkgs, hyprland, ... }:
|
||||
|
||||
let
|
||||
hyprland-pkgs = hyprland.inputs.nixpkgs.legacyPackages.${pkgs.stdenv.hostPlatform.system};
|
||||
in
|
||||
{
|
||||
environment.sessionVariables = {
|
||||
# Set env for Fcitx5
|
||||
QMODIFIERS = "@im=fcitx5";
|
||||
};
|
||||
|
||||
# Enable SDDM.
|
||||
services.displayManager.sddm = {
|
||||
enable = true;
|
||||
wayland.enable = true;
|
||||
theme = "catppuccin-frappe";
|
||||
package = pkgs.kdePackages.sddm;
|
||||
};
|
||||
|
||||
# Enable Hyprland
|
||||
programs.hyprland = {
|
||||
enable = true;
|
||||
|
||||
package = hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland;
|
||||
portalPackage = pkgs.xdg-desktop-portal-wlr;
|
||||
};
|
||||
|
||||
# Enable XDG Desktop Portals.
|
||||
xdg.portal = {
|
||||
enable = true;
|
||||
|
||||
config = {
|
||||
common = {
|
||||
default = [ "wlr" ];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
# Needed for home-manager
|
||||
environment.pathsToLink = [
|
||||
"/share/xdg-desktop-portal"
|
||||
"/share/applications"
|
||||
];
|
||||
|
||||
# Enable OpenGL.
|
||||
hardware.graphics = {
|
||||
enable = true;
|
||||
enable32Bit = true;
|
||||
|
||||
package = hyprland-pkgs.mesa.drivers;
|
||||
package32 = hyprland-pkgs.pkgsi686Linux.mesa.drivers;
|
||||
|
||||
extraPackages = with pkgs; [
|
||||
rocm-opencl-icd # OpenGL hwa
|
||||
rocm-opencl-runtime
|
||||
];
|
||||
};
|
||||
|
||||
# Enable Thunar and it's dependencies
|
||||
programs.thunar = {
|
||||
enable = true;
|
||||
plugins = with pkgs.xfce; [ thunar-archive-plugin ];
|
||||
};
|
||||
programs.xfconf.enable = true; # For configuring
|
||||
services.gvfs.enable = true; # For mounting drives, trash, etc.
|
||||
services.tumbler.enable = true; # Thumbnail support
|
||||
|
||||
# Enable the Fcitx5 IME
|
||||
i18n.inputMethod = {
|
||||
enable = true;
|
||||
type = "fcitx5";
|
||||
|
||||
fcitx5 = {
|
||||
addons = with pkgs; [
|
||||
fcitx5-mozc
|
||||
fcitx5-gtk
|
||||
fcitx5-catppuccin
|
||||
];
|
||||
|
||||
waylandFrontend = true;
|
||||
};
|
||||
};
|
||||
}
|
13
modules/nixos/hardware.nix
Normal file
13
modules/nixos/hardware.nix
Normal file
|
@ -0,0 +1,13 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
# Enable Bluetooth
|
||||
hardware.bluetooth = {
|
||||
enable = true;
|
||||
powerOnBoot = true;
|
||||
};
|
||||
services.blueman.enable = true;
|
||||
|
||||
# Enable fstrim for better ssd lifespan
|
||||
services.fstrim.enable = true;
|
||||
}
|
108
modules/nixos/packages.nix
Normal file
108
modules/nixos/packages.nix
Normal file
|
@ -0,0 +1,108 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
# Allow unfree packages
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
||||
# Enable GPG.
|
||||
programs.gnupg.agent = {
|
||||
enable = true;
|
||||
enableSSHSupport = true;
|
||||
};
|
||||
|
||||
# Enable fish system-wide to integrate with nixpkgs.
|
||||
programs.fish.enable = true;
|
||||
|
||||
# Enable Steam.
|
||||
programs.steam = {
|
||||
enable = true;
|
||||
|
||||
remotePlay.openFirewall = true;
|
||||
localNetworkGameTransfers.openFirewall = true;
|
||||
# ^ Enables so we can transfer games to other computers in the network.
|
||||
|
||||
# Add Proton-GE to 'compatibilitytools.d'.
|
||||
extraCompatPackages = with pkgs; [ proton-ge-bin ];
|
||||
};
|
||||
|
||||
# Enable and configure gamemode.
|
||||
programs.gamemode = {
|
||||
enable = true;
|
||||
enableRenice = true;
|
||||
};
|
||||
|
||||
# Enable KDEConnect
|
||||
programs.kdeconnect.enable = true;
|
||||
|
||||
# Enable Docker.
|
||||
virtualisation.docker.enable = true;
|
||||
|
||||
# Enable virt-manager
|
||||
programs.virt-manager.enable = true;
|
||||
|
||||
# Enable virtd and spice USB redirection
|
||||
virtualisation.spiceUSBRedirection.enable = true;
|
||||
virtualisation.libvirtd.enable = true;
|
||||
|
||||
# List packages installed in system profile. To search, run:
|
||||
# $ nix search wget
|
||||
environment.systemPackages = with pkgs; [
|
||||
## Tools
|
||||
# Utilities
|
||||
bat
|
||||
btrfs-progs
|
||||
duf
|
||||
fuseiso
|
||||
lm_sensors
|
||||
p7zip
|
||||
tree
|
||||
unrar
|
||||
unzip
|
||||
wget
|
||||
zip
|
||||
|
||||
# File managing
|
||||
sshfs
|
||||
yazi
|
||||
|
||||
# Virtualization
|
||||
docker-compose
|
||||
quickemu
|
||||
|
||||
# Desktop
|
||||
wl-clipboard
|
||||
xclip
|
||||
zoxide
|
||||
(catppuccin-sddm.override # So SDDM finds the theme files.
|
||||
{
|
||||
flavor = "frappe";
|
||||
font = "FantasqueSansM Nerd Font";
|
||||
fontSize = "12";
|
||||
background = "${./theming/sddm/Background.jpg}";
|
||||
loginBackground = true;
|
||||
}
|
||||
)
|
||||
|
||||
# Networking
|
||||
gping
|
||||
nmap
|
||||
|
||||
# Processes
|
||||
btop
|
||||
killall
|
||||
|
||||
# Filter
|
||||
fzf
|
||||
ripgrep
|
||||
|
||||
## Libraries
|
||||
libsForQt5.qt5.qtgraphicaleffects
|
||||
libsForQt5.qt5.qtquickcontrols2
|
||||
pkgsi686Linux.gperftools # Needed for TF2 rn :(
|
||||
|
||||
## Hardware specific
|
||||
openrazer-daemon # Razor products back-end
|
||||
polychromatic # and it's front-end
|
||||
vial
|
||||
];
|
||||
}
|
38
modules/nixos/services.nix
Normal file
38
modules/nixos/services.nix
Normal file
|
@ -0,0 +1,38 @@
|
|||
{
|
||||
pkgs,
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
# Enable polkit,
|
||||
security.polkit.enable = true;
|
||||
|
||||
# install an agent to interface with it,
|
||||
environment.systemPackages = with pkgs; [ polkit_gnome ];
|
||||
|
||||
# And enable GNOME keyring for registering keys.
|
||||
services.gnome.gnome-keyring.enable = true;
|
||||
|
||||
services.postgresql = {
|
||||
identMap = lib.mkIf config.services.postgresql.enable ''
|
||||
# MAP_NAME SYSTEM_USER DB_USER
|
||||
superuser_map root postgres
|
||||
superuser_map postgres postgres
|
||||
superuser_map /^(.*)$ \1
|
||||
'';
|
||||
|
||||
authentication = lib.mkIf config.services.postgresql.enable (
|
||||
lib.mkOverride 10 ''
|
||||
# TYPE DATABASE USER ADDRESS METHOD MAP
|
||||
local all all peer map=superuser_map
|
||||
host all all 127.0.0.1/32 md5
|
||||
host all all ::1/128 md5
|
||||
local replication all peer map=superuser_map
|
||||
host replication all 127.0.0.1/32 ident map=superuser_map
|
||||
host replication all ::1/128 ident map=superuser_map
|
||||
''
|
||||
);
|
||||
};
|
||||
}
|
16
modules/nixos/sound.nix
Normal file
16
modules/nixos/sound.nix
Normal file
|
@ -0,0 +1,16 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
# Enable sound with pipewire.
|
||||
hardware.pulseaudio.enable = false;
|
||||
security.rtkit.enable = true;
|
||||
services.pipewire = {
|
||||
enable = true;
|
||||
audio.enable = true;
|
||||
|
||||
alsa.enable = true;
|
||||
alsa.support32Bit = true;
|
||||
|
||||
pulse.enable = true;
|
||||
};
|
||||
}
|
54
modules/nixos/system.nix
Normal file
54
modules/nixos/system.nix
Normal file
|
@ -0,0 +1,54 @@
|
|||
{ pkgs, config, ... }:
|
||||
|
||||
{
|
||||
# Kernel
|
||||
boot.kernelPackages = pkgs.linuxPackages_zen;
|
||||
|
||||
# Add AMD drivers.
|
||||
boot.initrd.kernelModules = [ "amdgpu" ];
|
||||
|
||||
boot.extraModulePackages = [
|
||||
config.boot.kernelPackages.v4l2loopback
|
||||
];
|
||||
|
||||
# Bootloader.
|
||||
boot.loader = {
|
||||
systemd-boot = {
|
||||
enable = true;
|
||||
configurationLimit = 10;
|
||||
};
|
||||
|
||||
efi.canTouchEfiVariables = true;
|
||||
};
|
||||
|
||||
# Enables zram.
|
||||
zramSwap.enable = true;
|
||||
|
||||
# Enable networking
|
||||
networking.networkmanager.enable = true;
|
||||
|
||||
# Enable WOL on my ethernet interface.
|
||||
networking.interfaces.enp5s0.wakeOnLan.enable = true;
|
||||
|
||||
# Define variables that will be initialized in PAM.
|
||||
environment.sessionVariables = {
|
||||
# Set env for Fcitx5
|
||||
QMODIFIERS = "@im=fcitx5";
|
||||
};
|
||||
|
||||
# Set fish as the default shell for all users.
|
||||
users.defaultUserShell = pkgs.fish;
|
||||
|
||||
# Enable CUPS to print documents.
|
||||
services.printing.enable = true;
|
||||
|
||||
# Enable the OpenSSH daemon.
|
||||
services.openssh = {
|
||||
enable = true;
|
||||
|
||||
settings = {
|
||||
PasswordAuthentication = false;
|
||||
PermitRootLogin = "no";
|
||||
};
|
||||
};
|
||||
}
|
Before Width: | Height: | Size: 4.8 MiB After Width: | Height: | Size: 4.8 MiB |
511
nixos.nix
511
nixos.nix
|
@ -1,511 +0,0 @@
|
|||
# Edit this configuration file to define what should be installed on
|
||||
# your system. Help is available in the configuration.nix(5) man page
|
||||
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
||||
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
hyprland,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
hyprland-pkgs = hyprland.inputs.nixpkgs.legacyPackages.${pkgs.stdenv.hostPlatform.system};
|
||||
in
|
||||
{
|
||||
##
|
||||
## NIXOS ##
|
||||
##
|
||||
|
||||
imports = [
|
||||
# Include the results of the hardware scan.
|
||||
./hardware-configuration.nix
|
||||
# Include service configuration
|
||||
./services/archi.nix
|
||||
./services/authentication.nix
|
||||
./services/caddy.nix
|
||||
./services/forgejo.nix
|
||||
./services/jellyfin.nix
|
||||
];
|
||||
|
||||
# Enable experimental features
|
||||
nix.settings.experimental-features = [
|
||||
"nix-command"
|
||||
"flakes"
|
||||
];
|
||||
|
||||
# Enable nh, a bundle of CLI utilities for NixOS
|
||||
programs.nh = {
|
||||
enable = true;
|
||||
|
||||
# Enable automatic garbage collection.
|
||||
clean.enable = true;
|
||||
clean.extraArgs = "--keep-since 4d --keep 3";
|
||||
|
||||
flake = "/home/wizardlink/.system";
|
||||
};
|
||||
|
||||
# Optimize storage
|
||||
nix.optimise.automatic = true;
|
||||
nix.settings.auto-optimise-store = true;
|
||||
|
||||
# Enable Hyprland's cachix
|
||||
nix.settings.substituters = [ "https://hyprland.cachix.org" ];
|
||||
nix.settings.trusted-public-keys = [
|
||||
"hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="
|
||||
];
|
||||
|
||||
# This value determines the NixOS release from which the default
|
||||
# settings for stateful data, like file locations and database versions
|
||||
# on your system were taken. It‘s perfectly fine and recommended to leave
|
||||
# this value at the release version of the first install of this system.
|
||||
# Before changing this value read the documentation for this option
|
||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
||||
system.stateVersion = "23.05"; # Did you read the comment?
|
||||
|
||||
##
|
||||
## SYSTEM ##
|
||||
##
|
||||
|
||||
# Kernel
|
||||
boot.kernelPackages = pkgs.linuxPackages_zen;
|
||||
|
||||
# Add AMD drivers.
|
||||
boot.initrd.kernelModules = [ "amdgpu" ];
|
||||
|
||||
# TODO: FIX IT BEING BEING OVERWRITTEN
|
||||
boot.extraModulePackages = [
|
||||
config.boot.kernelPackages.v4l2loopback
|
||||
(pkgs.callPackage ./kernel/zenergy.nix { kernel = pkgs.linux_zen; })
|
||||
];
|
||||
|
||||
# Bootloader.
|
||||
boot.loader = {
|
||||
systemd-boot = {
|
||||
enable = true;
|
||||
configurationLimit = 10;
|
||||
};
|
||||
|
||||
efi.canTouchEfiVariables = true;
|
||||
};
|
||||
|
||||
# Configure options for mounted volumes.
|
||||
fileSystems = {
|
||||
"/".options = [ "compress=zstd" ];
|
||||
"/home".options = [ "compress=zstd" ];
|
||||
"/nix".options = [
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
];
|
||||
"/mnt/extra".options = [ "nofail" ];
|
||||
"/mnt/internal".options = [ "nofail" ];
|
||||
"/mnt/media".options = [ "nofail" ];
|
||||
"/mnt/ssd".options = [ "nofail" ];
|
||||
};
|
||||
|
||||
# Enable btrf's auto scrubbing of volumes.
|
||||
services.btrfs.autoScrub = {
|
||||
enable = true;
|
||||
interval = "weekly";
|
||||
fileSystems = [ "/" ];
|
||||
};
|
||||
|
||||
# Enables zram.
|
||||
zramSwap.enable = true;
|
||||
|
||||
networking.hostName = "wizdesk"; # Define your hostname.
|
||||
|
||||
# Enable networking
|
||||
networking.networkmanager.enable = true;
|
||||
|
||||
# Enable WOL on my ethernet interface.
|
||||
networking.interfaces.enp5s0.wakeOnLan.enable = true;
|
||||
|
||||
# Open ports in the firewall.
|
||||
networking.firewall = {
|
||||
allowedTCPPorts = [
|
||||
443 # SSL
|
||||
6567 # Mindustry
|
||||
80 # HTTP
|
||||
3979 # OpenTTD
|
||||
];
|
||||
|
||||
allowedUDPPorts = [
|
||||
2626 # Dolphin emulator
|
||||
27015 # Source games
|
||||
28910 # Heretic II
|
||||
6567 # Mindustry
|
||||
8211 # Palworld
|
||||
3979 # OpenTTD
|
||||
];
|
||||
|
||||
allowedTCPPortRanges = [
|
||||
{
|
||||
from = 1714;
|
||||
to = 1764;
|
||||
} # KDEConnect
|
||||
];
|
||||
allowedUDPPortRanges = [
|
||||
{
|
||||
from = 1714;
|
||||
to = 1764;
|
||||
} # KDEConnect
|
||||
];
|
||||
};
|
||||
# Or disable the firewall altogether.
|
||||
# networking.firewall.enable = false;
|
||||
|
||||
# Define system-wide variables.
|
||||
environment.variables = { };
|
||||
|
||||
# Define variables that will be initialized in PAM.
|
||||
environment.sessionVariables = {
|
||||
# Set env for Fcitx5
|
||||
QMODIFIERS = "@im=fcitx5";
|
||||
};
|
||||
|
||||
# Set fish as the default shell for all users.
|
||||
users.defaultUserShell = pkgs.fish;
|
||||
|
||||
# Define a user account. Don't forget to set a password with ‘passwd’.
|
||||
users.users.wizardlink = {
|
||||
createHome = true;
|
||||
description = "Alexandre Cavalheiro";
|
||||
extraGroups = [
|
||||
"docker"
|
||||
"gamemode"
|
||||
"libvirtd"
|
||||
"networkmanager"
|
||||
"openrazer"
|
||||
"postgresql"
|
||||
"wheel"
|
||||
];
|
||||
|
||||
initialPassword = "wizardlink";
|
||||
isNormalUser = true;
|
||||
|
||||
openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDdGOyRbu6IOw9yqotxE6m7wCif7oP/2D0tlREa5Q6uo Alexandre Cavalheiro S. Tiago da Silva <contact@thewizard.link>"
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIISfCUsZrnCMZapdrvkUCrdRiX+1xuZBdGrynNRzDI2v" # SpaceEEC
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPInBFp7zBLhFluoww65CZzcnMdhndTawBv8QYJ5s/Xt david.alejandro.rubio@gmail.com" # Kodehawa
|
||||
];
|
||||
};
|
||||
|
||||
# Set your time zone.
|
||||
time.timeZone = "America/Sao_Paulo";
|
||||
|
||||
# Select internationalisation properties.
|
||||
i18n = {
|
||||
defaultLocale = "en_US.UTF-8";
|
||||
supportedLocales = [
|
||||
"C.UTF-8/UTF-8"
|
||||
"en_GB.UTF-8/UTF-8"
|
||||
"en_US.UTF-8/UTF-8"
|
||||
"ja_JP.UTF-8/UTF-8"
|
||||
"pt_BR.UTF-8/UTF-8"
|
||||
];
|
||||
|
||||
extraLocaleSettings = {
|
||||
LANGUAGE = "en_US.UTF-8";
|
||||
LC_ADDRESS = "en_US.UTF-8";
|
||||
LC_ALL = "en_US.UTF-8";
|
||||
LC_IDENTIFICATION = "en_US.UTF-8";
|
||||
LC_MEASUREMENT = "pt_BR.UTF-8";
|
||||
LC_MONETARY = "en_US.UTF-8";
|
||||
LC_NAME = "en_US.UTF-8";
|
||||
LC_NUMERIC = "pt_BR.UTF-8";
|
||||
LC_PAPER = "pt_BR.UTF-8";
|
||||
LC_TELEPHONE = "pt_BR.UTF-8";
|
||||
LC_TIME = "en_GB.UTF-8";
|
||||
};
|
||||
};
|
||||
|
||||
# Enable CUPS to print documents.
|
||||
services.printing.enable = true;
|
||||
|
||||
# Enable the OpenSSH daemon.
|
||||
services.openssh = {
|
||||
enable = true;
|
||||
|
||||
settings = {
|
||||
PasswordAuthentication = false;
|
||||
PermitRootLogin = "no";
|
||||
};
|
||||
};
|
||||
|
||||
##
|
||||
## HARDWARE ##
|
||||
##
|
||||
|
||||
# Enable Bluetooth
|
||||
hardware.bluetooth = {
|
||||
enable = true;
|
||||
powerOnBoot = true;
|
||||
};
|
||||
services.blueman.enable = true;
|
||||
|
||||
# Enable openrazer for managing Razer products' configuration
|
||||
hardware.openrazer = {
|
||||
enable = true;
|
||||
users = [ "wizardlink" ];
|
||||
};
|
||||
|
||||
# Enable QMK support.
|
||||
# hardware.keyboard.qmk.enable = true;
|
||||
# FIXME: Causing issues with xpadneo :(
|
||||
|
||||
# enable a better driver for wireless xbox controllers.
|
||||
hardware.xpadneo.enable = true;
|
||||
|
||||
# Enable fstrim for better ssd lifespan
|
||||
services.fstrim.enable = true;
|
||||
|
||||
##
|
||||
## DESKTOP ##
|
||||
##
|
||||
|
||||
# Enable SDDM.
|
||||
services.displayManager.sddm = {
|
||||
enable = true;
|
||||
wayland.enable = true;
|
||||
theme = "catppuccin-frappe";
|
||||
package = pkgs.kdePackages.sddm;
|
||||
};
|
||||
|
||||
# Enable Hyprland
|
||||
programs.hyprland = {
|
||||
enable = true;
|
||||
|
||||
package = hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland;
|
||||
portalPackage = pkgs.xdg-desktop-portal-wlr;
|
||||
};
|
||||
|
||||
# Enable XDG Desktop Portals.
|
||||
xdg.portal = {
|
||||
enable = true;
|
||||
|
||||
config = {
|
||||
common = {
|
||||
default = [ "wlr" ];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
# Needed for home-manager
|
||||
environment.pathsToLink = [
|
||||
"/share/xdg-desktop-portal"
|
||||
"/share/applications"
|
||||
];
|
||||
|
||||
# Enable OpenGL.
|
||||
hardware.graphics = {
|
||||
enable = true;
|
||||
enable32Bit = true;
|
||||
|
||||
package = hyprland-pkgs.mesa.drivers;
|
||||
package32 = hyprland-pkgs.pkgsi686Linux.mesa.drivers;
|
||||
|
||||
extraPackages = with pkgs; [
|
||||
rocm-opencl-icd # OpenGL hwa
|
||||
rocm-opencl-runtime
|
||||
];
|
||||
};
|
||||
|
||||
# Enable Thunar and it's dependencies
|
||||
programs.thunar = {
|
||||
enable = true;
|
||||
plugins = with pkgs.xfce; [ thunar-archive-plugin ];
|
||||
};
|
||||
programs.xfconf.enable = true; # For configuring
|
||||
services.gvfs.enable = true; # For mounting drives, trash, etc.
|
||||
services.tumbler.enable = true; # Thumbnail support
|
||||
|
||||
# Enable the Fcitx5 IME
|
||||
i18n.inputMethod = {
|
||||
enable = true;
|
||||
type = "fcitx5";
|
||||
|
||||
fcitx5 = {
|
||||
addons = with pkgs; [
|
||||
fcitx5-mozc
|
||||
fcitx5-gtk
|
||||
fcitx5-catppuccin
|
||||
];
|
||||
|
||||
waylandFrontend = true;
|
||||
};
|
||||
};
|
||||
|
||||
##
|
||||
## SOUND #
|
||||
##
|
||||
|
||||
# Enable sound with pipewire.
|
||||
hardware.pulseaudio.enable = false;
|
||||
security.rtkit.enable = true;
|
||||
services.pipewire = {
|
||||
enable = true;
|
||||
audio.enable = true;
|
||||
|
||||
alsa.enable = true;
|
||||
alsa.support32Bit = true;
|
||||
|
||||
pulse.enable = true;
|
||||
|
||||
#jack.enable = true;
|
||||
};
|
||||
|
||||
##
|
||||
## PACKAGES ##
|
||||
##
|
||||
|
||||
# Allow unfree packages
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
||||
# Enable GPG.
|
||||
programs.gnupg.agent = {
|
||||
enable = true;
|
||||
enableSSHSupport = true;
|
||||
};
|
||||
|
||||
# Enable fish system-wide to integrate with nixpkgs.
|
||||
programs.fish.enable = true;
|
||||
|
||||
# Enable Steam.
|
||||
programs.steam = {
|
||||
enable = true;
|
||||
|
||||
remotePlay.openFirewall = true;
|
||||
localNetworkGameTransfers.openFirewall = true;
|
||||
# ^ Enables so we can transfer games to other computers in the network.
|
||||
|
||||
# Add Proton-GE to 'compatibilitytools.d'.
|
||||
extraCompatPackages = with pkgs; [ proton-ge-bin ];
|
||||
};
|
||||
|
||||
# Enable and configure gamemode.
|
||||
programs.gamemode = {
|
||||
enable = true;
|
||||
enableRenice = true;
|
||||
};
|
||||
|
||||
# Enable KDEConnect
|
||||
programs.kdeconnect.enable = true;
|
||||
|
||||
# Enable Docker.
|
||||
virtualisation.docker.enable = true;
|
||||
|
||||
# Enable virt-manager
|
||||
virtualisation.libvirtd.enable = true;
|
||||
programs.virt-manager.enable = true;
|
||||
virtualisation.spiceUSBRedirection.enable = true;
|
||||
|
||||
# List packages installed in system profile. To search, run:
|
||||
# $ nix search wget
|
||||
environment.systemPackages = with pkgs; [
|
||||
## Tools
|
||||
# Utilities
|
||||
bat
|
||||
btrfs-progs
|
||||
duf
|
||||
fuseiso
|
||||
lm_sensors
|
||||
p7zip
|
||||
tree
|
||||
unrar
|
||||
unzip
|
||||
wget
|
||||
zip
|
||||
|
||||
# File managing
|
||||
sshfs
|
||||
yazi
|
||||
|
||||
# Virtualization
|
||||
docker-compose
|
||||
quickemu
|
||||
|
||||
# Desktop
|
||||
wl-clipboard
|
||||
xclip
|
||||
zoxide
|
||||
(catppuccin-sddm.override # So SDDM finds the theme files.
|
||||
{
|
||||
flavor = "frappe";
|
||||
font = "FantasqueSansM Nerd Font";
|
||||
fontSize = "12";
|
||||
background = "${./theming/sddm/Background.jpg}";
|
||||
loginBackground = true;
|
||||
}
|
||||
)
|
||||
|
||||
# Networking
|
||||
gping
|
||||
nmap
|
||||
|
||||
# Processes
|
||||
btop
|
||||
killall
|
||||
|
||||
# Filter
|
||||
fzf
|
||||
ripgrep
|
||||
|
||||
## Libraries
|
||||
libsForQt5.qt5.qtgraphicaleffects
|
||||
libsForQt5.qt5.qtquickcontrols2
|
||||
pkgsi686Linux.gperftools # Needed for TF2 rn :(
|
||||
|
||||
## Hardware specific
|
||||
openrazer-daemon # Razor products back-end
|
||||
polychromatic # and it's front-end
|
||||
via
|
||||
];
|
||||
|
||||
# Some programs need SUID wrappers, can be configured further or are
|
||||
# started in user sessions.
|
||||
# programs.mtr.enable = true;
|
||||
# programs.gnupg.agent = {
|
||||
# enable = true;
|
||||
# enableSSHSupport = true;
|
||||
# };
|
||||
|
||||
##
|
||||
## SERVICES #
|
||||
##
|
||||
|
||||
# Enable flatpak
|
||||
services.flatpak.enable = true;
|
||||
|
||||
# Enables VIA
|
||||
# services.udev.packages = [ pkgs.via ];
|
||||
# FIXME: Causing issues with xpadneo :(
|
||||
|
||||
# Enable and configure PostgreSQL.
|
||||
services.postgresql = {
|
||||
enable = true;
|
||||
|
||||
identMap = ''
|
||||
# MAP_NAME SYSTEM_USER DB_USER
|
||||
superuser_map root postgres
|
||||
superuser_map postgres postgres
|
||||
superuser_map /^(.*)$ \1
|
||||
'';
|
||||
|
||||
authentication = pkgs.lib.mkOverride 10 ''
|
||||
# TYPE DATABASE USER ADDRESS METHOD MAP
|
||||
local all all peer map=superuser_map
|
||||
host all all 127.0.0.1/32 md5
|
||||
host all all ::1/128 md5
|
||||
local replication all peer map=superuser_map
|
||||
host replication all 127.0.0.1/32 ident map=superuser_map
|
||||
host replication all ::1/128 ident map=superuser_map
|
||||
'';
|
||||
|
||||
initialScript = pkgs.writeText "backend-initScript" ''
|
||||
CREATE ROLE wizardlink WITH LOGIN SUPERUSER PASSWORD 'wizardlink' CREATEDB CREATEROLE REPLICATION;
|
||||
CREATE DATABASE wizardlink;
|
||||
GRANT ALL PRIVILEGES ON DATABASE wizardlink TO wizardlink;
|
||||
'';
|
||||
};
|
||||
}
|
|
@ -1,21 +0,0 @@
|
|||
{
|
||||
services.forgejo = {
|
||||
enable = true;
|
||||
|
||||
lfs.enable = true;
|
||||
|
||||
settings = {
|
||||
server = {
|
||||
HTTP_PORT = 3788;
|
||||
LANDING_PAGE = "explore";
|
||||
ROOT_URL = "https://git.thewizard.link";
|
||||
};
|
||||
|
||||
service = {
|
||||
DISABLE_REGISTRATION = true;
|
||||
ENABLE_REVERSE_PROXY_AUTHENTICATION = true;
|
||||
ENABLE_REVERSE_PROXY_AUTHENTICATION_API = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,23 +0,0 @@
|
|||
{
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
openttd
|
||||
];
|
||||
|
||||
systemd.user.services.openttd = {
|
||||
Install.WantedBy = [ "default.target" ];
|
||||
|
||||
Unit.Description = "OpenTTD Tmux server";
|
||||
|
||||
Service = {
|
||||
ExecStart = "${pkgs.tmux}/bin/tmux new -s OpenTTD -d '${pkgs.openttd}/bin/openttd -D'";
|
||||
ExecStop = "${pkgs.tmux}/bin/tmux kill-server";
|
||||
Restart = "on-failure";
|
||||
Type = "forking";
|
||||
};
|
||||
};
|
||||
}
|
31
specific/home-manager.nix
Normal file
31
specific/home-manager.nix
Normal file
|
@ -0,0 +1,31 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
#
|
||||
## HOME CONFIGURATION #
|
||||
#
|
||||
|
||||
# Import configurations for better modularity.
|
||||
imports = [
|
||||
../../modules/home-manager
|
||||
../../modules/home-manager/services.nix
|
||||
];
|
||||
|
||||
# Home Manager needs a bit of information about you and the paths it should
|
||||
# manage.
|
||||
home.username = "wizardlink";
|
||||
home.homeDirectory = "/home/wizardlink";
|
||||
|
||||
# This value determines the Home Manager release that your configuration is
|
||||
# compatible with. This helps avoid breakage when a new Home Manager release
|
||||
# introduces backwards incompatible changes.
|
||||
#
|
||||
# You should not change this value, even if you update Home Manager. If you do
|
||||
# want to update the value, then make sure to first check the Home Manager
|
||||
# release notes.
|
||||
home.stateVersion = "23.05"; # Please read the comment before changing.
|
||||
|
||||
home.sessionVariables = {
|
||||
EDITOR = "nvim";
|
||||
};
|
||||
}
|
28
specific/wizdesk/hardware.nix
Normal file
28
specific/wizdesk/hardware.nix
Normal file
|
@ -0,0 +1,28 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
# Enable Zenergy
|
||||
boot.extraModulePackages = [
|
||||
(pkgs.callPackage ../kernel/zenergy.nix { kernel = pkgs.linux_zen; })
|
||||
];
|
||||
|
||||
# Enable openrazer for managing Razer products' configuration
|
||||
hardware.openrazer = {
|
||||
enable = true;
|
||||
users = [ "wizardlink" ];
|
||||
};
|
||||
|
||||
services.udev = {
|
||||
# Vial udev rule for Monsgeek M1
|
||||
extraRules = ''
|
||||
# Monsgeek M1
|
||||
KERNEL=="hidraw*", SUBSYSTEM=="hidraw", ATTRS{idVendor}=="fffe", ATTRS{idProduct}=="0005", MODE="0660", GROUP="users", TAG+="uaccess", TAG+="udev-acl"
|
||||
'';
|
||||
|
||||
# WB32 DFU rules - needed for flashing
|
||||
packages = [ (pkgs.callPackage ./services/udev/wb32dfu.nix { }) ];
|
||||
};
|
||||
|
||||
# enable a better driver for wireless xbox controllers.
|
||||
hardware.xpadneo.enable = true;
|
||||
}
|
125
specific/wizdesk/nixos.nix
Normal file
125
specific/wizdesk/nixos.nix
Normal file
|
@ -0,0 +1,125 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./hardware.nix
|
||||
./services.nix
|
||||
];
|
||||
|
||||
# This value determines the NixOS release from which the default
|
||||
# settings for stateful data, like file locations and database versions
|
||||
# on your system were taken. It‘s perfectly fine and recommended to leave
|
||||
# this value at the release version of the first install of this system.
|
||||
# Before changing this value read the documentation for this option
|
||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
||||
system.stateVersion = "23.05";
|
||||
|
||||
# Configure options for mounted volumes.
|
||||
fileSystems = {
|
||||
"/".options = [ "compress=zstd" ];
|
||||
"/home".options = [ "compress=zstd" ];
|
||||
"/nix".options = [
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
];
|
||||
"/mnt/extra".options = [ "nofail" ];
|
||||
"/mnt/internal".options = [ "nofail" ];
|
||||
"/mnt/media".options = [ "nofail" ];
|
||||
"/mnt/ssd".options = [ "nofail" ];
|
||||
};
|
||||
|
||||
# Enable btrf's auto scrubbing of volumes.
|
||||
services.btrfs.autoScrub = {
|
||||
enable = true;
|
||||
interval = "weekly";
|
||||
fileSystems = [ "/" ];
|
||||
};
|
||||
|
||||
networking.hostName = "wizdesk"; # Define your hostname.
|
||||
|
||||
# Open ports in the firewall.
|
||||
networking.firewall = {
|
||||
allowedTCPPorts = [
|
||||
443 # SSL
|
||||
6567 # Mindustry
|
||||
80 # HTTP
|
||||
3979 # OpenTTD
|
||||
];
|
||||
|
||||
allowedUDPPorts = [
|
||||
2626 # Dolphin emulator
|
||||
27015 # Source games
|
||||
28910 # Heretic II
|
||||
6567 # Mindustry
|
||||
8211 # Palworld
|
||||
3979 # OpenTTD
|
||||
];
|
||||
|
||||
allowedTCPPortRanges = [
|
||||
{
|
||||
from = 1714;
|
||||
to = 1764;
|
||||
} # KDEConnect
|
||||
];
|
||||
allowedUDPPortRanges = [
|
||||
{
|
||||
from = 1714;
|
||||
to = 1764;
|
||||
} # KDEConnect
|
||||
];
|
||||
};
|
||||
|
||||
# Define a user account. Don't forget to set a password with ‘passwd’.
|
||||
users.users.wizardlink = {
|
||||
createHome = true;
|
||||
description = "Alexandre Cavalheiro";
|
||||
extraGroups = [
|
||||
"docker"
|
||||
"gamemode"
|
||||
"libvirtd"
|
||||
"networkmanager"
|
||||
"openrazer"
|
||||
"postgresql"
|
||||
"wheel"
|
||||
];
|
||||
|
||||
initialPassword = "wizardlink";
|
||||
isNormalUser = true;
|
||||
|
||||
openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDdGOyRbu6IOw9yqotxE6m7wCif7oP/2D0tlREa5Q6uo Alexandre Cavalheiro S. Tiago da Silva <contact@thewizard.link>"
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIISfCUsZrnCMZapdrvkUCrdRiX+1xuZBdGrynNRzDI2v" # SpaceEEC
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPInBFp7zBLhFluoww65CZzcnMdhndTawBv8QYJ5s/Xt david.alejandro.rubio@gmail.com" # Kodehawa
|
||||
];
|
||||
};
|
||||
|
||||
# Set your time zone.
|
||||
time.timeZone = "America/Sao_Paulo";
|
||||
|
||||
# Select internationalisation properties.
|
||||
i18n = {
|
||||
defaultLocale = "en_US.UTF-8";
|
||||
supportedLocales = [
|
||||
"C.UTF-8/UTF-8"
|
||||
"en_GB.UTF-8/UTF-8"
|
||||
"en_US.UTF-8/UTF-8"
|
||||
"ja_JP.UTF-8/UTF-8"
|
||||
"pt_BR.UTF-8/UTF-8"
|
||||
];
|
||||
|
||||
extraLocaleSettings = {
|
||||
LANGUAGE = "en_US.UTF-8";
|
||||
LC_ADDRESS = "en_US.UTF-8";
|
||||
LC_ALL = "en_US.UTF-8";
|
||||
LC_IDENTIFICATION = "en_US.UTF-8";
|
||||
LC_MEASUREMENT = "pt_BR.UTF-8";
|
||||
LC_MONETARY = "en_US.UTF-8";
|
||||
LC_NAME = "en_US.UTF-8";
|
||||
LC_NUMERIC = "pt_BR.UTF-8";
|
||||
LC_PAPER = "pt_BR.UTF-8";
|
||||
LC_TELEPHONE = "pt_BR.UTF-8";
|
||||
LC_TIME = "en_GB.UTF-8";
|
||||
};
|
||||
};
|
||||
}
|
20
specific/wizdesk/services.nix
Normal file
20
specific/wizdesk/services.nix
Normal file
|
@ -0,0 +1,20 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./services/archi.nix
|
||||
./services/caddy.nix
|
||||
./services/forgejo.nix
|
||||
./services/jellyfin.nix
|
||||
];
|
||||
|
||||
services.postgresql = {
|
||||
enable = true;
|
||||
|
||||
initialScript = pkgs.writeText "backend-initScript" ''
|
||||
CREATE ROLE wizardlink WITH LOGIN SUPERUSER PASSWORD 'wizardlink' CREATEDB CREATEROLE REPLICATION;
|
||||
CREATE DATABASE wizardlink;
|
||||
GRANT ALL PRIVILEGES ON DATABASE wizardlink TO wizardlink;
|
||||
'';
|
||||
};
|
||||
}
|
28
specific/wizdesk/services/forgejo.nix
Normal file
28
specific/wizdesk/services/forgejo.nix
Normal file
|
@ -0,0 +1,28 @@
|
|||
{
|
||||
services.forgejo = {
|
||||
enable = true;
|
||||
|
||||
lfs.enable = true;
|
||||
|
||||
settings = {
|
||||
server = {
|
||||
HTTP_PORT = 3788;
|
||||
LANDING_PAGE = "explore";
|
||||
ROOT_URL = "https://git.thewizard.link";
|
||||
};
|
||||
|
||||
ui = {
|
||||
# HACK: Unfortunately we need to manually put files in /var/lib/forgejo/custom/public/assets/css
|
||||
# so this will break in a new system.
|
||||
DEFAULT_THEME = "catppuccin-frappe-lavender";
|
||||
THEMES = "forgejo-auto,forgejo-light,forgejo-dark,gitea-auto,gitea-light,gitea-dark,forgejo-auto-deuteranopia-protanopia,forgejo-light-deuteranopia-protanopia,forgejo-dark-deuteranopia-protanopia,forgejo-auto-tritanopia,forgejo-light-tritanopia,forgejo-dark-tritanopia,catppuccin-latte-rosewater,catppuccin-latte-flamingo,catppuccin-latte-pink,catppuccin-latte-mauve,catppuccin-latte-red,catppuccin-latte-maroon,catppuccin-latte-peach,catppuccin-latte-yellow,catppuccin-latte-green,catppuccin-latte-teal,catppuccin-latte-sky,catppuccin-latte-sapphire,catppuccin-latte-blue,catppuccin-latte-lavender,catppuccin-frappe-rosewater,catppuccin-frappe-flamingo,catppuccin-frappe-pink,catppuccin-frappe-mauve,catppuccin-frappe-red,catppuccin-frappe-maroon,catppuccin-frappe-peach,catppuccin-frappe-yellow,catppuccin-frappe-green,catppuccin-frappe-teal,catppuccin-frappe-sky,catppuccin-frappe-sapphire,catppuccin-frappe-blue,catppuccin-frappe-lavender,catppuccin-macchiato-rosewater,catppuccin-macchiato-flamingo,catppuccin-macchiato-pink,catppuccin-macchiato-mauve,catppuccin-macchiato-red,catppuccin-macchiato-maroon,catppuccin-macchiato-peach,catppuccin-macchiato-yellow,catppuccin-macchiato-green,catppuccin-macchiato-teal,catppuccin-macchiato-sky,catppuccin-macchiato-sapphire,catppuccin-macchiato-blue,catppuccin-macchiato-lavender,catppuccin-mocha-rosewater,catppuccin-mocha-flamingo,catppuccin-mocha-pink,catppuccin-mocha-mauve,catppuccin-mocha-red,catppuccin-mocha-maroon,catppuccin-mocha-peach,catppuccin-mocha-yellow,catppuccin-mocha-green,catppuccin-mocha-teal,catppuccin-mocha-sky,catppuccin-mocha-sapphire,catppuccin-mocha-blue,catppuccin-mocha-lavender";
|
||||
};
|
||||
|
||||
service = {
|
||||
DISABLE_REGISTRATION = true;
|
||||
ENABLE_REVERSE_PROXY_AUTHENTICATION = true;
|
||||
ENABLE_REVERSE_PROXY_AUTHENTICATION_API = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
19
specific/wizdesk/services/udev/wb32dfu.nix
Normal file
19
specific/wizdesk/services/udev/wb32dfu.nix
Normal file
|
@ -0,0 +1,19 @@
|
|||
{
|
||||
stdenv,
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
pname = "wb32dfu-udev-rules";
|
||||
version = "0-unstable-2024-09-15";
|
||||
src = ./.;
|
||||
|
||||
dontBuild = true;
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
|
||||
install -D wb32dfu.rules $out/lib/udev/rules.d/50-wb32dfu.rules
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
}
|
2
specific/wizdesk/services/udev/wb32dfu.rules
Normal file
2
specific/wizdesk/services/udev/wb32dfu.rules
Normal file
|
@ -0,0 +1,2 @@
|
|||
# WB32 DFU
|
||||
SUBSYSTEMS=="usb", ATTRS{idVendor}=="342d", ATTRS{idProduct}=="dfa0", TAG+="uaccess"
|
11
specific/wizlap/hardware.nix
Normal file
11
specific/wizlap/hardware.nix
Normal file
|
@ -0,0 +1,11 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
# Enable Zenergy
|
||||
boot.extraModulePackages = [
|
||||
(pkgs.callPackage ../kernel/zenergy.nix { kernel = pkgs.linux_zen; })
|
||||
];
|
||||
|
||||
# enable a better driver for wireless xbox controllers.
|
||||
hardware.xpadneo.enable = true;
|
||||
}
|
78
specific/wizlap/nixos.nix
Normal file
78
specific/wizlap/nixos.nix
Normal file
|
@ -0,0 +1,78 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./hardware.nix
|
||||
];
|
||||
|
||||
networking.hostName = "wizlap"; # Define your hostname.
|
||||
|
||||
# Open ports in the firewall.
|
||||
networking.firewall = {
|
||||
allowedTCPPortRanges = [
|
||||
{
|
||||
from = 1714;
|
||||
to = 1764;
|
||||
} # KDEConnect
|
||||
];
|
||||
allowedUDPPortRanges = [
|
||||
{
|
||||
from = 1714;
|
||||
to = 1764;
|
||||
} # KDEConnect
|
||||
];
|
||||
};
|
||||
|
||||
# Define a user account. Don't forget to set a password with ‘passwd’.
|
||||
users.users.wizardlink = {
|
||||
createHome = true;
|
||||
description = "Alexandre Cavalheiro";
|
||||
extraGroups = [
|
||||
"docker"
|
||||
"gamemode"
|
||||
"libvirtd"
|
||||
"networkmanager"
|
||||
"openrazer"
|
||||
"postgresql"
|
||||
"wheel"
|
||||
];
|
||||
|
||||
initialPassword = "wizardlink";
|
||||
isNormalUser = true;
|
||||
|
||||
openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDdGOyRbu6IOw9yqotxE6m7wCif7oP/2D0tlREa5Q6uo Alexandre Cavalheiro S. Tiago da Silva <contact@thewizard.link>"
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIISfCUsZrnCMZapdrvkUCrdRiX+1xuZBdGrynNRzDI2v" # SpaceEEC
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPInBFp7zBLhFluoww65CZzcnMdhndTawBv8QYJ5s/Xt david.alejandro.rubio@gmail.com" # Kodehawa
|
||||
];
|
||||
};
|
||||
|
||||
# Set your time zone.
|
||||
time.timeZone = "America/Sao_Paulo";
|
||||
|
||||
# Select internationalisation properties.
|
||||
i18n = {
|
||||
defaultLocale = "en_US.UTF-8";
|
||||
supportedLocales = [
|
||||
"C.UTF-8/UTF-8"
|
||||
"en_GB.UTF-8/UTF-8"
|
||||
"en_US.UTF-8/UTF-8"
|
||||
"ja_JP.UTF-8/UTF-8"
|
||||
"pt_BR.UTF-8/UTF-8"
|
||||
];
|
||||
|
||||
extraLocaleSettings = {
|
||||
LANGUAGE = "en_US.UTF-8";
|
||||
LC_ADDRESS = "en_US.UTF-8";
|
||||
LC_ALL = "en_US.UTF-8";
|
||||
LC_IDENTIFICATION = "en_US.UTF-8";
|
||||
LC_MEASUREMENT = "pt_BR.UTF-8";
|
||||
LC_MONETARY = "en_US.UTF-8";
|
||||
LC_NAME = "en_US.UTF-8";
|
||||
LC_NUMERIC = "pt_BR.UTF-8";
|
||||
LC_PAPER = "pt_BR.UTF-8";
|
||||
LC_TELEPHONE = "pt_BR.UTF-8";
|
||||
LC_TIME = "en_GB.UTF-8";
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Reference in a new issue