Compare commits
96 commits
structure-
...
main
Author | SHA1 | Date | |
---|---|---|---|
89f8637d03 | |||
9c74203ac1 | |||
2461a8a2c4 | |||
de6052693e | |||
acf42ca5e7 | |||
2603bf2b6f | |||
81c56877e6 | |||
e6cebabb48 | |||
7871b52a2f | |||
5344331bd4 | |||
8e156427d3 | |||
3a8435a8e3 | |||
5d1025644a | |||
957c49ef33 | |||
c168c8260a | |||
2919138fdf | |||
7828a1256b | |||
76862fbfdd | |||
3c1c71dce8 | |||
c32efcce18 | |||
0ecde1fc3c | |||
9fc5686078 | |||
b1dc9b3bdb | |||
f65911a876 | |||
1b25c927fb | |||
c1871c4310 | |||
7f9715af40 | |||
82d7029260 | |||
6af72ca39e | |||
2b89ed8b73 | |||
2d9df00fae | |||
edcf8e5010 | |||
f4507bc88d | |||
dc70f42c87 | |||
23c19987a3 | |||
8967b25c80 | |||
e0c277bf1e | |||
4576b30efa | |||
065266ee3a | |||
4ccd29cb9d | |||
af13f204ad | |||
5f1221d85b | |||
e02d77a025 | |||
0bc8a83fd3 | |||
8136d53ad7 | |||
cd4cc631a4 | |||
1e3d9b2f75 | |||
b5986f0c33 | |||
944c99f873 | |||
678a0c007d | |||
7a9d641995 | |||
9e5f6d2c85 | |||
4efda26046 | |||
ebfa07b72a | |||
d83faa96c4 | |||
fe83d5f557 | |||
1dc4024973 | |||
c06597fe7f | |||
408750a151 | |||
46542a2c19 | |||
210ed38295 | |||
10d313f33a | |||
c9b19c3b5f | |||
9293020602 | |||
b84157c771 | |||
077ec7b242 | |||
4430c88d43 | |||
b10f86de80 | |||
7ff03271d7 | |||
5348e741e8 | |||
cbf2ed3b10 | |||
73c25e55e9 | |||
d212c13635 | |||
21d45256fe | |||
fdefee324e | |||
61bc1ea56d | |||
0eab12a13f | |||
089a3363ba | |||
69dac78c20 | |||
52e584ee0b | |||
c5c201ec38 | |||
e71cf34700 | |||
852b3e1f78 | |||
9f0cdf9f98 | |||
ec2bce3b55 | |||
ae60854247 | |||
26845938e7 | |||
cc7eec6a81 | |||
fb51921f26 | |||
c7d09bcd5b | |||
bc7de34c43 | |||
1f1183fa4d | |||
e2bcffa79e | |||
1b4b665b2b | |||
c4897af672 | |||
390691be57 |
221 changed files with 5256 additions and 4262 deletions
1
.envrc
1
.envrc
|
@ -1 +0,0 @@
|
|||
use flake .
|
25
README.md
25
README.md
|
@ -1,34 +1,36 @@
|
|||
# ❄️ flocon
|
||||
<h1 id="header" align="center">
|
||||
<img src="assets/nix-snowflake-colors.svg" width="128px" height="128px" />
|
||||
<br>
|
||||
flocon
|
||||
</h1>
|
||||
|
||||
My NixOS configurations, using flakes.
|
||||
|
||||
# </> Software I use
|
||||
|
||||
- Wayland compositor: [niri](https://github.com/YaLTeR/niri)
|
||||
- Wayland compositor: [Hyprland](https://github.com/hyprwm/Hyprland)
|
||||
- Text editor: [neovim](https://github.com/neovim/neovim)
|
||||
- Shell: [fish](https://github.com/fish-shell/fish-shell)
|
||||
- Colors: [Catppuccin](https://github.com/catppuccin/catppuccin)
|
||||
- Font: [Intel One Mono](https://github.com/intel/intel-one-mono)
|
||||
|
||||
Additionally using a lot of other software you can find in the configuration files.
|
||||
|
||||
# 🛠️ Structure
|
||||
|
||||
| Name | Description |
|
||||
| ------------------- | -------------------------- |
|
||||
| [home](home/) | Home manager configuration |
|
||||
| ----------------- | ------------------------------------------------------------- |
|
||||
| [assets](assets/) | Resources used throughout the system (images etc.) |
|
||||
| [config](config/) | System configuration (separated between NixOS / home-manager) |
|
||||
| [hosts](hosts/) | Host-specific |
|
||||
| [lib](lib/) | Helper functions |
|
||||
| [modules](modules/) | NixOS modules |
|
||||
| [pkgs](pkgs/) | Custom packages |
|
||||
| [system](system/) | NixOS configuration |
|
||||
| [shared](shared/) | Re-used components (internal modules, custom derivations) |
|
||||
|
||||
My configuration is structured based on the following principles:
|
||||
|
||||
1. Hosts should be the main entry points and outputs.
|
||||
2. Abstractions should be avoided as much as possible.
|
||||
3. Setting up theming should be as simple as changing one or two options.
|
||||
|
||||
The bulk of the configuration can be found either in [home](home/) or [system](system/), which declares most of my programs, with some extra Nix code in [lib](lib/) and custom [modules](modules/), mostly for convenience and to provide a way to globally set styles and themes for now.
|
||||
The main configuration can be found in [config](config/), which declares most of my programs, with re-usable modules and derivations in [shared](shared/), to provide a way to globally set themes, usernames and more.
|
||||
|
||||
My hosts can then pick and choose the programs and configurations that they need from the other directories. If the need arises for a more modular setup for a specific piece of software (ie. having different flavors of Firefox per host), I will write a custom module for it. This helps to avoid unnecessarily abstracting my configuration, as I don't find it necessary for the most part, and I would also like it to remain as simple as possible.
|
||||
|
||||
|
@ -39,5 +41,6 @@ People / repositories I have copied / learned from:
|
|||
- [fufexan/dotfiles](https://github.com/fufexan/dotfiles) for the configuration structure
|
||||
- [jacekpoz/nixos](https://git.jacekpoz.pl/poz/niksos) for learning how NixOS modules work
|
||||
- [sodiboo](https://github.com/sodiboo) for helping me a whole lot with Niri-specific issues
|
||||
- [llakala](https://github.com/llakala) for being very thorough and helpful when cleaning up my code and general structure.
|
||||
|
||||
Some bits have also been borrowed from within the configuration, and credit has been given where its due.
|
||||
Some bits have also been borrowed from within the configuration, and credit has been given where its due.
|
||||
|
|
187
assets/nix-snowflake-colors.svg
Normal file
187
assets/nix-snowflake-colors.svg
Normal file
|
@ -0,0 +1,187 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||
|
||||
<svg
|
||||
width="535"
|
||||
height="535"
|
||||
viewBox="0 0 501.56251 501.56249"
|
||||
id="svg2"
|
||||
version="1.1"
|
||||
inkscape:version="1.3.2 (091e20ef0f, 2023-11-25)"
|
||||
sodipodi:docname="nix-snowflake-colours.svg"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/">
|
||||
<defs
|
||||
id="defs4">
|
||||
<linearGradient
|
||||
inkscape:collect="always"
|
||||
id="linearGradient5562">
|
||||
<stop
|
||||
style="stop-color:#699ad7;stop-opacity:1"
|
||||
offset="0"
|
||||
id="stop5564" />
|
||||
<stop
|
||||
id="stop5566"
|
||||
offset="0.24345198"
|
||||
style="stop-color:#7eb1dd;stop-opacity:1" />
|
||||
<stop
|
||||
style="stop-color:#7ebae4;stop-opacity:1"
|
||||
offset="1"
|
||||
id="stop5568" />
|
||||
</linearGradient>
|
||||
<linearGradient
|
||||
inkscape:collect="always"
|
||||
id="linearGradient5053">
|
||||
<stop
|
||||
style="stop-color:#415e9a;stop-opacity:1"
|
||||
offset="0"
|
||||
id="stop5055" />
|
||||
<stop
|
||||
id="stop5057"
|
||||
offset="0.23168644"
|
||||
style="stop-color:#4a6baf;stop-opacity:1" />
|
||||
<stop
|
||||
style="stop-color:#5277c3;stop-opacity:1"
|
||||
offset="1"
|
||||
id="stop5059" />
|
||||
</linearGradient>
|
||||
<linearGradient
|
||||
inkscape:collect="always"
|
||||
xlink:href="#linearGradient5562"
|
||||
id="linearGradient4328"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
gradientTransform="translate(70.650339,-1055.1511)"
|
||||
x1="200.59668"
|
||||
y1="351.41116"
|
||||
x2="290.08701"
|
||||
y2="506.18814" />
|
||||
<linearGradient
|
||||
inkscape:collect="always"
|
||||
xlink:href="#linearGradient5053"
|
||||
id="linearGradient4330"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
gradientTransform="translate(864.69589,-1491.3405)"
|
||||
x1="-584.19934"
|
||||
y1="782.33563"
|
||||
x2="-496.29703"
|
||||
y2="937.71399" />
|
||||
</defs>
|
||||
<sodipodi:namedview
|
||||
id="base"
|
||||
pagecolor="#ffffff"
|
||||
bordercolor="#666666"
|
||||
borderopacity="1.0"
|
||||
inkscape:pageopacity="0.0"
|
||||
inkscape:pageshadow="2"
|
||||
inkscape:zoom="0.70904368"
|
||||
inkscape:cx="99.429699"
|
||||
inkscape:cy="195.33352"
|
||||
inkscape:document-units="px"
|
||||
inkscape:current-layer="layer3"
|
||||
showgrid="false"
|
||||
inkscape:window-width="1920"
|
||||
inkscape:window-height="1050"
|
||||
inkscape:window-x="1920"
|
||||
inkscape:window-y="30"
|
||||
inkscape:window-maximized="1"
|
||||
inkscape:snap-global="true"
|
||||
fit-margin-top="0"
|
||||
fit-margin-left="0"
|
||||
fit-margin-right="0"
|
||||
fit-margin-bottom="0"
|
||||
inkscape:showpageshadow="2"
|
||||
inkscape:pagecheckerboard="0"
|
||||
inkscape:deskcolor="#d1d1d1" />
|
||||
<metadata
|
||||
id="metadata7">
|
||||
<rdf:RDF>
|
||||
<cc:Work
|
||||
rdf:about="">
|
||||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
</cc:Work>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<g
|
||||
inkscape:groupmode="layer"
|
||||
id="layer3"
|
||||
inkscape:label="gradient-logo"
|
||||
style="display:inline;opacity:1"
|
||||
transform="translate(-156.41121,933.30685)">
|
||||
<g
|
||||
id="g2"
|
||||
transform="matrix(0.99994059,0,0,0.99994059,-0.06321798,33.188377)"
|
||||
style="stroke-width:1.00006">
|
||||
<path
|
||||
sodipodi:nodetypes="cccccccccc"
|
||||
inkscape:connector-curvature="0"
|
||||
id="path3336-6"
|
||||
d="m 309.54892,-710.38827 122.19683,211.67512 -56.15706,0.5268 -32.6236,-56.8692 -32.85645,56.5653 -27.90237,-0.011 -14.29086,-24.6896 46.81047,-80.4901 -33.22946,-57.8257 z"
|
||||
style="opacity:1;fill:url(#linearGradient4328);fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:3.00018;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" />
|
||||
<use
|
||||
height="100%"
|
||||
width="100%"
|
||||
transform="rotate(60,407.11155,-715.78724)"
|
||||
id="use3439-6"
|
||||
inkscape:transform-center-y="151.59082"
|
||||
inkscape:transform-center-x="124.43045"
|
||||
xlink:href="#path3336-6"
|
||||
y="0"
|
||||
x="0"
|
||||
style="stroke-width:1.00006" />
|
||||
<use
|
||||
height="100%"
|
||||
width="100%"
|
||||
transform="rotate(-60,407.31177,-715.70016)"
|
||||
id="use3445-0"
|
||||
inkscape:transform-center-y="75.573958"
|
||||
inkscape:transform-center-x="-168.20651"
|
||||
xlink:href="#path3336-6"
|
||||
y="0"
|
||||
x="0"
|
||||
style="stroke-width:1.00006" />
|
||||
<use
|
||||
height="100%"
|
||||
width="100%"
|
||||
transform="rotate(180,407.41868,-715.7565)"
|
||||
id="use3449-5"
|
||||
inkscape:transform-center-y="-139.94592"
|
||||
inkscape:transform-center-x="59.669705"
|
||||
xlink:href="#path3336-6"
|
||||
y="0"
|
||||
x="0"
|
||||
style="stroke-width:1.00006" />
|
||||
<path
|
||||
style="color:#000000;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill:url(#linearGradient4330);fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:3.00018;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate"
|
||||
d="m 309.54892,-710.38827 122.19683,211.67512 -56.15706,0.5268 -32.6236,-56.8692 -32.85645,56.5653 -27.90237,-0.011 -14.29086,-24.6896 46.81047,-80.4901 -33.22946,-57.8256 z"
|
||||
id="path4260-0"
|
||||
inkscape:connector-curvature="0"
|
||||
sodipodi:nodetypes="cccccccccc" />
|
||||
<use
|
||||
height="100%"
|
||||
width="100%"
|
||||
transform="rotate(120,407.33916,-716.08356)"
|
||||
id="use4354-5"
|
||||
xlink:href="#path4260-0"
|
||||
y="0"
|
||||
x="0"
|
||||
style="display:inline;stroke-width:1.00006" />
|
||||
<use
|
||||
height="100%"
|
||||
width="100%"
|
||||
transform="rotate(-120,407.28823,-715.86995)"
|
||||
id="use4362-2"
|
||||
xlink:href="#path4260-0"
|
||||
y="0"
|
||||
x="0"
|
||||
style="display:inline;stroke-width:1.00006" />
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 6.4 KiB |
BIN
assets/wallpapers/nixos-tan-hypr-chan.png
Normal file
BIN
assets/wallpapers/nixos-tan-hypr-chan.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 4.7 MiB |
1244
flake.lock
1244
flake.lock
File diff suppressed because it is too large
Load diff
52
flake.nix
52
flake.nix
|
@ -4,13 +4,12 @@
|
|||
outputs = {
|
||||
self,
|
||||
nixpkgs,
|
||||
systems,
|
||||
agenix,
|
||||
deploy-rs,
|
||||
treefmt-nix,
|
||||
...
|
||||
} @ inputs: let
|
||||
eachSystem = f: nixpkgs.lib.genAttrs (import systems) (system: f nixpkgs.legacyPackages.${system});
|
||||
eachSystem = f: nixpkgs.lib.genAttrs nixpkgs.lib.systems.flakeExposed (system: f nixpkgs.legacyPackages.${system});
|
||||
treefmtEval = eachSystem (pkgs: treefmt-nix.lib.evalModule pkgs ./treefmt.nix);
|
||||
in {
|
||||
devShells = eachSystem (pkgs: {
|
||||
|
@ -24,15 +23,14 @@
|
|||
};
|
||||
});
|
||||
formatter = eachSystem (pkgs: treefmtEval.${pkgs.system}.config.build.wrapper);
|
||||
nixosConfigurations = import ./hosts {inherit inputs;};
|
||||
packages = eachSystem (pkgs: import ./pkgs {inherit inputs pkgs;});
|
||||
deploy.nodes = import ./nodes {inherit inputs;};
|
||||
nixosConfigurations = import ./hosts {inherit self inputs;};
|
||||
packages = eachSystem (pkgs: import ./shared/pkgs {inherit inputs pkgs;});
|
||||
deploy.nodes = import ./nodes.nix {inherit inputs;};
|
||||
checks = builtins.mapAttrs (_: deployLib: deployLib.deployChecks self.deploy) deploy-rs.lib;
|
||||
};
|
||||
inputs = {
|
||||
# nix related
|
||||
nixpkgs.url = "nixpkgs/nixos-unstable";
|
||||
systems.url = "github:nix-systems/default-linux";
|
||||
nixos-hardware.url = "github:NixOS/nixos-hardware";
|
||||
lanzaboote = {
|
||||
url = "github:nix-community/lanzaboote/v0.4.1";
|
||||
|
@ -58,31 +56,71 @@
|
|||
url = "gitlab:rycee/nur-expressions?dir=pkgs/firefox-addons";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
hyprland.url = "github:hyprwm/Hyprland";
|
||||
hyprland-qtutils = {
|
||||
url = "github:hyprwm/hyprland-qtutils";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
hypridle = {
|
||||
url = "github:hyprwm/hypridle";
|
||||
inputs = {
|
||||
hyprlang.follows = "hyprland/hyprlang";
|
||||
hyprutils.follows = "hyprland/hyprutils";
|
||||
nixpkgs.follows = "hyprland/nixpkgs";
|
||||
systems.follows = "hyprland/systems";
|
||||
};
|
||||
};
|
||||
hyprlock = {
|
||||
url = "github:hyprwm/hyprlock";
|
||||
inputs = {
|
||||
hyprlang.follows = "hyprland/hyprlang";
|
||||
hyprutils.follows = "hyprland/hyprutils";
|
||||
nixpkgs.follows = "hyprland/nixpkgs";
|
||||
systems.follows = "hyprland/systems";
|
||||
};
|
||||
};
|
||||
hyprpaper = {
|
||||
url = "github:hyprwm/hyprpaper";
|
||||
inputs = {
|
||||
hyprlang.follows = "hyprland/hyprlang";
|
||||
hyprutils.follows = "hyprland/hyprutils";
|
||||
nixpkgs.follows = "hyprland/nixpkgs";
|
||||
systems.follows = "hyprland/systems";
|
||||
};
|
||||
};
|
||||
hyprwm-contrib = {
|
||||
url = "github:hyprwm/contrib";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
niri.url = "github:sodiboo/niri-flake";
|
||||
nix-flatpak.url = "github:gmodena/nix-flatpak/?ref=v0.5.0";
|
||||
nix-gaming.url = "github:fufexan/nix-gaming";
|
||||
nvf.url = "github:notashelf/nvf";
|
||||
portfolio.url = "github:nezia1/portfolio";
|
||||
plasma-manager = {
|
||||
url = "github:nix-community/plasma-manager";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
inputs.home-manager.follows = "home-manager";
|
||||
};
|
||||
treefmt-nix.url = "github:numtide/treefmt-nix";
|
||||
walker.url = "github:abenz1267/walker";
|
||||
nezia_dev.url = "github:nezia1/nezia.dev";
|
||||
};
|
||||
nixConfig = {
|
||||
extra-substituters = [
|
||||
# use nixos cache first
|
||||
"https://cache.nixos.org?priority=10"
|
||||
"https://hyprland.cachix.org"
|
||||
"https://nix-gaming.cachix.org"
|
||||
"https://walker.cachix.org"
|
||||
"https://walker-git.cachix.org"
|
||||
];
|
||||
extra-trusted-public-keys = [
|
||||
"cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY="
|
||||
"hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="
|
||||
"nix-gaming.cachix.org-1:nbjlureqMbRAxR1gJ/f3hxemL9svXaZF/Ees8vCUUs4="
|
||||
"walker-git.cachix.org-1:vmC0ocfPWh0S/vRAQGtChuiZBTAe4wiKDeyyXM0/7pM="
|
||||
];
|
||||
};
|
||||
}
|
||||
|
|
|
@ -1,14 +0,0 @@
|
|||
{
|
||||
imports = [
|
||||
./services/udiskie.nix
|
||||
./terminal
|
||||
./programs
|
||||
];
|
||||
home = {
|
||||
username = "nezia";
|
||||
homeDirectory = "/home/nezia";
|
||||
stateVersion = "24.05";
|
||||
};
|
||||
|
||||
programs.home-manager.enable = true;
|
||||
}
|
|
@ -1,172 +0,0 @@
|
|||
{
|
||||
inputs,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
betterfox = pkgs.fetchFromGitHub {
|
||||
owner = "yokoffing";
|
||||
repo = "betterfox";
|
||||
rev = "e026ed7d3a763c5d3f96c2680d7bc3340831af4f";
|
||||
hash = "sha256-hpkEO5BhMVtINQG8HN4xqfas/R6q5pYPZiFK8bilIDs=";
|
||||
};
|
||||
in {
|
||||
programs.firefox = {
|
||||
enable = true;
|
||||
package = pkgs.wrapFirefox pkgs.firefox-unwrapped {
|
||||
extraPolicies = {
|
||||
DisableTelemetry = true;
|
||||
DisablePocket = true;
|
||||
DisableFeedbackCommands = true;
|
||||
DisableFirefoxStudies = true;
|
||||
OfferToSaveLogins = false;
|
||||
OffertosaveloginsDefault = false;
|
||||
PasswordManagerEnabled = false;
|
||||
SearchSuggestEnabled = true;
|
||||
|
||||
# https://github.com/Sly-Harvey/NixOS/blob/f9da2691ea46565256ad757959cfc26ec6cee10d/modules/programs/browser/firefox/default.nix#L58-L163
|
||||
"3rdparty".Extensions = {
|
||||
"addon@darkreader.org" = {
|
||||
permissions = ["internal:privateBrowsingAllowed"];
|
||||
enabled = true;
|
||||
automation = {
|
||||
enabled = true;
|
||||
behavior = "OnOff";
|
||||
mode = "system";
|
||||
};
|
||||
detectDarkTheme = true;
|
||||
enabledByDefault = true;
|
||||
changeBrowserTheme = false;
|
||||
enableForProtectedPages = true;
|
||||
fetchNews = false;
|
||||
previewNewDesign = true;
|
||||
};
|
||||
"uBlock0@raymondhill.net" = {
|
||||
permissions = ["internal:privateBrowsingAllowed"];
|
||||
advancedSettings = [
|
||||
[
|
||||
"userResourcesLocation"
|
||||
"https://raw.githubusercontent.com/pixeltris/TwitchAdSolutions/master/video-swap-new/video-swap-new-ublock-origin.js"
|
||||
]
|
||||
];
|
||||
adminSettings = {
|
||||
userSettings = {
|
||||
uiTheme = "dark";
|
||||
advancedUserEnabled = true;
|
||||
userFiltersTrusted = true;
|
||||
importedLists = [
|
||||
"https://raw.githubusercontent.com/laylavish/uBlockOrigin-HUGE-AI-Blocklist/main/list.txt"
|
||||
];
|
||||
selectedFilterLists = [
|
||||
"FRA-0"
|
||||
"adguard-cookies"
|
||||
"adguard-mobile-app-banners"
|
||||
"adguard-other-annoyances"
|
||||
"adguard-popup-overlays"
|
||||
"adguard-social"
|
||||
"adguard-spyware-url"
|
||||
"adguard-widgets"
|
||||
"easylist"
|
||||
"easylist-annoyances"
|
||||
"easylist-chat"
|
||||
"easylist-newsletters"
|
||||
"easylist-notifications"
|
||||
"easyprivacy"
|
||||
"fanboy-cookiemonster"
|
||||
"https://filters.adtidy.org/extension/ublock/filters/3.txt"
|
||||
"https://github.com/DandelionSprout/adfilt/raw/master/LegitimateURLShortener.txt"
|
||||
"plowe-0"
|
||||
"ublock-annoyances"
|
||||
"ublock-badware"
|
||||
"ublock-cookies-adguard"
|
||||
"ublock-cookies-easylist"
|
||||
"ublock-filters"
|
||||
"ublock-privacy"
|
||||
"ublock-quick-fixes"
|
||||
"ublock-unbreak"
|
||||
"urlhaus-1"
|
||||
"https://raw.githubusercontent.com/laylavish/uBlockOrigin-HUGE-AI-Blocklist/main/list.txt"
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
profiles = {
|
||||
nezia = {
|
||||
settings = {
|
||||
"browser.search.suggest.enabled" = true;
|
||||
"ui.key.menuAccessKeyFocuses" = false;
|
||||
};
|
||||
|
||||
extensions = with inputs.firefox-addons.packages.${pkgs.system}; [
|
||||
darkreader
|
||||
proton-pass
|
||||
shinigami-eyes
|
||||
stylus
|
||||
ublock-origin
|
||||
violentmonkey
|
||||
];
|
||||
# https://git.jacekpoz.pl/poz/niksos/src/commit/a48647a1c5bc6877a1100a65f4dc169b2fc11ed7/hosts/hape/firefox.nix
|
||||
search = {
|
||||
force = true;
|
||||
default = "SearxNG";
|
||||
engines = {
|
||||
"SearxNG" = {
|
||||
urls = [
|
||||
{
|
||||
rels = ["results"];
|
||||
template = "https://search.nezia.dev/search";
|
||||
params = [
|
||||
{
|
||||
name = "q";
|
||||
value = "{searchTerms}";
|
||||
}
|
||||
];
|
||||
}
|
||||
{
|
||||
rels = ["suggestions"];
|
||||
template = "https://search.nezia.dev/autocompleter";
|
||||
params = [
|
||||
{
|
||||
name = "q";
|
||||
value = "{searchTerms}";
|
||||
}
|
||||
];
|
||||
"type" = "application/x-suggestions+json";
|
||||
}
|
||||
];
|
||||
};
|
||||
"MyNixOS" = {
|
||||
urls = [{template = "https://mynixos.com/search?q={searchTerms}";}];
|
||||
iconUpdateURL = "https://mynixos.com/favicon.ico";
|
||||
updateInterval = 24 * 60 * 60 * 1000;
|
||||
definedAliases = ["@nx"];
|
||||
};
|
||||
"Noogle" = {
|
||||
urls = [{template = "https://noogle.dev/q?term={searchTerms}";}];
|
||||
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
|
||||
definedAliases = ["@ng"];
|
||||
};
|
||||
"GitHub Nix" = {
|
||||
# https://github.com/search?q=language%3Anix+NOT+is%3Afork+programs.neovim&type=code
|
||||
urls = [{template = "https://github.com/search?q=language:nix NOT is:fork {searchTerms}&type=code";}];
|
||||
iconUpdateURL = "https://github.com/favicon.ico";
|
||||
updateInterval = 24 * 60 * 60 * 1000;
|
||||
definedAliases = ["@ghn"];
|
||||
};
|
||||
"Google".metaData.alias = "@g"; # builtin engines only support specifying one additional alias
|
||||
};
|
||||
};
|
||||
# https://github.com/oddlama/nix-config/blob/main/users/myuser/graphical/firefox.nix#L53-L57
|
||||
extraConfig = builtins.concatStringsSep "\n" [
|
||||
(builtins.readFile "${betterfox}/user.js")
|
||||
(builtins.readFile "${betterfox}/Securefox.js")
|
||||
(builtins.readFile "${betterfox}/Fastfox.js")
|
||||
(builtins.readFile "${betterfox}/Peskyfox.js")
|
||||
(builtins.readFile "${betterfox}/Smoothfox.js")
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,44 +0,0 @@
|
|||
{pkgs, ...}: {
|
||||
imports = [
|
||||
./browsers
|
||||
./media
|
||||
./xdg.nix
|
||||
./editors/helix.nix
|
||||
];
|
||||
|
||||
# idk where to put this
|
||||
programs = {
|
||||
fzf.enable = true;
|
||||
fastfetch.enable = true;
|
||||
hyfetch = {
|
||||
enable = true;
|
||||
settings = {
|
||||
preset = "nonbinary";
|
||||
mode = "rgb";
|
||||
backend = "fastfetch";
|
||||
color_align.mode = "horizontal";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
# miscellaneous programs that do not need to be configured
|
||||
home.packages = with pkgs; [
|
||||
cinny-desktop
|
||||
entr
|
||||
equibop
|
||||
fractal
|
||||
geary
|
||||
gnome-control-center
|
||||
gns3-gui
|
||||
gns3-server
|
||||
imhex
|
||||
logisim-evolution
|
||||
mission-center
|
||||
nautilus
|
||||
obsidian
|
||||
playerctl
|
||||
proton-pass
|
||||
simple-scan
|
||||
wl-clipboard
|
||||
];
|
||||
}
|
|
@ -1,61 +0,0 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
programs.helix = {
|
||||
enable = true;
|
||||
settings = {
|
||||
theme = "catppuccin_macchiato";
|
||||
editor = {
|
||||
line-number = "relative";
|
||||
lsp.display-messages = true;
|
||||
auto-format = true;
|
||||
auto-completion = true;
|
||||
completion-timeout = 5;
|
||||
color-modes = true;
|
||||
completion-trigger-len = 1;
|
||||
completion-replace = true;
|
||||
cursorline = true;
|
||||
cursor-shape = {
|
||||
insert = "bar";
|
||||
normal = "block";
|
||||
select = "underline";
|
||||
};
|
||||
indent-guides.render = true;
|
||||
lsp.display-inlay-hints = true;
|
||||
statusline.center = ["position-percentage"];
|
||||
true-color = true;
|
||||
whitespace.characters = {
|
||||
newline = "↴";
|
||||
tab = "⇥";
|
||||
};
|
||||
};
|
||||
|
||||
keys.normal = {
|
||||
space = {
|
||||
space = "file_picker";
|
||||
w = ":w";
|
||||
q = ":q";
|
||||
};
|
||||
esc = ["collapse_selection" "keep_primary_selection"];
|
||||
};
|
||||
};
|
||||
|
||||
languages = {
|
||||
language = [
|
||||
{
|
||||
name = "nix";
|
||||
auto-format = true;
|
||||
}
|
||||
];
|
||||
|
||||
language-server = {
|
||||
nil = {
|
||||
command = lib.getExe pkgs.nil;
|
||||
config.nil.formatting.command = ["${lib.getExe pkgs.alejandra}" "-q"];
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,241 +0,0 @@
|
|||
{
|
||||
inputs,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
imports = [inputs.nvf.homeManagerModules.default];
|
||||
|
||||
programs.nvf = {
|
||||
enable = true;
|
||||
settings.vim = {
|
||||
viAlias = true;
|
||||
vimAlias = true;
|
||||
enableLuaLoader = true;
|
||||
preventJunkFiles = true;
|
||||
useSystemClipboard = true;
|
||||
options = {
|
||||
tabstop = 4;
|
||||
autoindent = false;
|
||||
};
|
||||
|
||||
luaConfigPost = ''
|
||||
vim.opt.formatoptions:remove('c')
|
||||
vim.opt.formatoptions:remove('r')
|
||||
vim.opt.formatoptions:remove('o')
|
||||
'';
|
||||
|
||||
maps = {
|
||||
normal = {
|
||||
"<leader>m" = {
|
||||
silent = true;
|
||||
action = "<cmd>make<CR>";
|
||||
}; # Same as nnoremap <leader>m <silent> <cmd>make<CR>
|
||||
"<leader>t" = {
|
||||
silent = true;
|
||||
action = "<cmd>Neotree toggle<CR>";
|
||||
};
|
||||
};
|
||||
};
|
||||
theme = lib.mkDefault {
|
||||
enable = true;
|
||||
name = "catppuccin";
|
||||
style = "macchiato";
|
||||
};
|
||||
|
||||
ui = {
|
||||
noice.enable = true;
|
||||
};
|
||||
notify.nvim-notify.enable = true;
|
||||
|
||||
statusline = {
|
||||
lualine = {
|
||||
enable = true;
|
||||
theme = "auto";
|
||||
componentSeparator = {
|
||||
left = "";
|
||||
};
|
||||
sectionSeparator = {
|
||||
left = "";
|
||||
right = "";
|
||||
};
|
||||
|
||||
activeSection = {
|
||||
a = [
|
||||
''
|
||||
{
|
||||
"mode",
|
||||
separator = { right = "" },
|
||||
right_padding = 2
|
||||
}
|
||||
''
|
||||
];
|
||||
b = [
|
||||
''
|
||||
{
|
||||
"branch",
|
||||
icon = '',
|
||||
separator = { right = "" }
|
||||
}
|
||||
''
|
||||
];
|
||||
c = [
|
||||
''
|
||||
"filename"
|
||||
''
|
||||
];
|
||||
x = [
|
||||
''
|
||||
{
|
||||
"diagnostics",
|
||||
sources = {'nvim_lsp', 'nvim_diagnostic', 'nvim_diagnostic', 'vim_lsp', 'coc'},
|
||||
symbols = {error = ' ', warn = ' ', info = ' ', hint = ' '},
|
||||
colored = true,
|
||||
update_in_insert = false,
|
||||
always_visible = false,
|
||||
diagnostics_color = {
|
||||
color_error = { fg = 'red' },
|
||||
color_warn = { fg = 'yellow' },
|
||||
color_info = { fg = 'cyan' },
|
||||
},
|
||||
}
|
||||
''
|
||||
''
|
||||
"filetype"
|
||||
''
|
||||
];
|
||||
y = [
|
||||
''
|
||||
{
|
||||
"progress",
|
||||
separator = { left = "" },
|
||||
}
|
||||
''
|
||||
''
|
||||
''
|
||||
];
|
||||
z = [
|
||||
''
|
||||
{
|
||||
"location",
|
||||
separator = { left = "" },
|
||||
left_padding = 2
|
||||
}
|
||||
''
|
||||
''
|
||||
{
|
||||
"fileformat",
|
||||
color = {fg='black'},
|
||||
symbols = {
|
||||
unix = '', -- e712
|
||||
dos = '', -- e70f
|
||||
mac = '', -- e711
|
||||
},
|
||||
}
|
||||
''
|
||||
];
|
||||
};
|
||||
|
||||
inactiveSection = {
|
||||
a = [
|
||||
''
|
||||
"filename"
|
||||
''
|
||||
];
|
||||
z = [
|
||||
''
|
||||
"location"
|
||||
''
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
git.enable = true;
|
||||
|
||||
utility = {
|
||||
vim-wakatime.enable = true;
|
||||
};
|
||||
|
||||
lsp = {
|
||||
enable = true;
|
||||
lspSignature.enable = true;
|
||||
lspconfig.enable = true;
|
||||
formatOnSave = true;
|
||||
mappings = {
|
||||
addWorkspaceFolder = "<leader>wa";
|
||||
codeAction = "<leader>a";
|
||||
goToDeclaration = "gD";
|
||||
goToDefinition = "gd";
|
||||
hover = "K";
|
||||
listImplementations = "gi";
|
||||
listReferences = "gr";
|
||||
listWorkspaceFolders = "<leader>wl";
|
||||
nextDiagnostic = "<leader>k";
|
||||
previousDiagnostic = "<leader>j";
|
||||
openDiagnosticFloat = "<leader>e";
|
||||
removeWorkspaceFolder = "<leader>wr";
|
||||
renameSymbol = "<leader>r";
|
||||
signatureHelp = "<C-k>";
|
||||
};
|
||||
};
|
||||
|
||||
autocomplete.nvim-cmp = {
|
||||
enable = true;
|
||||
};
|
||||
|
||||
autopairs.nvim-autopairs.enable = true;
|
||||
|
||||
languages = {
|
||||
enableExtraDiagnostics = true;
|
||||
enableFormat = true;
|
||||
enableLSP = true;
|
||||
enableTreesitter = true;
|
||||
|
||||
nix.enable = true;
|
||||
clang.enable = true;
|
||||
python.enable = true;
|
||||
ts.enable = true;
|
||||
css.enable = true;
|
||||
};
|
||||
|
||||
treesitter = {
|
||||
enable = true;
|
||||
fold = true;
|
||||
context.enable = true;
|
||||
grammars = [
|
||||
pkgs.vimPlugins.nvim-treesitter.builtGrammars.nix
|
||||
pkgs.vimPlugins.nvim-treesitter.builtGrammars.c
|
||||
pkgs.vimPlugins.nvim-treesitter.builtGrammars.python
|
||||
];
|
||||
};
|
||||
|
||||
binds.whichKey.enable = true;
|
||||
filetree.neo-tree.enable = true;
|
||||
|
||||
telescope.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
programs.neovide = {
|
||||
enable = true;
|
||||
settings = {
|
||||
fork = false;
|
||||
frame = "full";
|
||||
idle = true;
|
||||
maximized = false;
|
||||
no-multigrid = false;
|
||||
srgb = false;
|
||||
tabs = true;
|
||||
theme = "auto";
|
||||
title-hidden = true;
|
||||
vsync = true;
|
||||
wsl = false;
|
||||
|
||||
font = {
|
||||
normal = [];
|
||||
size = 14.0;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,15 +0,0 @@
|
|||
{
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
programs.fuzzel = {
|
||||
enable = true;
|
||||
settings = {
|
||||
main = {
|
||||
terminal = lib.getExe pkgs.foot;
|
||||
layer = "overlay";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,23 +0,0 @@
|
|||
{
|
||||
pkgs,
|
||||
inputs,
|
||||
...
|
||||
}: {
|
||||
home.packages = [
|
||||
pkgs.bottles
|
||||
pkgs.mangohud
|
||||
pkgs.protonplus
|
||||
|
||||
# steamtinkerlaunch dependencies
|
||||
pkgs.wget
|
||||
pkgs.xdotool
|
||||
pkgs.xorg.xrandr
|
||||
pkgs.xorg.xprop
|
||||
pkgs.xorg.xwininfo
|
||||
pkgs.xxd
|
||||
pkgs.yad
|
||||
|
||||
inputs.self.packages.${pkgs.system}.bolt-launcher
|
||||
pkgs.ankama-launcher
|
||||
];
|
||||
}
|
|
@ -1,67 +0,0 @@
|
|||
{
|
||||
pkgs,
|
||||
osConfig,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
dconf = {
|
||||
enable = true;
|
||||
settings = {
|
||||
"org/gnome/shell" = {
|
||||
disable-user-extensions = false; # enables user extensions
|
||||
enabled-extensions = [
|
||||
pkgs.gnomeExtensions.appindicator.extensionUuid
|
||||
pkgs.gnomeExtensions.blur-my-shell.extensionUuid
|
||||
pkgs.gnomeExtensions.emoji-copy.extensionUuid
|
||||
pkgs.gnomeExtensions.clipboard-history.extensionUuid
|
||||
];
|
||||
};
|
||||
|
||||
"org/gnome/desktop/input-sources" = {
|
||||
xkb-options = ["compose:ralt"];
|
||||
};
|
||||
|
||||
"org/gnome/desktop/interface" = {
|
||||
enable-hot-corners = false;
|
||||
color-scheme = "prefer-dark";
|
||||
};
|
||||
"org/gnome/desktop/background" = {
|
||||
picture-uri-dark = "file://" + builtins.toString osConfig.theme.wallpaper;
|
||||
};
|
||||
|
||||
"org/gnome/desktop/search-providers" = {
|
||||
disabled = [
|
||||
"org.gnome.Terminal.desktop"
|
||||
"org.gnome.Software.desktop"
|
||||
"org.gnome.seahorse.Application.desktop"
|
||||
"org.gnome.clocks.desktop"
|
||||
"org.gnome.Characters.desktop"
|
||||
"org.gnome.Calendar.desktop"
|
||||
"org.gnome.Calculator.desktop"
|
||||
];
|
||||
enabled = [
|
||||
"org.gnome.Nautilus.desktop"
|
||||
"org.gnome.Settings.desktop"
|
||||
];
|
||||
};
|
||||
|
||||
"org/freedesktop/tracker/mine/files" = {
|
||||
index-recursive-directories = [
|
||||
"&DESKTOP"
|
||||
"&DOCUMENTS"
|
||||
"&MUSIC"
|
||||
"&PICTURES"
|
||||
"&VIDEOS"
|
||||
"${config.home.homeDirectory}/Notes"
|
||||
"${config.home.homeDirectory}/Projects"
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
home.packages = with pkgs.gnomeExtensions; [
|
||||
appindicator
|
||||
blur-my-shell
|
||||
clipboard-history
|
||||
emoji-copy
|
||||
];
|
||||
}
|
|
@ -1,30 +0,0 @@
|
|||
_: {
|
||||
services.hypridle = {
|
||||
enable = true;
|
||||
|
||||
settings = {
|
||||
general = {
|
||||
lock_cmd = "pidof hyprlock || hyprlock";
|
||||
unlock_cmd = "pkill --signal SIGUSR1 hyprlock";
|
||||
before_sleep_cmd = "loginctl lock-session";
|
||||
after_sleep_cmd = "hyprctl dispatch dpms on";
|
||||
};
|
||||
|
||||
listener = [
|
||||
{
|
||||
timeout = 300; # 5m
|
||||
on-timeout = "loginctl lock-session";
|
||||
}
|
||||
{
|
||||
timeout = 330; # 5.5m
|
||||
on-timeout = "hyprctl dipsatch dpms off";
|
||||
on-resume = "hyprctl dispatch dpms on";
|
||||
}
|
||||
{
|
||||
timeout = 600; # 10m
|
||||
on-timeout = "systemctl suspend";
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,66 +0,0 @@
|
|||
_: {
|
||||
wayland.windowManager.hyprland.settings = {
|
||||
"$mod" = "SUPER";
|
||||
bind = [
|
||||
"$mod, Return, exec, foot"
|
||||
"$mod, n, exec, neovide"
|
||||
"$mod, w, exec, firefox"
|
||||
", Print, exec, grimblast --notify copy output"
|
||||
"$mod, q, killactive"
|
||||
"$mod SHIFT, q, exit"
|
||||
"$mod, Space, exec, fuzzel"
|
||||
"CTRL, Print, exec, grimblast --notify --freeze copy area"
|
||||
|
||||
"$mod, h, movefocus, l"
|
||||
"$mod, j, movefocus, d"
|
||||
"$mod, k, movefocus, u"
|
||||
"$mod, l, movefocus, r"
|
||||
|
||||
"$mod SHIFT, h, movewindow, l"
|
||||
"$mod SHIFT, j, movewindow, d"
|
||||
"$mod SHIFT, k, movewindow, u"
|
||||
"$mod SHIFT, l, movewindow, r"
|
||||
|
||||
"$mod, 1, workspace, 1"
|
||||
"$mod, 2, workspace, 2"
|
||||
"$mod, 3, workspace, 3"
|
||||
"$mod, 4, workspace, 4"
|
||||
"$mod, 5, workspace, 5"
|
||||
"$mod, 6, workspace, 6"
|
||||
"$mod, 7, workspace, 7"
|
||||
"$mod, 8, workspace, 8"
|
||||
"$mod, 9, workspace, 9"
|
||||
"$mod, 0, workspace, 10"
|
||||
|
||||
"$mod SHIFT, 1, movetoworkspacesilent, 1"
|
||||
"$mod SHIFT, 2, movetoworkspacesilent, 2"
|
||||
"$mod SHIFT, 3, movetoworkspacesilent, 3"
|
||||
"$mod SHIFT, 4, movetoworkspacesilent, 4"
|
||||
"$mod SHIFT, 5, movetoworkspacesilent, 5"
|
||||
"$mod SHIFT, 6, movetoworkspacesilent, 6"
|
||||
"$mod SHIFT, 7, movetoworkspacesilent, 7"
|
||||
"$mod SHIFT, 8, movetoworkspacesilent, 8"
|
||||
"$mod SHIFT, 9, movetoworkspacesilent, 9"
|
||||
"$mod SHIFT, 0, movetoworkspacesilent, 10"
|
||||
|
||||
"$mod, t, togglefloating"
|
||||
", F11, fullscreen, 0"
|
||||
"$mod, f, fullscreen, 1"
|
||||
|
||||
"$mod, e, togglespecialworkspace, file_manager_tui"
|
||||
"$mod SHIFT, e, togglespecialworkspace, file_manager_gui"
|
||||
];
|
||||
|
||||
binde = [
|
||||
", XF86AudioRaiseVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+"
|
||||
", XF86AudioLowerVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-"
|
||||
", XF86AudioMute, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle"
|
||||
|
||||
", XF86MonBrightnessUp, exec, brillo -q -u 300000 -A 5"
|
||||
", XF86MonBrightnessDown, exec, brillo -q -u 300000 -U 5"
|
||||
", XF86AudioMedia, exec, sh -c env XDG_CURRENT_DESKTOP=gnome gnome-control-center"
|
||||
", XF86PowerOff, exec, wlogout"
|
||||
"$mod Alt, l, exec, loginctl lock-session"
|
||||
];
|
||||
};
|
||||
}
|
|
@ -1,90 +0,0 @@
|
|||
{
|
||||
inputs,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
imports = [./binds.nix];
|
||||
home.packages = [
|
||||
inputs.hyprwm-contrib.packages.${pkgs.system}.grimblast
|
||||
];
|
||||
wayland.windowManager.hyprland = {
|
||||
enable = true;
|
||||
xwayland.enable = true;
|
||||
systemd = {
|
||||
enable = true;
|
||||
variables = ["--all"];
|
||||
};
|
||||
|
||||
settings = {
|
||||
xwayland = {
|
||||
force_zero_scaling = true;
|
||||
};
|
||||
|
||||
env = [
|
||||
"GDK_SCALE,1"
|
||||
];
|
||||
monitor = [
|
||||
"eDP-1, preferred, auto, 1.33"
|
||||
];
|
||||
workspace = [
|
||||
"special:terminal, on-created-empty:foot"
|
||||
"special:mixer_gui, on-created-empty:pavucontrol"
|
||||
"special:file_manager_gui, on-created-empty:nautilus"
|
||||
"special:file_manager_tui, on-created-empty:foot -- yazi"
|
||||
];
|
||||
|
||||
windowrulev2 = [
|
||||
# fixes fullscreen windows (mostly games)
|
||||
"stayfocused, initialtitle:^()$, initialclass:^(steam)$"
|
||||
"minsize 1 1, initialtitle:^()$, initialclass:^(steam)$"
|
||||
"maximize, initialtitle:^(\S+)$, initialclass:^(steamwebhelper)$"
|
||||
|
||||
"immediate, initialclass:^(steam_app_)(.*)$"
|
||||
"fullscreen, initialclass:^(steam_app_)(.*)$"
|
||||
];
|
||||
|
||||
render = {
|
||||
explicit_sync = 1;
|
||||
explicit_sync_kms = 1;
|
||||
expand_undersized_textures = false;
|
||||
};
|
||||
|
||||
animations = {
|
||||
enabled = true;
|
||||
bezier = "myBezier, 0.05, 0.9, 0.1, 1.1";
|
||||
animation = [
|
||||
"windows, 1, 5, myBezier"
|
||||
"windowsOut, 1, 5, default, popin 80%"
|
||||
"windowsMove, 1, 5, default, popin 80%"
|
||||
"fade, 1, 5, default"
|
||||
"border, 1, 5, default"
|
||||
"borderangle, 0, 8, default"
|
||||
"workspaces, 0"
|
||||
"specialWorkspace, 0"
|
||||
];
|
||||
};
|
||||
|
||||
input = {
|
||||
kb_options = "compose:ralt";
|
||||
touchpad = {
|
||||
natural_scroll = true;
|
||||
scroll_factor = 0.8;
|
||||
tap-to-click = true;
|
||||
clickfinger_behavior = true;
|
||||
};
|
||||
};
|
||||
|
||||
gestures = {
|
||||
workspace_swipe = true;
|
||||
workspace_swipe_direction_lock = false;
|
||||
workspace_swipe_cancel_ratio = 0.15;
|
||||
};
|
||||
|
||||
misc = {
|
||||
force_default_wallpaper = 0;
|
||||
disable_hyprland_logo = true;
|
||||
middle_click_paste = false;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,5 +0,0 @@
|
|||
_: {
|
||||
programs.hyprlock = {
|
||||
enable = true;
|
||||
};
|
||||
}
|
|
@ -1,12 +0,0 @@
|
|||
{pkgs, ...}: {
|
||||
imports = [./zathura.nix];
|
||||
programs.mpv.enable = true;
|
||||
home.packages = [
|
||||
pkgs.gnome-calculator
|
||||
pkgs.loupe
|
||||
pkgs.spotify
|
||||
pkgs.stremio
|
||||
pkgs.tidal-hifi
|
||||
pkgs.celluloid
|
||||
];
|
||||
}
|
|
@ -1,17 +0,0 @@
|
|||
_: {
|
||||
programs.zathura = {
|
||||
enable = true;
|
||||
options = {
|
||||
font = "Inter 12";
|
||||
selection-notification = true;
|
||||
|
||||
selection-clipboard = "clipboard";
|
||||
adjust-open = "best-fit";
|
||||
pages-per-row = "1";
|
||||
scroll-page-aware = "true";
|
||||
scroll-full-overlap = "0.01";
|
||||
scroll-step = "100";
|
||||
zoom-min = "10";
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,168 +0,0 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
appLauncher = "fuzzel";
|
||||
terminal = "foot";
|
||||
browser = "firefox";
|
||||
prefix = "Mod";
|
||||
guiFileManager = "nautilus";
|
||||
cliFileManager = "yazi";
|
||||
in {
|
||||
programs.niri.settings.binds = {
|
||||
"${prefix}+D".action.spawn = appLauncher;
|
||||
"${prefix}+Return".action.spawn = terminal;
|
||||
"${prefix}+W".action.spawn = browser;
|
||||
"${prefix}+E".action.spawn = guiFileManager;
|
||||
"${prefix}+Shift+E".action.spawn = [terminal "-e" cliFileManager];
|
||||
|
||||
"${prefix}+Shift+Slash".action = config.lib.niri.actions.show-hotkey-overlay;
|
||||
"${prefix}+Q".action = config.lib.niri.actions.close-window;
|
||||
"${prefix}+Shift+Q".action.quit.skip-confirmation = true;
|
||||
"${prefix}+F".action = config.lib.niri.actions.maximize-column;
|
||||
"${prefix}+Shift+F".action = config.lib.niri.actions.fullscreen-window;
|
||||
"${prefix}+C".action = config.lib.niri.actions.center-column;
|
||||
|
||||
# Focus
|
||||
"${prefix}+Left".action = config.lib.niri.actions.focus-column-left;
|
||||
"${prefix}+Down".action = config.lib.niri.actions.focus-window-down;
|
||||
"${prefix}+Up".action = config.lib.niri.actions.focus-window-up;
|
||||
"${prefix}+Right".action = config.lib.niri.actions.focus-column-right;
|
||||
"${prefix}+H".action = config.lib.niri.actions.focus-column-left;
|
||||
"${prefix}+J".action = config.lib.niri.actions.focus-window-down;
|
||||
"${prefix}+K".action = config.lib.niri.actions.focus-window-up;
|
||||
"${prefix}+L".action = config.lib.niri.actions.focus-column-right;
|
||||
"${prefix}+Home".action = config.lib.niri.actions.focus-column-first;
|
||||
"${prefix}+End".action = config.lib.niri.actions.focus-column-last;
|
||||
|
||||
# Move
|
||||
"${prefix}+Ctrl+Left".action = config.lib.niri.actions.move-column-left;
|
||||
"${prefix}+Ctrl+Down".action = config.lib.niri.actions.move-window-down;
|
||||
"${prefix}+Ctrl+Up".action = config.lib.niri.actions.move-window-up;
|
||||
"${prefix}+Ctrl+Right".action = config.lib.niri.actions.move-column-right;
|
||||
"${prefix}+Ctrl+H".action = config.lib.niri.actions.move-column-left;
|
||||
"${prefix}+Ctrl+J".action = config.lib.niri.actions.move-window-down;
|
||||
"${prefix}+Ctrl+K".action = config.lib.niri.actions.move-window-up;
|
||||
"${prefix}+Ctrl+L".action = config.lib.niri.actions.move-column-right;
|
||||
"${prefix}+Ctrl+Home".action = config.lib.niri.actions.move-column-to-first;
|
||||
"${prefix}+Ctrl+End".action = config.lib.niri.actions.move-column-to-last;
|
||||
|
||||
# Monitor focus
|
||||
"${prefix}+Shift+Left".action = config.lib.niri.actions.focus-monitor-left;
|
||||
"${prefix}+Shift+Down".action = config.lib.niri.actions.focus-monitor-down;
|
||||
"${prefix}+Shift+Up".action = config.lib.niri.actions.focus-monitor-up;
|
||||
"${prefix}+Shift+Right".action = config.lib.niri.actions.focus-monitor-right;
|
||||
"${prefix}+Shift+H".action = config.lib.niri.actions.focus-monitor-left;
|
||||
"${prefix}+Shift+J".action = config.lib.niri.actions.focus-monitor-down;
|
||||
"${prefix}+Shift+K".action = config.lib.niri.actions.focus-monitor-up;
|
||||
"${prefix}+Shift+L".action = config.lib.niri.actions.focus-monitor-right;
|
||||
|
||||
# Move to monitor
|
||||
"${prefix}+Shift+Ctrl+Left".action = config.lib.niri.actions.move-column-to-monitor-left;
|
||||
"${prefix}+Shift+Ctrl+Down".action = config.lib.niri.actions.move-column-to-monitor-down;
|
||||
"${prefix}+Shift+Ctrl+Up".action = config.lib.niri.actions.move-column-to-monitor-up;
|
||||
"${prefix}+Shift+Ctrl+Right".action = config.lib.niri.actions.move-column-to-monitor-right;
|
||||
"${prefix}+Shift+Ctrl+H".action = config.lib.niri.actions.move-column-to-monitor-left;
|
||||
"${prefix}+Shift+Ctrl+J".action = config.lib.niri.actions.move-column-to-monitor-down;
|
||||
"${prefix}+Shift+Ctrl+K".action = config.lib.niri.actions.move-column-to-monitor-up;
|
||||
"${prefix}+Shift+Ctrl+L".action = config.lib.niri.actions.move-column-to-monitor-right;
|
||||
|
||||
# Workspace navigation
|
||||
"${prefix}+Page_Down".action = config.lib.niri.actions.focus-workspace-down;
|
||||
"${prefix}+Page_Up".action = config.lib.niri.actions.focus-workspace-up;
|
||||
"${prefix}+U".action = config.lib.niri.actions.focus-workspace-down;
|
||||
"${prefix}+I".action = config.lib.niri.actions.focus-workspace-up;
|
||||
"${prefix}+Ctrl+Page_Down".action = config.lib.niri.actions.move-column-to-workspace-down;
|
||||
"${prefix}+Ctrl+Page_Up".action = config.lib.niri.actions.move-column-to-workspace-up;
|
||||
"${prefix}+Ctrl+U".action = config.lib.niri.actions.move-column-to-workspace-down;
|
||||
"${prefix}+Ctrl+I".action = config.lib.niri.actions.move-column-to-workspace-up;
|
||||
"${prefix}+Shift+Page_Down".action = config.lib.niri.actions.move-workspace-down;
|
||||
"${prefix}+Shift+Page_Up".action = config.lib.niri.actions.move-workspace-up;
|
||||
"${prefix}+Shift+U".action = config.lib.niri.actions.move-workspace-down;
|
||||
|
||||
# Workspace focus
|
||||
"${prefix}+1".action.focus-workspace = 1;
|
||||
"${prefix}+2".action.focus-workspace = 2;
|
||||
"${prefix}+3".action.focus-workspace = 3;
|
||||
"${prefix}+4".action.focus-workspace = 4;
|
||||
"${prefix}+5".action.focus-workspace = 5;
|
||||
"${prefix}+6".action.focus-workspace = 6;
|
||||
"${prefix}+7".action.focus-workspace = 7;
|
||||
"${prefix}+8".action.focus-workspace = 8;
|
||||
"${prefix}+9".action.focus-workspace = 9;
|
||||
|
||||
# Move to workspace
|
||||
"${prefix}+Ctrl+1".action.move-column-to-workspace = 1;
|
||||
"${prefix}+Ctrl+2".action.move-column-to-workspace = 2;
|
||||
"${prefix}+Ctrl+3".action.move-column-to-workspace = 3;
|
||||
"${prefix}+Ctrl+4".action.move-column-to-workspace = 4;
|
||||
"${prefix}+Ctrl+5".action.move-column-to-workspace = 5;
|
||||
"${prefix}+Ctrl+6".action.move-column-to-workspace = 6;
|
||||
"${prefix}+Ctrl+7".action.move-column-to-workspace = 7;
|
||||
"${prefix}+Ctrl+8".action.move-column-to-workspace = 8;
|
||||
"${prefix}+Ctrl+9".action.move-column-to-workspace = 9;
|
||||
"${prefix}+Shift+I".action = config.lib.niri.actions.move-workspace-up;
|
||||
|
||||
# Window management
|
||||
"${prefix}+Comma".action = config.lib.niri.actions.consume-window-into-column;
|
||||
"${prefix}+Period".action = config.lib.niri.actions.expel-window-from-column;
|
||||
"${prefix}+BracketLeft".action = config.lib.niri.actions.consume-or-expel-window-left;
|
||||
"${prefix}+BracketRight".action = config.lib.niri.actions.consume-or-expel-window-right;
|
||||
|
||||
# Column management
|
||||
"${prefix}+R".action = config.lib.niri.actions.switch-preset-column-width;
|
||||
"${prefix}+Shift+R".action = config.lib.niri.actions.switch-preset-window-height;
|
||||
"${prefix}+Ctrl+R".action = config.lib.niri.actions.reset-window-height;
|
||||
"${prefix}+Minus".action = config.lib.niri.actions.set-column-width "-10%";
|
||||
"${prefix}+Equal".action = config.lib.niri.actions.set-column-width "+10%";
|
||||
"${prefix}+Shift+Minus".action = config.lib.niri.actions.set-window-height "-10%";
|
||||
"${prefix}+Shift+Equal".action = config.lib.niri.actions.set-window-height "+10%";
|
||||
|
||||
# Screenshots
|
||||
"Print".action = config.lib.niri.actions.screenshot-screen;
|
||||
"Ctrl+Print".action = config.lib.niri.actions.screenshot;
|
||||
|
||||
# System
|
||||
"${prefix}+Alt+L".action.spawn = [
|
||||
"${lib.getExe' pkgs.systemd "loginctl"}"
|
||||
"lock-session"
|
||||
];
|
||||
|
||||
# Media keys
|
||||
"XF86AudioRaiseVolume" = {
|
||||
action.spawn = ["wpctl" "set-volume" "@DEFAULT_AUDIO_SINK@" "0.1+"];
|
||||
allow-when-locked = true;
|
||||
};
|
||||
"XF86AudioLowerVolume" = {
|
||||
action.spawn = ["wpctl" "set-volume" "@DEFAULT_AUDIO_SINK@" "0.1-"];
|
||||
allow-when-locked = true;
|
||||
};
|
||||
"XF86AudioMute" = {
|
||||
action.spawn = ["wpctl" "set-mute" "@DEFAULT_AUDIO_SINK@" "toggle"];
|
||||
allow-when-locked = true;
|
||||
};
|
||||
"XF86AudioMicMute" = {
|
||||
action.spawn = ["wpctl" "set-mute" "@DEFAULT_AUDIO_SOURCE@" "toggle"];
|
||||
allow-when-locked = true;
|
||||
};
|
||||
"XF86AudioPlay" = {
|
||||
action.spawn = ["playerctl" "play-pause"];
|
||||
};
|
||||
"XF86MonBrightnessUp" = {
|
||||
action.spawn = ["brillo" "-q" "-u 300000" "-A 5"];
|
||||
allow-when-locked = true;
|
||||
};
|
||||
"XF86MonBrightnessDown" = {
|
||||
action.spawn = ["brillo" "-q" "-u 300000" "-U 5"];
|
||||
allow-when-locked = true;
|
||||
};
|
||||
# set on media key since framework laptops have a gear as the button label
|
||||
"XF86AudioMedia" = {
|
||||
action.spawn = ["sh" "-c" "env XDG_CURRENT_DESKTOP=gnome gnome-control-center"];
|
||||
};
|
||||
|
||||
"XF86PowerOff".action.spawn = "wlogout";
|
||||
};
|
||||
}
|
|
@ -1,173 +0,0 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
imports = [./binds.nix];
|
||||
|
||||
xdg.portal = {
|
||||
enable = true;
|
||||
xdgOpenUsePortal = true;
|
||||
extraPortals = [pkgs.xdg-desktop-portal-gtk pkgs.xdg-desktop-portal-gnome pkgs.gnome-keyring];
|
||||
config = {
|
||||
common = {
|
||||
default = ["gtk"];
|
||||
"org.freedesktop.impl.portal.ScreenCast" = ["gnome"];
|
||||
"org.freedesktop.impl.portal.Secret" = ["gnome-keyring"];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
programs.niri = {
|
||||
settings = {
|
||||
input = {
|
||||
power-key-handling.enable = false;
|
||||
keyboard.xkb = {
|
||||
layout = "us";
|
||||
options = "compose:ralt";
|
||||
};
|
||||
};
|
||||
|
||||
prefer-no-csd = true;
|
||||
hotkey-overlay.skip-at-startup = true;
|
||||
|
||||
layout = {
|
||||
focus-ring = {
|
||||
enable = true;
|
||||
};
|
||||
always-center-single-column = true;
|
||||
};
|
||||
|
||||
# https://github.com/sodiboo/system/blob/2978f4d79c51a5bd7e38a9cd75e3ec9046aa7e75/niri.mod.nix#L418-L434
|
||||
outputs = let
|
||||
cfg = config.programs.niri.settings.outputs;
|
||||
in {
|
||||
"HDMI-A-1" = {
|
||||
mode = {
|
||||
width = 1920;
|
||||
height = 1080;
|
||||
refresh = 60.0;
|
||||
};
|
||||
position.x = -cfg."HDMI-A-1".mode.width;
|
||||
position.y = 0;
|
||||
};
|
||||
"DP-1" = {
|
||||
mode = {
|
||||
width = 2560;
|
||||
height = 1440;
|
||||
refresh = 144.0;
|
||||
};
|
||||
position.x = 0;
|
||||
position.y = 0;
|
||||
};
|
||||
};
|
||||
|
||||
window-rules = [
|
||||
{
|
||||
draw-border-with-background = false;
|
||||
geometry-corner-radius = let
|
||||
r = 8.0;
|
||||
in {
|
||||
top-left = r;
|
||||
top-right = r;
|
||||
bottom-left = r;
|
||||
bottom-right = r;
|
||||
};
|
||||
clip-to-geometry = true;
|
||||
}
|
||||
{
|
||||
matches = [
|
||||
{app-id = "foot";}
|
||||
];
|
||||
default-column-width = {proportion = 0.5;};
|
||||
}
|
||||
];
|
||||
|
||||
environment = {
|
||||
"NIXOS_OZONE_WL" = "1";
|
||||
"DISPLAY" = ":0";
|
||||
"_JAVA_AWT_WM_NONREPARENTING" = "1"; # https://wiki.archlinux.org/title/Sway#Java_applications
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
# copied from https://github.com/linyinfeng/dotfiles/blob/c00fe3b1562ad947672863a43e455bc2f01a56b6/home-manager/profiles/niri/default.nix#L594-L611
|
||||
systemd.user.services.xwayland-satellite = {
|
||||
Unit = {
|
||||
PartOf = ["graphical-session.target"];
|
||||
After = ["graphical-session.target"];
|
||||
Requisite = ["graphical-session.target"];
|
||||
};
|
||||
Install = {
|
||||
WantedBy = ["niri.service"];
|
||||
};
|
||||
Service = {
|
||||
Type = "simple";
|
||||
ExecStart = "${lib.getExe pkgs.xwayland-satellite} :0";
|
||||
NotifyAccess = "all";
|
||||
StandardOutput = "journal";
|
||||
Restart = "on-failure";
|
||||
};
|
||||
};
|
||||
|
||||
programs.wlogout = {
|
||||
enable = true;
|
||||
|
||||
layout = let
|
||||
systemd = let
|
||||
systemd = lib.getExe' pkgs.systemd;
|
||||
in {
|
||||
loginctl = systemd "loginctl";
|
||||
systemctl = systemd "systemctl";
|
||||
};
|
||||
in [
|
||||
{
|
||||
action = "${systemd.loginctl} lock-session";
|
||||
keybind = "l";
|
||||
label = "lock";
|
||||
text = "Lock";
|
||||
}
|
||||
|
||||
{
|
||||
action = "${systemd.systemctl} hibernate";
|
||||
keybind = "h";
|
||||
label = "hibernate";
|
||||
text = "Hibernate";
|
||||
}
|
||||
|
||||
{
|
||||
action = "${
|
||||
systemd.loginctl
|
||||
} terminate-user ${
|
||||
config.home.username
|
||||
}";
|
||||
|
||||
keybind = "q";
|
||||
label = "logout";
|
||||
text = "Logout";
|
||||
}
|
||||
|
||||
{
|
||||
action = "${systemd.systemctl} poweroff";
|
||||
keybind = "p";
|
||||
label = "shutdown";
|
||||
text = "Shutdown";
|
||||
}
|
||||
|
||||
{
|
||||
action = "${systemd.systemctl} suspend";
|
||||
keybind = "s";
|
||||
label = "suspend";
|
||||
text = "Suspend";
|
||||
}
|
||||
|
||||
{
|
||||
action = "${systemd.systemctl} reboot";
|
||||
keybind = "r";
|
||||
label = "reboot";
|
||||
text = "Reboot";
|
||||
}
|
||||
];
|
||||
};
|
||||
}
|
|
@ -1,19 +0,0 @@
|
|||
# stolen from https://raw.githubusercontent.com/carlsvelz/dotfiles/a7a109b2e19f73062b4961e7be75836e6d13408c/home/wayland/swaybg.nix
|
||||
{
|
||||
pkgs,
|
||||
lib,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
systemd.user.services.swaybg = {
|
||||
Unit = {
|
||||
Description = "Wayland wallpaper daemon";
|
||||
PartOf = ["graphical-session.target"];
|
||||
};
|
||||
Service = {
|
||||
ExecStart = "${lib.getExe pkgs.swaybg} -i ${osConfig.theme.wallpaper} -m fill";
|
||||
Restart = "on-failure";
|
||||
};
|
||||
Install.WantedBy = ["graphical-session.target"];
|
||||
};
|
||||
}
|
|
@ -1,20 +0,0 @@
|
|||
{
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
services.swayidle = {
|
||||
enable = true;
|
||||
events = [
|
||||
{
|
||||
event = "lock";
|
||||
command = "${lib.getExe config.programs.swaylock.package} --daemonize";
|
||||
}
|
||||
{
|
||||
event = "before-sleep";
|
||||
command = "${lib.getExe config.programs.swaylock.package} --daemonize";
|
||||
}
|
||||
];
|
||||
};
|
||||
systemd.user.services.swayidle.Unit.After = lib.mkForce ["graphical-session.target"];
|
||||
}
|
|
@ -1,24 +0,0 @@
|
|||
{pkgs, ...}: {
|
||||
# requires `security.pam.services.swaylock = { };` at the system level or else
|
||||
# unlock will not work.
|
||||
programs.swaylock = {
|
||||
enable = true;
|
||||
package = pkgs.swaylock-effects;
|
||||
|
||||
settings = {
|
||||
clock = true;
|
||||
timestr = "%H:%M";
|
||||
|
||||
indicator = true;
|
||||
indicator-radius = 111;
|
||||
indicator-thickness = 9;
|
||||
|
||||
screenshots = true;
|
||||
effect-blur = "7x5";
|
||||
effect-vignette = "0.75:0.75";
|
||||
effect-pixelate = 5;
|
||||
|
||||
ignore-empty-password = false; # needed for PAM to work with fprintd / password
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,186 +0,0 @@
|
|||
{
|
||||
pkgs,
|
||||
lib,
|
||||
osConfig,
|
||||
config,
|
||||
...
|
||||
}: let
|
||||
inherit (lib) getExe mkMerge mkIf;
|
||||
inherit (builtins) readFile;
|
||||
in {
|
||||
programs.waybar = {
|
||||
enable = true;
|
||||
systemd.enable = true;
|
||||
style = readFile ./style.css;
|
||||
settings = {
|
||||
mainBar = mkMerge [
|
||||
{
|
||||
layer = "top";
|
||||
position = "top";
|
||||
height = 30;
|
||||
|
||||
margin-top = 6;
|
||||
margin-left = 6;
|
||||
margin-right = 6;
|
||||
margin-bottom = 0;
|
||||
|
||||
modules-left = ["hyprland/workspaces" "hyprland/window"];
|
||||
modules-center = ["group/clock"];
|
||||
modules-right =
|
||||
["tray" "group/status" "group/power"]
|
||||
++ lib.optional config.services.swaync.enable "custom/swaync";
|
||||
|
||||
tray = {
|
||||
icon-size = 16;
|
||||
spacing = 12;
|
||||
};
|
||||
|
||||
battery = {
|
||||
interval = 10;
|
||||
states = {
|
||||
warning = 30;
|
||||
critical = 15;
|
||||
};
|
||||
format = "{icon} {capacity}%";
|
||||
format-charging = " {capacity}% - {time}";
|
||||
format-full = " {capacity}% - Full";
|
||||
format-icons = [
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
];
|
||||
max-length = 25;
|
||||
};
|
||||
|
||||
"pulseaudio" = {
|
||||
format = "{icon} {volume}%";
|
||||
format-bluetooth = "{icon} {volume}%";
|
||||
format-muted = " ";
|
||||
format-icons = {
|
||||
"alsa_output.pci-0000_00_1f.3.analog-stereo" = "";
|
||||
"alsa_output.pci-0000_00_1f.3.analog-stereo-muted" = "";
|
||||
headphone = "";
|
||||
hands-free = "";
|
||||
headset = "";
|
||||
phone = "";
|
||||
phone-muted = "";
|
||||
portable = "";
|
||||
car = "";
|
||||
default = [
|
||||
""
|
||||
""
|
||||
];
|
||||
};
|
||||
scroll-step = 1;
|
||||
on-click = "pavucontrol";
|
||||
ignored-sinks = [
|
||||
"Easy Effects Sink"
|
||||
];
|
||||
};
|
||||
|
||||
"power-profiles-daemon" = {
|
||||
format-icons = {
|
||||
default = "";
|
||||
performance = "";
|
||||
balanced = "";
|
||||
power-saver = "";
|
||||
};
|
||||
};
|
||||
|
||||
"group/status" = {
|
||||
orientation = "inherit";
|
||||
modules = [
|
||||
"pulseaudio"
|
||||
"power-profiles-daemon"
|
||||
"network"
|
||||
"battery"
|
||||
];
|
||||
};
|
||||
|
||||
"group/power" = {
|
||||
orientation = "inherit";
|
||||
modules = [
|
||||
"custom/power"
|
||||
];
|
||||
};
|
||||
|
||||
"group/clock" = {
|
||||
orientation = "inherit";
|
||||
modules = [
|
||||
"clock#time"
|
||||
"clock#date"
|
||||
];
|
||||
};
|
||||
|
||||
"custom/power" = {
|
||||
format = "";
|
||||
tooltip = false;
|
||||
on-click = getExe pkgs.wlogout;
|
||||
};
|
||||
|
||||
"clock#date" = {
|
||||
format = "{:%D}";
|
||||
tooltip-format = "<tt><big>{calendar}</big></tt>";
|
||||
};
|
||||
|
||||
"clock#time" = {
|
||||
format = "{:%H:%M}";
|
||||
tooltip-format = "{tz_list}";
|
||||
timezones = [
|
||||
osConfig.time.timeZone
|
||||
"US/Eastern"
|
||||
];
|
||||
};
|
||||
|
||||
network = {
|
||||
interface = "wlp1s0";
|
||||
format = "{ifname}";
|
||||
format-wifi = "{icon}";
|
||||
format-ethernet = "{ipaddr}/{cidr} ";
|
||||
format-disconnected = "";
|
||||
tooltip-format = "{ifname} via {gwaddr} ";
|
||||
tooltip-format-wifi = "{essid} ({signalStrength}%)";
|
||||
tooltip-format-ethernet = "{ifname} ";
|
||||
tooltip-format-disconnected = "Disconnected";
|
||||
max-length = 50;
|
||||
format-icons = [
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
];
|
||||
};
|
||||
}
|
||||
(mkIf osConfig.programs.niri.enable {
|
||||
"niri/window" = {
|
||||
icon = true;
|
||||
};
|
||||
})
|
||||
(mkIf config.services.swaync.enable {
|
||||
"custom/swaync" = {
|
||||
format = "<big>{icon}</big>";
|
||||
format-icons = {
|
||||
notification = "";
|
||||
none = "";
|
||||
dnd-notification = "";
|
||||
dnd-none = "";
|
||||
};
|
||||
max-length = 3;
|
||||
return-type = "json";
|
||||
escape = true;
|
||||
exec-if = "which ${pkgs.swaynotificationcenter}/bin/swaync-client";
|
||||
exec = "${pkgs.swaynotificationcenter}/bin/swaync-client --subscribe-waybar";
|
||||
on-click = "${pkgs.swaynotificationcenter}/bin/swaync-client --toggle-panel --skip-wait";
|
||||
on-click-middle = "${pkgs.swaynotificationcenter}/bin/swaync-client --toggle-dnd --skip-wait";
|
||||
tooltip-format = " {} notification(s)";
|
||||
};
|
||||
})
|
||||
];
|
||||
};
|
||||
};
|
||||
home.packages = [
|
||||
pkgs.pavucontrol
|
||||
];
|
||||
}
|
|
@ -1,91 +0,0 @@
|
|||
* {
|
||||
/* `otf-font-awesome` is required to be installed for icons */
|
||||
border: none;
|
||||
border-radius: 0px;
|
||||
min-height: 0;
|
||||
}
|
||||
|
||||
window#waybar {
|
||||
border-radius: 2em;
|
||||
font-family: "Symbols Nerd Font", Inter, sans-serif;
|
||||
font-size: 16px;
|
||||
font-style: normal;
|
||||
background: alpha(
|
||||
@base00,
|
||||
0.9999999
|
||||
); /* niri issue workaround, thanks https://github.com/oatmealine/nix-config/blob/bfdddd2cb36ef659bcddc28e0dbb542b6db8b3bc/modules/desktop/themes/catppuccin/waybar.css#L14 */
|
||||
color: @base05;
|
||||
}
|
||||
|
||||
#workspaces,
|
||||
.modules-right box {
|
||||
background: @base02;
|
||||
padding: 0.15em 0.25em;
|
||||
border-radius: 1em;
|
||||
margin: 0 0.25em;
|
||||
}
|
||||
|
||||
#workspaces {
|
||||
padding: 0;
|
||||
background: @base02;
|
||||
}
|
||||
|
||||
#workspaces button:nth-child(1) {
|
||||
border-top-left-radius: 1em;
|
||||
border-bottom-left-radius: 1em;
|
||||
}
|
||||
#workspaces button:nth-last-child(1) {
|
||||
border-top-right-radius: 1em;
|
||||
border-bottom-right-radius: 1em;
|
||||
}
|
||||
|
||||
#workspaces button {
|
||||
padding: 0 0.5em;
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
#workspaces button:hover {
|
||||
background: rgba(255, 255, 255, 0.1);
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
#workspaces button.active {
|
||||
background: @base0D;
|
||||
color: @base02;
|
||||
}
|
||||
|
||||
#workspaces button.urgent {
|
||||
background: @base08;
|
||||
}
|
||||
|
||||
#window {
|
||||
margin-left: 1em;
|
||||
}
|
||||
|
||||
.modules-left,
|
||||
.modules-right {
|
||||
margin: 0.4em 0.5em;
|
||||
}
|
||||
|
||||
#battery,
|
||||
#clock,
|
||||
#network,
|
||||
#pulseaudio,
|
||||
#tray,
|
||||
#power-profiles-daemon {
|
||||
padding: 0 0.5em;
|
||||
}
|
||||
|
||||
.modules-left,
|
||||
.modules-right {
|
||||
margin: 0.4em 0.5em;
|
||||
}
|
||||
|
||||
#custom-power {
|
||||
padding: 0 1.2em;
|
||||
color: @base08;
|
||||
}
|
||||
|
||||
#custom-swaync {
|
||||
padding: 0 1.2em;
|
||||
}
|
|
@ -1,66 +0,0 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
programs.wlogout = {
|
||||
enable = true;
|
||||
|
||||
layout = let
|
||||
systemd = let
|
||||
systemd = lib.getExe' pkgs.systemd;
|
||||
in {
|
||||
loginctl = systemd "loginctl";
|
||||
systemctl = systemd "systemctl";
|
||||
};
|
||||
in [
|
||||
{
|
||||
action = "${systemd.loginctl} lock-session";
|
||||
keybind = "l";
|
||||
label = "lock";
|
||||
text = "Lock";
|
||||
}
|
||||
|
||||
{
|
||||
action = "${systemd.systemctl} hibernate";
|
||||
keybind = "h";
|
||||
label = "hibernate";
|
||||
text = "Hibernate";
|
||||
}
|
||||
|
||||
{
|
||||
action = "${
|
||||
systemd.loginctl
|
||||
} terminate-user ${
|
||||
config.home.username
|
||||
}";
|
||||
|
||||
keybind = "q";
|
||||
label = "logout";
|
||||
text = "Logout";
|
||||
}
|
||||
|
||||
{
|
||||
action = "${systemd.systemctl} poweroff";
|
||||
keybind = "p";
|
||||
label = "shutdown";
|
||||
text = "Shutdown";
|
||||
}
|
||||
|
||||
{
|
||||
action = "${systemd.systemctl} suspend";
|
||||
keybind = "s";
|
||||
label = "suspend";
|
||||
text = "Suspend";
|
||||
}
|
||||
|
||||
{
|
||||
action = "${systemd.systemctl} reboot";
|
||||
keybind = "r";
|
||||
label = "reboot";
|
||||
text = "Reboot";
|
||||
}
|
||||
];
|
||||
};
|
||||
}
|
|
@ -1,35 +0,0 @@
|
|||
{config, ...}: {
|
||||
xdg = {
|
||||
enable = true;
|
||||
cacheHome = config.home.homeDirectory + "/.local/cache";
|
||||
|
||||
mimeApps = {
|
||||
enable = true;
|
||||
defaultApplications = {
|
||||
"default-web-browser" = ["firefox.desktop"];
|
||||
"text/html" = ["firefox.desktop"];
|
||||
"x-scheme-handler/http" = ["firefox.desktop"];
|
||||
"x-scheme-handler/https" = ["firefox.desktop"];
|
||||
"x-scheme-handler/about" = ["firefox.desktop"];
|
||||
"x-scheme-handler/unknown" = ["firefox.desktop"];
|
||||
"x-scheme-handler/chrome" = ["chromium-browser.desktop"];
|
||||
"inode/directory" = ["yazi.desktop"];
|
||||
"application/pdf" = ["org.pwmt.zathura-pdf-mupdf.desktop"];
|
||||
"image/png" = ["org.gnome.Loupe.desktop"];
|
||||
"image/svg" = [" org.gnome.Loupe.desktop"];
|
||||
"image/jpeg" = ["org.gnome.Loupe.desktop"];
|
||||
"image/gif" = [" org.gnome.Loupe.desktop"];
|
||||
"video/mp4" = ["io.github.celluloid_player.Celluloid.desktop"];
|
||||
"video/avi" = ["io.github.celluloid_player.Celluloid.desktop"];
|
||||
"video/mkv" = ["io.github.celluloid_player.Celluloid.desktop"];
|
||||
};
|
||||
};
|
||||
userDirs = {
|
||||
enable = true;
|
||||
createDirectories = true;
|
||||
extraConfig = {
|
||||
XDG_SCREENSHOTS_DIR = "${config.xdg.userDirs.pictures}/Screenshots";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,9 +0,0 @@
|
|||
{inputs, ...}: {
|
||||
imports = [inputs.nix-flatpak.homeManagerModules.nix-flatpak];
|
||||
services.flatpak.packages = [
|
||||
{
|
||||
flatpakref = "https://sober.vinegarhq.org/sober.flatpakref";
|
||||
sha256 = "1pj8y1xhiwgbnhrr3yr3ybpfis9slrl73i0b1lc9q89vhip6ym2l";
|
||||
}
|
||||
];
|
||||
}
|
|
@ -1,27 +0,0 @@
|
|||
{lib, ...}: let
|
||||
inherit (builtins) readFile;
|
||||
in {
|
||||
services.swaync = {
|
||||
enable = true;
|
||||
style = readFile ./style.css;
|
||||
settings = {
|
||||
positionX = "right";
|
||||
positionY = "top";
|
||||
layer = "overlay";
|
||||
control-center-layer = "top";
|
||||
layer-shell = true;
|
||||
cssPriority = "application";
|
||||
control-center-margin-top = 0;
|
||||
control-center-margin-bottom = 0;
|
||||
control-center-margin-right = 0;
|
||||
control-center-margin-left = 0;
|
||||
notification-2fa-action = true;
|
||||
notification-inline-replies = false;
|
||||
notification-icon-size = 64;
|
||||
notification-body-image-height = 100;
|
||||
notification-body-image-width = 200;
|
||||
};
|
||||
};
|
||||
# systemd.user.services.swaync.Service.Environment = "WAYLAND_DISPLAY=wayland-1";
|
||||
systemd.user.services.swaync.Unit.ConditionEnvironment = lib.mkForce "";
|
||||
}
|
|
@ -1,5 +0,0 @@
|
|||
_: {
|
||||
services.syncthing = {
|
||||
enable = true;
|
||||
};
|
||||
}
|
|
@ -1,3 +0,0 @@
|
|||
{
|
||||
services.udiskie.enable = true;
|
||||
}
|
|
@ -1,10 +0,0 @@
|
|||
_: {
|
||||
imports = [
|
||||
./programs
|
||||
./shell
|
||||
];
|
||||
|
||||
home.sessionVariables = {
|
||||
EDITOR = "nvim";
|
||||
};
|
||||
}
|
|
@ -1,18 +0,0 @@
|
|||
{
|
||||
osConfig,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
in {
|
||||
programs.foot = {
|
||||
enable = true;
|
||||
settings = {
|
||||
main = {
|
||||
term = "xterm-256color";
|
||||
font = "monospace:size=14";
|
||||
shell = "${lib.getExe config.programs.fish.package}";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,16 +0,0 @@
|
|||
_: {
|
||||
programs.gnome-terminal = {
|
||||
enable = true;
|
||||
showMenubar = true;
|
||||
profile = {
|
||||
"4621184a-b921-42cf-80a0-7784516606f2" = {
|
||||
default = true;
|
||||
audibleBell = false;
|
||||
allowBold = true;
|
||||
boldIsBright = true;
|
||||
visibleName = "default";
|
||||
font = "Intel One Mono 14";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,71 +0,0 @@
|
|||
{
|
||||
programs.wezterm = {
|
||||
enable = true;
|
||||
# package = inputs.wezterm.packages.${pkgs.system}.default;
|
||||
extraConfig = ''
|
||||
local w = require('wezterm')
|
||||
|
||||
local function is_vim(pane)
|
||||
return pane:get_user_vars().IS_NVIM == 'true'
|
||||
end
|
||||
|
||||
local direction_keys = {
|
||||
h = 'Left',
|
||||
j = 'Down',
|
||||
k = 'Up',
|
||||
l = 'Right',
|
||||
}
|
||||
|
||||
local function split_nav(resize_or_move, key)
|
||||
return {
|
||||
key = key,
|
||||
mods = resize_or_move == 'resize' and 'META' or 'CTRL',
|
||||
action = w.action_callback(function(win, pane)
|
||||
if is_vim(pane) then
|
||||
win:perform_action({
|
||||
SendKey = { key = key, mods = resize_or_move == 'resize' and 'META' or 'CTRL' },
|
||||
}, pane)
|
||||
else
|
||||
if resize_or_move == 'resize' then
|
||||
win:perform_action({ AdjustPaneSize = { direction_keys[key], 3 } }, pane)
|
||||
else
|
||||
win:perform_action({ ActivatePaneDirection = direction_keys[key] }, pane)
|
||||
end
|
||||
end
|
||||
end),
|
||||
}
|
||||
end
|
||||
|
||||
return {
|
||||
enable_wayland = false,
|
||||
front_end = "WebGpu",
|
||||
hide_tab_bar_if_only_one_tab = true,
|
||||
show_new_tab_button_in_tab_bar = false,
|
||||
harfbuzz_features = { "ss01", "ss03" },
|
||||
|
||||
leader = { key = " ", mods = "CTRL", timeout_milliseconds = 1000 },
|
||||
|
||||
keys = {
|
||||
{
|
||||
mods = "LEADER",
|
||||
key = "-",
|
||||
action = wezterm.action.SplitVertical { domain = "CurrentPaneDomain" }
|
||||
},
|
||||
{
|
||||
mods = "LEADER",
|
||||
key = "=",
|
||||
action = wezterm.action.SplitHorizontal { domain = "CurrentPaneDomain" }
|
||||
},
|
||||
split_nav('move', 'h'),
|
||||
split_nav('move', 'j'),
|
||||
split_nav('move', 'k'),
|
||||
split_nav('move', 'l'),
|
||||
split_nav('resize', 'h'),
|
||||
split_nav('resize', 'j'),
|
||||
split_nav('resize', 'k'),
|
||||
split_nav('resize', 'l'),
|
||||
},
|
||||
}
|
||||
'';
|
||||
};
|
||||
}
|
|
@ -1,10 +0,0 @@
|
|||
_: {
|
||||
programs.bat = {
|
||||
enable = true;
|
||||
config.theme = "base16";
|
||||
};
|
||||
home.sessionVariables = {
|
||||
MANPAGER = "sh -c 'col -bx | bat -l man -p'";
|
||||
MANROFFOPT = "-c";
|
||||
};
|
||||
}
|
|
@ -1,23 +0,0 @@
|
|||
{pkgs, ...}: {
|
||||
imports = [
|
||||
./bat.nix
|
||||
./git.nix
|
||||
./gnupg.nix
|
||||
./tmux.nix
|
||||
./direnv.nix
|
||||
./nix-index.nix
|
||||
./yazi.nix
|
||||
];
|
||||
|
||||
home.packages = with pkgs; [
|
||||
# archives
|
||||
zip
|
||||
unzip
|
||||
unrar
|
||||
|
||||
# utils
|
||||
fd
|
||||
file
|
||||
ripgrep
|
||||
];
|
||||
}
|
|
@ -1,8 +0,0 @@
|
|||
{
|
||||
programs = {
|
||||
direnv = {
|
||||
enable = true;
|
||||
nix-direnv.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,54 +0,0 @@
|
|||
{
|
||||
programs.git = {
|
||||
enable = true;
|
||||
userName = "Anthony Rodriguez";
|
||||
userEmail = "anthony@nezia.dev";
|
||||
signing = {
|
||||
signByDefault = true;
|
||||
key = "EE3BE97C040A86CE";
|
||||
};
|
||||
extraConfig = {
|
||||
push.autoSetupRemote = true;
|
||||
init = {
|
||||
defaultBranch = "main";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
programs.lazygit = {
|
||||
enable = true;
|
||||
};
|
||||
|
||||
home.shellAliases = {
|
||||
lg = "lazygit";
|
||||
g = "git";
|
||||
gs = "git status";
|
||||
gsh = "git show HEAD";
|
||||
gshs = "DELTA_FEATURES=+side-by-side git show HEAD";
|
||||
ga = "git add";
|
||||
gaa = "git add :/";
|
||||
gap = "git add -p";
|
||||
gc = "git commit";
|
||||
gca = "git commit --amend";
|
||||
gcm = "git commit --message";
|
||||
gcf = "git commit --fixup";
|
||||
gk = "git checkout";
|
||||
gkp = "git checkout -p";
|
||||
gd = "git diff";
|
||||
gds = "DELTA_FEATURES=+side-by-side git diff";
|
||||
gdc = "git diff --cached";
|
||||
gdcs = "DELTA_FEATURES=+side-by-side git diff --cached";
|
||||
gf = "git fetch";
|
||||
gl = "git log";
|
||||
glp = "git log -p";
|
||||
glps = "DELTA_FEATURES=+side-by-side git log -p";
|
||||
gp = "git push";
|
||||
gpf = "git push --force-with-lease";
|
||||
gr = "git reset";
|
||||
gra = "git reset :/";
|
||||
grp = "git reset -p";
|
||||
gt = "git stash";
|
||||
gtp = "git stash pop";
|
||||
gu = "git pull";
|
||||
};
|
||||
}
|
|
@ -1,8 +0,0 @@
|
|||
{
|
||||
programs.gpg.enable = true;
|
||||
services.gpg-agent = {
|
||||
enable = true;
|
||||
enableBashIntegration = true;
|
||||
enableFishIntegration = true;
|
||||
};
|
||||
}
|
|
@ -1,11 +0,0 @@
|
|||
{inputs, ...}: {
|
||||
imports = [inputs.nix-index-db.hmModules.nix-index];
|
||||
programs = {
|
||||
nix-index = {
|
||||
enable = true;
|
||||
symlinkToCacheHome = true; # needed for comma
|
||||
};
|
||||
command-not-found.enable = false;
|
||||
nix-index-database.comma.enable = true;
|
||||
};
|
||||
}
|
|
@ -1,44 +0,0 @@
|
|||
{pkgs, ...}: {
|
||||
programs.tmux = {
|
||||
enable = true;
|
||||
prefix = "C-space";
|
||||
escapeTime = 10;
|
||||
clock24 = true;
|
||||
keyMode = "vi";
|
||||
mouse = true;
|
||||
baseIndex = 1;
|
||||
extraConfig = ''
|
||||
set-option -a terminal-features "''${TERM}:RGB"
|
||||
'';
|
||||
plugins = with pkgs; [
|
||||
{
|
||||
plugin = tmuxPlugins.catppuccin;
|
||||
extraConfig = ''
|
||||
set -g @catppuccin_window_left_separator ""
|
||||
set -g @catppuccin_window_right_separator " "
|
||||
set -g @catppuccin_window_middle_separator " █"
|
||||
set -g @catppuccin_window_number_position "right"
|
||||
|
||||
set -g @catppuccin_window_default_fill "number"
|
||||
set -g @catppuccin_window_default_text "#W"
|
||||
|
||||
set -g @catppuccin_window_current_fill "number"
|
||||
set -g @catppuccin_window_current_text "#W"
|
||||
|
||||
set -g @catppuccin_status_modules_right "directory user host session"
|
||||
set -g @catppuccin_status_left_separator " "
|
||||
set -g @catppuccin_status_right_separator ""
|
||||
set -g @catppuccin_status_fill "icon"
|
||||
set -g @catppuccin_status_connect_separator "no"
|
||||
|
||||
set -g @catppuccin_directory_text "#{pane_current_path}"
|
||||
|
||||
set -g @catppuccin_flavor 'frappe'
|
||||
'';
|
||||
}
|
||||
tmuxPlugins.vim-tmux-navigator
|
||||
tmuxPlugins.yank
|
||||
];
|
||||
};
|
||||
programs.fzf.tmux.enableShellIntegration = true;
|
||||
}
|
|
@ -1,26 +0,0 @@
|
|||
{pkgs, ...}: {
|
||||
programs.yazi = let
|
||||
# https://github.com/iynaix/dotfiles/blob/8bb1568019ea26f034ac1af9c499b3ff102391a5/home-manager/shell/yazi.nix#L9-L11
|
||||
mkYaziPlugin = name: text: {
|
||||
"${name}" = toString (pkgs.writeTextDir "${name}.yazi/init.lua" text) + "/${name}.yazi";
|
||||
};
|
||||
in {
|
||||
enable = true;
|
||||
enableFishIntegration = true;
|
||||
plugins = mkYaziPlugin "smart-enter" ''
|
||||
return {
|
||||
entry = function()
|
||||
local h = cx.active.current.hovered
|
||||
ya.manager_emit(h and h.cha.is_dir and "enter" or "open", { hovered = true })
|
||||
end,
|
||||
}
|
||||
'';
|
||||
keymap.manager.prepend_keymap = [
|
||||
{
|
||||
on = "l";
|
||||
run = "plugin --sync smart-enter";
|
||||
desc = "Enter the child directory, or open the file";
|
||||
}
|
||||
];
|
||||
};
|
||||
}
|
|
@ -1,52 +0,0 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
starshipTransient = lib.strings.optionalString config.programs.starship.enableTransience ''
|
||||
function starship_transient_prompt_func
|
||||
starship module character
|
||||
end
|
||||
|
||||
function starship_transient_rprompt_func
|
||||
starship module cmd_duration
|
||||
end
|
||||
'';
|
||||
in {
|
||||
programs.fish = {
|
||||
enable = true;
|
||||
interactiveShellInit =
|
||||
starshipTransient
|
||||
+ ''
|
||||
set fish_greeting # Disable greeting
|
||||
fish_vi_key_bindings # Enable Vi mode
|
||||
|
||||
'';
|
||||
shellAbbrs = {
|
||||
cd = "z";
|
||||
ngc = "sudo nix-collect-garbage -d";
|
||||
};
|
||||
plugins = [
|
||||
{
|
||||
name = "fzf";
|
||||
inherit (pkgs.fishPlugins.fzf) src;
|
||||
}
|
||||
{
|
||||
name = "autopair";
|
||||
inherit (pkgs.fishPlugins.autopair) src;
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
programs.bash = {
|
||||
enable = true;
|
||||
initExtra = ''
|
||||
if [[ $(${pkgs.procps}/bin/ps --no-header --pid=$PPID --format=comm) != "fish" && -z ''${BASH_EXECUTION_STRING} ]]
|
||||
then
|
||||
shopt -q login_shell && LOGIN_OPTION='--login' || LOGIN_OPTION=""
|
||||
exec ${pkgs.fish}/bin/fish $LOGIN_OPTION
|
||||
fi
|
||||
'';
|
||||
};
|
||||
}
|
|
@ -1,30 +0,0 @@
|
|||
{
|
||||
programs.nushell = {
|
||||
enable = true;
|
||||
extraConfig = ''
|
||||
let carapace_completer = {|spans|
|
||||
carapace $spans.0 nushell ...$spans | from json
|
||||
}
|
||||
$env.config = {
|
||||
show_banner: false,
|
||||
completions: {
|
||||
case_sensitive: false # case-sensitive completions
|
||||
quick: true # set to false to prevent auto-selecting completions
|
||||
partial: true # set to false to prevent partial filling of the prompt
|
||||
algorithm: "fuzzy" # prefix or fuzzy
|
||||
external: {
|
||||
# set to false to prevent nushell looking into $env.PATH to find more suggestions
|
||||
enable: true
|
||||
# set to lower can improve completion performance at the cost of omitting some options
|
||||
max_results: 100
|
||||
completer: $carapace_completer # check 'carapace_completer'
|
||||
}
|
||||
}
|
||||
}
|
||||
'';
|
||||
};
|
||||
|
||||
programs.carapace = {
|
||||
enable = true;
|
||||
};
|
||||
}
|
|
@ -1,9 +0,0 @@
|
|||
{
|
||||
programs.starship = {
|
||||
enable = true;
|
||||
enableTransience = true;
|
||||
settings = {
|
||||
add_newline = true;
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,6 +0,0 @@
|
|||
{
|
||||
programs.zoxide = {
|
||||
enable = true;
|
||||
enableBashIntegration = false;
|
||||
};
|
||||
}
|
|
@ -6,20 +6,23 @@ in {
|
|||
./networking.nix # generated at runtime by nixos-infect
|
||||
|
||||
inputs.agenix.nixosModules.default
|
||||
|
||||
"${system}/services/forgejo.nix"
|
||||
"${system}/services/searx.nix"
|
||||
"${system}/services/portfolio.nix"
|
||||
];
|
||||
|
||||
local = {
|
||||
systemVars = {
|
||||
hostName = "anastacia";
|
||||
};
|
||||
|
||||
profiles.server.enable = true;
|
||||
};
|
||||
|
||||
boot.tmp.cleanOnBoot = true;
|
||||
zramSwap.enable = true;
|
||||
networking.hostName = "anastacia";
|
||||
networking.domain = "";
|
||||
services.openssh.enable = true;
|
||||
users.users.root.openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIEzs7SQH0Vjt9JHoXXmWy9fPU1I3rrRWV5magZFrI5al"
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIHKEPlN/GU9nJZPleA77HH5NA+6vyhhM84fTSjEwnEgq"
|
||||
];
|
||||
|
||||
system.stateVersion = "23.11";
|
||||
}
|
||||
|
|
|
@ -1,29 +1,23 @@
|
|||
{inputs, ...}: let
|
||||
lib' = import ../lib;
|
||||
lib' = import ../shared/lib inputs.nixpkgs.lib;
|
||||
mkSystem = args:
|
||||
inputs.nixpkgs.lib.nixosSystem {
|
||||
specialArgs = {inherit inputs lib';};
|
||||
modules = args.modules or [];
|
||||
modules = (args.modules or []) ++ [../modules];
|
||||
};
|
||||
in {
|
||||
vamos = mkSystem {
|
||||
modules = [
|
||||
./vamos
|
||||
../modules
|
||||
inputs.nixos-hardware.nixosModules.framework-13-7040-amd
|
||||
];
|
||||
};
|
||||
|
||||
solaire = mkSystem {
|
||||
modules = [
|
||||
./solaire
|
||||
../modules
|
||||
];
|
||||
modules = [./solaire];
|
||||
};
|
||||
|
||||
anastacia = mkSystem {
|
||||
modules = [
|
||||
./anastacia
|
||||
];
|
||||
modules = [./anastacia];
|
||||
};
|
||||
}
|
||||
|
|
|
@ -2,11 +2,13 @@
|
|||
hardware.graphics.enable = true;
|
||||
services.xserver.videoDrivers = ["nvidia"];
|
||||
hardware.nvidia = {
|
||||
open = false;
|
||||
modesetting.enable = true;
|
||||
powerManagement.enable = false;
|
||||
powerManagement.finegrained = false;
|
||||
open = true;
|
||||
powerManagement.enable = true;
|
||||
nvidiaSettings = true;
|
||||
package = config.boot.kernelPackages.nvidiaPackages.beta;
|
||||
};
|
||||
|
||||
# https://wiki.hyprland.org/Nvidia/#suspendwakeup-issues
|
||||
boot.kernelParams = ["nvidia.NVreg_PreserveVideoMemoryAllocations=1"];
|
||||
}
|
|
@ -1,5 +1,5 @@
|
|||
_: {
|
||||
theme = {
|
||||
local.style = {
|
||||
enable = true;
|
||||
wallpaper = ../../../assets/wallpapers/lucy-edgerunners-wallpaper.jpg;
|
||||
};
|
|
@ -1,56 +1,25 @@
|
|||
{
|
||||
inputs,
|
||||
specialArgs,
|
||||
...
|
||||
}: let
|
||||
system = "${inputs.self}/system";
|
||||
home = "${inputs.self}/home";
|
||||
in {
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./modules
|
||||
_: {
|
||||
imports = [./hardware-configuration.nix ./config/theme.nix ./config/nvidia.nix];
|
||||
|
||||
system
|
||||
"${system}/hardware/uni-sync.nix"
|
||||
|
||||
"${system}/programs/games.nix"
|
||||
"${system}/hardware/nvidia.nix"
|
||||
|
||||
"${system}/services/logind.nix"
|
||||
"${system}/services/greetd.nix"
|
||||
|
||||
"${system}/programs/hyprland.nix"
|
||||
"${system}/services/gnome.nix"
|
||||
|
||||
"${system}/services/documentation.nix"
|
||||
|
||||
"${system}/services/flatpak.nix"
|
||||
];
|
||||
|
||||
home-manager = {
|
||||
users.nezia.imports = [
|
||||
"${home}"
|
||||
"${home}/services/udiskie.nix"
|
||||
"${home}/programs/games"
|
||||
|
||||
"${home}/programs/waybar"
|
||||
"${home}/programs/fuzzel.nix"
|
||||
"${home}/programs/hypr"
|
||||
|
||||
"${home}/services/swaync"
|
||||
"${home}/programs/swaybg.nix"
|
||||
"${home}/programs/swaylock.nix"
|
||||
|
||||
"${home}/terminal/emulators/foot.nix"
|
||||
|
||||
"${home}/services/flatpak.nix"
|
||||
"${home}/services/syncthing.nix"
|
||||
|
||||
"${home}/programs/editors/neovim.nix"
|
||||
];
|
||||
extraSpecialArgs = specialArgs;
|
||||
local = {
|
||||
systemVars = {
|
||||
hostName = "solaire";
|
||||
username = "nezia";
|
||||
};
|
||||
homeVars = {
|
||||
fullName = "Anthony Rodriguez";
|
||||
email = "anthony@nezia.dev";
|
||||
};
|
||||
|
||||
profiles = {
|
||||
desktop.enable = true;
|
||||
gaming.enable = true;
|
||||
};
|
||||
|
||||
modules = {
|
||||
hyprland.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
networking.hostName = "solaire";
|
||||
environment.variables.FLAKE = "/home/nezia/.dotfiles";
|
||||
}
|
||||
|
|
|
@ -1,3 +0,0 @@
|
|||
{
|
||||
imports = [./theme.nix];
|
||||
}
|
9
hosts/vamos/config/theme.nix
Normal file
9
hosts/vamos/config/theme.nix
Normal file
|
@ -0,0 +1,9 @@
|
|||
{pkgs, ...}: {
|
||||
local.style = {
|
||||
enable = true;
|
||||
wallpaper = pkgs.fetchurl {
|
||||
url = "https://raw.githubusercontent.com/NixOS/nixos-artwork/refs/heads/master/wallpapers/nix-wallpaper-simple-dark-gray.png";
|
||||
hash = "sha256-JaLHdBxwrphKVherDVe5fgh+3zqUtpcwuNbjwrBlAok=";
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,55 +1,29 @@
|
|||
{
|
||||
inputs,
|
||||
specialArgs,
|
||||
...
|
||||
}: let
|
||||
system = "${inputs.self}/system";
|
||||
home = "${inputs.self}/home";
|
||||
in {
|
||||
_: {
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./modules
|
||||
|
||||
"${system}"
|
||||
"${system}/core/lanzaboote.nix"
|
||||
|
||||
"${system}/hardware/fprintd.nix"
|
||||
"${system}/services/power.nix"
|
||||
"${system}/services/brightness.nix"
|
||||
|
||||
"${system}/services/logind.nix"
|
||||
"${system}/services/greetd.nix"
|
||||
"${system}/services/kanata.nix"
|
||||
|
||||
"${system}/programs/hyprland.nix"
|
||||
"${system}/services/gnome.nix"
|
||||
"${system}/services/mail.nix"
|
||||
|
||||
"${system}/services/documentation.nix"
|
||||
./config/theme.nix
|
||||
];
|
||||
|
||||
home-manager = {
|
||||
users.nezia.imports = [
|
||||
"${home}"
|
||||
"${home}/services/udiskie.nix"
|
||||
|
||||
"${home}/programs/hypr"
|
||||
"${home}/programs/waybar"
|
||||
"${home}/programs/fuzzel.nix"
|
||||
|
||||
"${home}/services/swaync"
|
||||
"${home}/programs/swaybg.nix"
|
||||
"${home}/programs/wlogout.nix"
|
||||
|
||||
"${home}/services/syncthing.nix"
|
||||
|
||||
"${home}/programs/editors/neovim.nix"
|
||||
|
||||
"${home}/terminal/emulators/foot.nix"
|
||||
];
|
||||
extraSpecialArgs = specialArgs;
|
||||
local = {
|
||||
systemVars = {
|
||||
hostName = "vamos";
|
||||
username = "nezia";
|
||||
};
|
||||
|
||||
homeVars = {
|
||||
fullName = "Anthony Rodriguez";
|
||||
email = "anthony@nezia.dev";
|
||||
};
|
||||
|
||||
profiles = {
|
||||
desktop.enable = true;
|
||||
laptop.enable = true;
|
||||
};
|
||||
|
||||
modules = {
|
||||
hyprland.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
networking.hostName = "vamos";
|
||||
environment.variables.FLAKE = "/home/nezia/.dotfiles";
|
||||
}
|
||||
|
|
|
@ -1,3 +0,0 @@
|
|||
{
|
||||
imports = [./theme.nix];
|
||||
}
|
|
@ -1,9 +0,0 @@
|
|||
{pkgs, ...}: {
|
||||
theme = {
|
||||
enable = true;
|
||||
wallpaper = pkgs.fetchurl {
|
||||
url = "https://raw.githubusercontent.com/NixOS/nixos-artwork/e0cf0eb237dc5baba86661a3572b20a6183c1876/wallpapers/nix-wallpaper-nineish-catppuccin-frappe.png?raw=true";
|
||||
hash = "sha256-/HAtpGwLxjNfJvX5/4YZfM8jPNStaM3gisK8+ImRmQ4=";
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,60 +0,0 @@
|
|||
let
|
||||
# convert rrggbb hex to rgba(r, g, b, a)
|
||||
rgba = lib: color: opacity: let
|
||||
r = toString (hexToDec lib (builtins.substring 0 2 color));
|
||||
g = toString (hexToDec lib (builtins.substring 2 2 color));
|
||||
b = toString (hexToDec lib (builtins.substring 4 2 color));
|
||||
in "rgba(${r}, ${g}, ${b}, ${opacity})";
|
||||
|
||||
hexToDec = lib: v: let
|
||||
# Map of hex characters to their decimal values
|
||||
hexToInt = {
|
||||
"0" = 0;
|
||||
"1" = 1;
|
||||
"2" = 2;
|
||||
"3" = 3;
|
||||
"4" = 4;
|
||||
"5" = 5;
|
||||
"6" = 6;
|
||||
"7" = 7;
|
||||
"8" = 8;
|
||||
"9" = 9;
|
||||
"a" = 10;
|
||||
"b" = 11;
|
||||
"c" = 12;
|
||||
"d" = 13;
|
||||
"e" = 14;
|
||||
"f" = 15;
|
||||
"A" = 10;
|
||||
"B" = 11;
|
||||
"C" = 12;
|
||||
"D" = 13;
|
||||
"E" = 14;
|
||||
"F" = 15;
|
||||
};
|
||||
# Remove any leading `#` from the input
|
||||
cleanHex =
|
||||
if lib.strings.substring 0 1 v == "#"
|
||||
then lib.strings.substring 1 (builtins.stringLength v - 1) v
|
||||
else v;
|
||||
# Convert the cleaned string into characters
|
||||
chars = lib.strings.stringToCharacters cleanHex;
|
||||
in
|
||||
# Fold over the characters to calculate the decimal value
|
||||
builtins.foldl' (acc: char: acc * 16 + hexToInt."${char}") 0 chars;
|
||||
|
||||
blurImage = pkgs: path:
|
||||
pkgs.runCommand "${builtins.baseNameOf path}-blurred" {
|
||||
buildInputs = [pkgs.imagemagick];
|
||||
}
|
||||
''
|
||||
magick ${path} -gaussian-blur 0x12 "$out"
|
||||
'';
|
||||
|
||||
generateGtkColors = lib: palette: (lib.concatLines
|
||||
(lib.mapAttrsToList
|
||||
(name: color: "@define-color ${name} ${color};")
|
||||
palette));
|
||||
in {
|
||||
inherit blurImage generateGtkColors rgba;
|
||||
}
|
|
@ -1,3 +1,6 @@
|
|||
{
|
||||
imports = [./theme];
|
||||
imports = [
|
||||
./options
|
||||
./nix
|
||||
];
|
||||
}
|
||||
|
|
6
modules/hm/default.nix
Normal file
6
modules/hm/default.nix
Normal file
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
imports = [
|
||||
./programs
|
||||
./services
|
||||
];
|
||||
}
|
176
modules/hm/programs/browsers/firefox.nix
Normal file
176
modules/hm/programs/browsers/firefox.nix
Normal file
|
@ -0,0 +1,176 @@
|
|||
{
|
||||
lib,
|
||||
inputs,
|
||||
pkgs,
|
||||
osConfig,
|
||||
...
|
||||
}: let
|
||||
betterfox = pkgs.fetchFromGitHub {
|
||||
owner = "yokoffing";
|
||||
repo = "betterfox";
|
||||
rev = "e026ed7d3a763c5d3f96c2680d7bc3340831af4f";
|
||||
hash = "sha256-hpkEO5BhMVtINQG8HN4xqfas/R6q5pYPZiFK8bilIDs=";
|
||||
};
|
||||
in {
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
programs.firefox = {
|
||||
enable = true;
|
||||
package = pkgs.wrapFirefox pkgs.firefox-unwrapped {
|
||||
extraPolicies = {
|
||||
DisableTelemetry = true;
|
||||
DisablePocket = true;
|
||||
DisableFeedbackCommands = true;
|
||||
DisableFirefoxStudies = true;
|
||||
OfferToSaveLogins = false;
|
||||
OffertosaveloginsDefault = false;
|
||||
PasswordManagerEnabled = false;
|
||||
SearchSuggestEnabled = true;
|
||||
|
||||
# https://github.com/Sly-Harvey/NixOS/blob/f9da2691ea46565256ad757959cfc26ec6cee10d/modules/programs/browser/firefox/default.nix#L58-L163
|
||||
"3rdparty".Extensions = {
|
||||
"addon@darkreader.org" = {
|
||||
permissions = ["internal:privateBrowsingAllowed"];
|
||||
enabled = true;
|
||||
automation = {
|
||||
enabled = true;
|
||||
behavior = "OnOff";
|
||||
mode = "system";
|
||||
};
|
||||
detectDarkTheme = true;
|
||||
enabledByDefault = true;
|
||||
changeBrowserTheme = false;
|
||||
enableForProtectedPages = true;
|
||||
fetchNews = false;
|
||||
previewNewDesign = true;
|
||||
};
|
||||
"uBlock0@raymondhill.net" = {
|
||||
permissions = ["internal:privateBrowsingAllowed"];
|
||||
advancedSettings = [
|
||||
[
|
||||
"userResourcesLocation"
|
||||
"https://raw.githubusercontent.com/pixeltris/TwitchAdSolutions/master/video-swap-new/video-swap-new-ublock-origin.js"
|
||||
]
|
||||
];
|
||||
adminSettings = {
|
||||
userSettings = {
|
||||
uiTheme = "dark";
|
||||
advancedUserEnabled = true;
|
||||
userFiltersTrusted = true;
|
||||
importedLists = [
|
||||
"https://raw.githubusercontent.com/laylavish/uBlockOrigin-HUGE-AI-Blocklist/main/list.txt"
|
||||
];
|
||||
selectedFilterLists = [
|
||||
"FRA-0"
|
||||
"adguard-cookies"
|
||||
"adguard-mobile-app-banners"
|
||||
"adguard-other-annoyances"
|
||||
"adguard-popup-overlays"
|
||||
"adguard-social"
|
||||
"adguard-spyware-url"
|
||||
"adguard-widgets"
|
||||
"easylist"
|
||||
"easylist-annoyances"
|
||||
"easylist-chat"
|
||||
"easylist-newsletters"
|
||||
"easylist-notifications"
|
||||
"easyprivacy"
|
||||
"fanboy-cookiemonster"
|
||||
"https://filters.adtidy.org/extension/ublock/filters/3.txt"
|
||||
"https://github.com/DandelionSprout/adfilt/raw/master/LegitimateURLShortener.txt"
|
||||
"plowe-0"
|
||||
"ublock-annoyances"
|
||||
"ublock-badware"
|
||||
"ublock-cookies-adguard"
|
||||
"ublock-cookies-easylist"
|
||||
"ublock-filters"
|
||||
"ublock-privacy"
|
||||
"ublock-quick-fixes"
|
||||
"ublock-unbreak"
|
||||
"urlhaus-1"
|
||||
"https://raw.githubusercontent.com/laylavish/uBlockOrigin-HUGE-AI-Blocklist/main/list.txt"
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
profiles = {
|
||||
nezia = {
|
||||
settings = {
|
||||
"browser.search.suggest.enabled" = true;
|
||||
"ui.key.menuAccessKeyFocuses" = false;
|
||||
};
|
||||
|
||||
extensions = with inputs.firefox-addons.packages.${pkgs.system}; [
|
||||
darkreader
|
||||
proton-pass
|
||||
shinigami-eyes
|
||||
stylus
|
||||
ublock-origin
|
||||
violentmonkey
|
||||
];
|
||||
# https://git.jacekpoz.pl/poz/niksos/src/commit/a48647a1c5bc6877a1100a65f4dc169b2fc11ed7/hosts/hape/firefox.nix
|
||||
search = {
|
||||
force = true;
|
||||
default = "SearxNG";
|
||||
engines = {
|
||||
"SearxNG" = {
|
||||
urls = [
|
||||
{
|
||||
rels = ["results"];
|
||||
template = "https://search.nezia.dev/search";
|
||||
params = [
|
||||
{
|
||||
name = "q";
|
||||
value = "{searchTerms}";
|
||||
}
|
||||
];
|
||||
}
|
||||
{
|
||||
rels = ["suggestions"];
|
||||
template = "https://search.nezia.dev/autocompleter";
|
||||
params = [
|
||||
{
|
||||
name = "q";
|
||||
value = "{searchTerms}";
|
||||
}
|
||||
];
|
||||
"type" = "application/x-suggestions+json";
|
||||
}
|
||||
];
|
||||
};
|
||||
"MyNixOS" = {
|
||||
urls = [{template = "https://mynixos.com/search?q={searchTerms}";}];
|
||||
iconUpdateURL = "https://mynixos.com/favicon.ico";
|
||||
updateInterval = 24 * 60 * 60 * 1000;
|
||||
definedAliases = ["@nx"];
|
||||
};
|
||||
"Noogle" = {
|
||||
urls = [{template = "https://noogle.dev/q?term={searchTerms}";}];
|
||||
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
|
||||
definedAliases = ["@ng"];
|
||||
};
|
||||
"GitHub Nix" = {
|
||||
# https://github.com/search?q=language%3Anix+NOT+is%3Afork+programs.neovim&type=code
|
||||
urls = [{template = "https://github.com/search?q=language:nix NOT is:fork {searchTerms}&type=code";}];
|
||||
iconUpdateURL = "https://github.com/favicon.ico";
|
||||
updateInterval = 24 * 60 * 60 * 1000;
|
||||
definedAliases = ["@ghn"];
|
||||
};
|
||||
"Google".metaData.alias = "@g"; # builtin engines only support specifying one additional alias
|
||||
};
|
||||
};
|
||||
# https://github.com/oddlama/nix-config/blob/main/users/myuser/graphical/firefox.nix#L53-L57
|
||||
extraConfig = builtins.concatStringsSep "\n" [
|
||||
(builtins.readFile "${betterfox}/user.js")
|
||||
(builtins.readFile "${betterfox}/Securefox.js")
|
||||
(builtins.readFile "${betterfox}/Fastfox.js")
|
||||
(builtins.readFile "${betterfox}/Peskyfox.js")
|
||||
(builtins.readFile "${betterfox}/Smoothfox.js")
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
17
modules/hm/programs/default.nix
Normal file
17
modules/hm/programs/default.nix
Normal file
|
@ -0,0 +1,17 @@
|
|||
{
|
||||
imports = [
|
||||
./browsers
|
||||
./editors
|
||||
./hypr
|
||||
./media
|
||||
./terminal
|
||||
|
||||
./games.nix
|
||||
./gnome.nix
|
||||
./misc.nix
|
||||
./walker.nix
|
||||
./waybar.nix
|
||||
./wlogout.nix
|
||||
./xdg.nix
|
||||
];
|
||||
}
|
6
modules/hm/programs/editors/default.nix
Normal file
6
modules/hm/programs/editors/default.nix
Normal file
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
imports = [
|
||||
./helix.nix
|
||||
./neovim.nix
|
||||
];
|
||||
}
|
64
modules/hm/programs/editors/helix.nix
Normal file
64
modules/hm/programs/editors/helix.nix
Normal file
|
@ -0,0 +1,64 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
programs.helix = {
|
||||
enable = true;
|
||||
settings = {
|
||||
theme = "catppuccin_macchiato";
|
||||
editor = {
|
||||
line-number = "relative";
|
||||
lsp.display-messages = true;
|
||||
auto-format = true;
|
||||
auto-completion = true;
|
||||
completion-timeout = 5;
|
||||
color-modes = true;
|
||||
completion-trigger-len = 1;
|
||||
completion-replace = true;
|
||||
cursorline = true;
|
||||
cursor-shape = {
|
||||
insert = "bar";
|
||||
normal = "block";
|
||||
select = "underline";
|
||||
};
|
||||
indent-guides.render = true;
|
||||
lsp.display-inlay-hints = true;
|
||||
statusline.center = ["position-percentage"];
|
||||
true-color = true;
|
||||
whitespace.characters = {
|
||||
newline = "↴";
|
||||
tab = "⇥";
|
||||
};
|
||||
};
|
||||
|
||||
keys.normal = {
|
||||
space = {
|
||||
space = "file_picker";
|
||||
w = ":w";
|
||||
q = ":q";
|
||||
};
|
||||
esc = ["collapse_selection" "keep_primary_selection"];
|
||||
};
|
||||
};
|
||||
|
||||
languages = {
|
||||
language = [
|
||||
{
|
||||
name = "nix";
|
||||
auto-format = true;
|
||||
}
|
||||
];
|
||||
|
||||
language-server = {
|
||||
nil = {
|
||||
command = lib.getExe pkgs.nil;
|
||||
config.nil.formatting.command = ["${lib.getExe pkgs.alejandra}" "-q"];
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
250
modules/hm/programs/editors/neovim.nix
Normal file
250
modules/hm/programs/editors/neovim.nix
Normal file
|
@ -0,0 +1,250 @@
|
|||
{
|
||||
lib,
|
||||
inputs,
|
||||
pkgs,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
imports = [inputs.nvf.homeManagerModules.default];
|
||||
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
programs.nvf = {
|
||||
enable = true;
|
||||
settings.vim = {
|
||||
viAlias = true;
|
||||
vimAlias = true;
|
||||
enableLuaLoader = true;
|
||||
preventJunkFiles = true;
|
||||
useSystemClipboard = true;
|
||||
options = {
|
||||
tabstop = 4;
|
||||
autoindent = false;
|
||||
};
|
||||
|
||||
luaConfigPost = ''
|
||||
vim.opt.formatoptions:remove('c')
|
||||
vim.opt.formatoptions:remove('r')
|
||||
vim.opt.formatoptions:remove('o')
|
||||
'';
|
||||
|
||||
maps = {
|
||||
normal = {
|
||||
"<leader>m" = {
|
||||
silent = true;
|
||||
action = "<cmd>make<CR>";
|
||||
}; # Same as nnoremap <leader>m <silent> <cmd>make<CR>
|
||||
"<leader>t" = {
|
||||
silent = true;
|
||||
action = "<cmd>Neotree toggle<CR>";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
theme = lib.mkDefault {
|
||||
enable = true;
|
||||
name = "catppuccin";
|
||||
style = "macchiato";
|
||||
};
|
||||
|
||||
ui = {
|
||||
noice.enable = true;
|
||||
};
|
||||
notify.nvim-notify.enable = true;
|
||||
|
||||
statusline = {
|
||||
lualine = {
|
||||
enable = true;
|
||||
theme = "auto";
|
||||
componentSeparator = {
|
||||
left = "";
|
||||
};
|
||||
sectionSeparator = {
|
||||
left = "";
|
||||
right = "";
|
||||
};
|
||||
|
||||
activeSection = {
|
||||
a = [
|
||||
''
|
||||
{
|
||||
"mode",
|
||||
separator = { right = "" },
|
||||
right_padding = 2
|
||||
}
|
||||
''
|
||||
];
|
||||
b = [
|
||||
''
|
||||
{
|
||||
"branch",
|
||||
icon = '',
|
||||
separator = { right = "" }
|
||||
}
|
||||
''
|
||||
];
|
||||
c = [
|
||||
''
|
||||
"filename"
|
||||
''
|
||||
];
|
||||
x = [
|
||||
''
|
||||
{
|
||||
"diagnostics",
|
||||
sources = {'nvim_lsp', 'nvim_diagnostic', 'nvim_diagnostic', 'vim_lsp', 'coc'},
|
||||
symbols = {error = ' ', warn = ' ', info = ' ', hint = ' '},
|
||||
colored = true,
|
||||
update_in_insert = false,
|
||||
always_visible = false,
|
||||
diagnostics_color = {
|
||||
color_error = { fg = 'red' },
|
||||
color_warn = { fg = 'yellow' },
|
||||
color_info = { fg = 'cyan' },
|
||||
},
|
||||
}
|
||||
''
|
||||
''
|
||||
"filetype"
|
||||
''
|
||||
];
|
||||
y = [
|
||||
''
|
||||
{
|
||||
"progress",
|
||||
separator = { left = "" },
|
||||
}
|
||||
''
|
||||
''
|
||||
''
|
||||
];
|
||||
z = [
|
||||
''
|
||||
{
|
||||
"location",
|
||||
separator = { left = "" },
|
||||
left_padding = 2
|
||||
}
|
||||
''
|
||||
''
|
||||
{
|
||||
"fileformat",
|
||||
color = {fg='black'},
|
||||
symbols = {
|
||||
unix = '', -- e712
|
||||
dos = '', -- e70f
|
||||
mac = '', -- e711
|
||||
},
|
||||
}
|
||||
''
|
||||
];
|
||||
};
|
||||
|
||||
inactiveSection = {
|
||||
a = [
|
||||
''
|
||||
"filename"
|
||||
''
|
||||
];
|
||||
z = [
|
||||
''
|
||||
"location"
|
||||
''
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
git.enable = true;
|
||||
|
||||
utility = {
|
||||
vim-wakatime.enable = true;
|
||||
surround.enable = true;
|
||||
motion.leap = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
lsp = {
|
||||
enable = true;
|
||||
lspSignature.enable = true;
|
||||
lspconfig.enable = true;
|
||||
formatOnSave = true;
|
||||
mappings = {
|
||||
addWorkspaceFolder = "<leader>wa";
|
||||
codeAction = "<leader>a";
|
||||
goToDeclaration = "gD";
|
||||
goToDefinition = "gd";
|
||||
hover = "K";
|
||||
listImplementations = "gi";
|
||||
listReferences = "gr";
|
||||
listWorkspaceFolders = "<leader>wl";
|
||||
nextDiagnostic = "<leader>k";
|
||||
previousDiagnostic = "<leader>j";
|
||||
openDiagnosticFloat = "<leader>e";
|
||||
removeWorkspaceFolder = "<leader>wr";
|
||||
renameSymbol = "<leader>r";
|
||||
signatureHelp = "<C-k>";
|
||||
};
|
||||
};
|
||||
|
||||
autocomplete.nvim-cmp = {
|
||||
enable = true;
|
||||
};
|
||||
|
||||
autopairs.nvim-autopairs.enable = true;
|
||||
|
||||
languages = {
|
||||
enableExtraDiagnostics = true;
|
||||
enableFormat = true;
|
||||
enableLSP = true;
|
||||
enableTreesitter = true;
|
||||
|
||||
nix.enable = true;
|
||||
clang.enable = true;
|
||||
python.enable = true;
|
||||
ts.enable = true;
|
||||
css.enable = true;
|
||||
typst.enable = true;
|
||||
};
|
||||
|
||||
treesitter = {
|
||||
enable = true;
|
||||
fold = true;
|
||||
context.enable = true;
|
||||
grammars = [
|
||||
pkgs.vimPlugins.nvim-treesitter.builtGrammars.nix
|
||||
pkgs.vimPlugins.nvim-treesitter.builtGrammars.c
|
||||
pkgs.vimPlugins.nvim-treesitter.builtGrammars.python
|
||||
];
|
||||
};
|
||||
|
||||
binds.whichKey.enable = true;
|
||||
filetree.neo-tree.enable = true;
|
||||
|
||||
telescope.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
programs.neovide = {
|
||||
enable = true;
|
||||
settings = {
|
||||
fork = false;
|
||||
frame = "full";
|
||||
idle = true;
|
||||
maximized = false;
|
||||
no-multigrid = false;
|
||||
srgb = false;
|
||||
tabs = true;
|
||||
theme = "auto";
|
||||
title-hidden = true;
|
||||
vsync = true;
|
||||
wsl = false;
|
||||
|
||||
font = {
|
||||
normal = [];
|
||||
size = 14.0;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
17
modules/hm/programs/games.nix
Normal file
17
modules/hm/programs/games.nix
Normal file
|
@ -0,0 +1,17 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.profiles.gaming.enable {
|
||||
home.packages = [
|
||||
pkgs.mangohud
|
||||
pkgs.bolt-launcher
|
||||
pkgs.ankama-launcher
|
||||
pkgs.lutris
|
||||
pkgs.qbittorrent
|
||||
pkgs.protonplus
|
||||
];
|
||||
};
|
||||
}
|
16
modules/hm/programs/gnome.nix
Normal file
16
modules/hm/programs/gnome.nix
Normal file
|
@ -0,0 +1,16 @@
|
|||
{
|
||||
lib,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
dconf = {
|
||||
enable = true;
|
||||
settings = {
|
||||
"org/gnome/desktop/wm/preferences" = {
|
||||
button-layout = "";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -3,5 +3,6 @@ _: {
|
|||
./land
|
||||
./idle.nix
|
||||
./lock.nix
|
||||
./paper.nix
|
||||
];
|
||||
}
|
58
modules/hm/programs/hypr/idle.nix
Normal file
58
modules/hm/programs/hypr/idle.nix
Normal file
|
@ -0,0 +1,58 @@
|
|||
{
|
||||
lib,
|
||||
inputs,
|
||||
pkgs,
|
||||
config,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.modules.hyprland.enable {
|
||||
services.hypridle = {
|
||||
enable = true;
|
||||
|
||||
package = inputs.hypridle.packages.${pkgs.system}.hypridle;
|
||||
|
||||
settings = {
|
||||
general = {
|
||||
lock_cmd = "pidof hyprlock || hyprlock";
|
||||
unlock_cmd = "pkill --signal SIGUSR1 hyprlock";
|
||||
before_sleep_cmd = "loginctl lock-session";
|
||||
after_sleep_cmd = "hyprctl dispatch dpms on";
|
||||
};
|
||||
|
||||
listener = [
|
||||
{
|
||||
timeout = 300; # 5m
|
||||
on-timeout = "loginctl lock-session";
|
||||
}
|
||||
{
|
||||
timeout = 330; # 5.5m
|
||||
on-timeout = "hyprctl dipsatch dpms off";
|
||||
on-resume = "hyprctl dispatch dpms on";
|
||||
}
|
||||
{
|
||||
timeout = 600; # 10m
|
||||
on-timeout = "systemctl suspend";
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
# needed when using uwsm as the session manager
|
||||
systemd.user.services."hypridle" = lib.mkForce {
|
||||
Unit = {
|
||||
Description = "Hyprland's Idle Daemon";
|
||||
After = "graphical-session.target";
|
||||
X-Restart-Triggers = ["${config.xdg.configFile."hypr/hypridle.conf".source}"];
|
||||
};
|
||||
Service = {
|
||||
Type = "exec";
|
||||
ExecStart = lib.getExe pkgs.hypridle;
|
||||
Restart = "on-failure";
|
||||
Slice = "background-graphical.slice";
|
||||
};
|
||||
Install = {
|
||||
WantedBy = ["graphical-session.target"];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
85
modules/hm/programs/hypr/land/binds.nix
Normal file
85
modules/hm/programs/hypr/land/binds.nix
Normal file
|
@ -0,0 +1,85 @@
|
|||
{
|
||||
lib,
|
||||
osConfig,
|
||||
...
|
||||
}: let
|
||||
# thanks https://github.com/fufexan/dotfiles/blob/c0b3c77d95ce1f574a87e7f7ead672ca0d951245/home/programs/wayland/hyprland/binds.nix#L16-L20
|
||||
toggle = program: uwsm: let
|
||||
prog = builtins.substring 0 14 program;
|
||||
in "pkill ${prog} || ${lib.optionalString uwsm "uwsm app -- "} ${program}";
|
||||
runOnce = program: "pgrep ${program} || uwsm app -- ${program}";
|
||||
run = program: "uwsm app -- ${program}";
|
||||
in {
|
||||
config = lib.mkIf osConfig.local.modules.hyprland.enable {
|
||||
wayland.windowManager.hyprland.settings = {
|
||||
"$mod" = "SUPER";
|
||||
bindr = [
|
||||
"$mod, SUPER_L, exec, walker"
|
||||
];
|
||||
bind = [
|
||||
"$mod, Return, exec, ${run "foot"}"
|
||||
"$mod, n, exec, ${run "neovide"}"
|
||||
"$mod, w, exec, ${run "firefox"}"
|
||||
", Print, exec, ${runOnce "grimblast"} --notify --cursor copysave output"
|
||||
"$mod, q, killactive"
|
||||
"$mod SHIFT, q, exec, loginctl terminate-user ''"
|
||||
"$mod, period, exec, ${toggle "walker -m emojis" false}" # not using uwsm as it already runs as a service
|
||||
"CTRL, Print, exec, ${runOnce "grimblast"} --notify --cursor --freeze copysave area"
|
||||
|
||||
"$mod, h, movefocus, l"
|
||||
"$mod, j, movefocus, d"
|
||||
"$mod, k, movefocus, u"
|
||||
"$mod, l, movefocus, r"
|
||||
|
||||
"$mod SHIFT, h, movewindow, l"
|
||||
"$mod SHIFT, j, movewindow, d"
|
||||
"$mod SHIFT, k, movewindow, u"
|
||||
"$mod SHIFT, l, movewindow, r"
|
||||
|
||||
"$mod, 1, workspace, 1"
|
||||
"$mod, 2, workspace, 2"
|
||||
"$mod, 3, workspace, 3"
|
||||
"$mod, 4, workspace, 4"
|
||||
"$mod, 5, workspace, 5"
|
||||
"$mod, 6, workspace, 6"
|
||||
"$mod, 7, workspace, 7"
|
||||
"$mod, 8, workspace, 8"
|
||||
"$mod, 9, workspace, 9"
|
||||
"$mod, 0, workspace, 10"
|
||||
|
||||
"$mod SHIFT, 1, movetoworkspacesilent, 1"
|
||||
"$mod SHIFT, 2, movetoworkspacesilent, 2"
|
||||
"$mod SHIFT, 3, movetoworkspacesilent, 3"
|
||||
"$mod SHIFT, 4, movetoworkspacesilent, 4"
|
||||
"$mod SHIFT, 5, movetoworkspacesilent, 5"
|
||||
"$mod SHIFT, 6, movetoworkspacesilent, 6"
|
||||
"$mod SHIFT, 7, movetoworkspacesilent, 7"
|
||||
"$mod SHIFT, 8, movetoworkspacesilent, 8"
|
||||
"$mod SHIFT, 9, movetoworkspacesilent, 9"
|
||||
"$mod SHIFT, 0, movetoworkspacesilent, 10"
|
||||
|
||||
"$mod, t, togglefloating"
|
||||
", F11, fullscreen, 0"
|
||||
"$mod, f, fullscreen, 1"
|
||||
|
||||
"$mod, e, togglespecialworkspace, file_manager_tui"
|
||||
"$mod SHIFT, e, togglespecialworkspace, file_manager_gui"
|
||||
|
||||
", XF86PowerOff, exec, ${toggle "wlogout" true}"
|
||||
];
|
||||
|
||||
bindel = [
|
||||
", XF86AudioRaiseVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+"
|
||||
", XF86AudioLowerVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-"
|
||||
", XF86AudioMute, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle"
|
||||
|
||||
", XF86MonBrightnessUp, exec, brillo -q -u 300000 -A 5"
|
||||
", XF86MonBrightnessDown, exec, brillo -q -u 300000 -U 5"
|
||||
", XF86AudioMedia, exec, XDG_CURRENT_DESKTOP=gnome gnome-control-center"
|
||||
];
|
||||
binde = [
|
||||
"$mod Alt, l, exec, loginctl lock-session"
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
119
modules/hm/programs/hypr/land/default.nix
Normal file
119
modules/hm/programs/hypr/land/default.nix
Normal file
|
@ -0,0 +1,119 @@
|
|||
{
|
||||
lib,
|
||||
inputs,
|
||||
pkgs,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
imports = [./binds.nix];
|
||||
|
||||
config = lib.mkIf osConfig.local.modules.hyprland.enable {
|
||||
home.packages = [
|
||||
inputs.hyprwm-contrib.packages.${pkgs.system}.grimblast
|
||||
# disable unused panels - https://github.com/maydayv7/dotfiles/blob/4de45008a6915753834aa7e1cbafbacfff8b7adc/modules/gui/desktop/hyprland/apps/utilities.nix#L42-L57
|
||||
(pkgs.gnome-control-center.overrideAttrs (old: {
|
||||
postInstall =
|
||||
old.postInstall
|
||||
+ ''
|
||||
dir=$out/share/applications
|
||||
for panel in $dir/*
|
||||
do
|
||||
[ "$panel" = "$dir/gnome-network-panel.desktop" ] && continue
|
||||
[ "$panel" = "$dir/gnome-bluetooth-panel.desktop" ] && continue
|
||||
[ "$panel" = "$dir/gnome-wifi-panel.desktop" ] && continue
|
||||
[ "$panel" = "$dir/gnome-wwan-panel.desktop" ] && continue
|
||||
[ "$panel" = "$dir/gnome-sharing-panel.desktop" ] && continue
|
||||
[ "$panel" = "$dir/gnome-wacom-panel.desktop" ] && continue
|
||||
rm "$panel"
|
||||
done
|
||||
'';
|
||||
}))
|
||||
];
|
||||
wayland.windowManager.hyprland = {
|
||||
enable = true;
|
||||
xwayland.enable = true;
|
||||
|
||||
systemd.enable = false;
|
||||
|
||||
settings = {
|
||||
xwayland = {
|
||||
force_zero_scaling = true;
|
||||
};
|
||||
|
||||
env = [
|
||||
"GDK_SCALE,1"
|
||||
];
|
||||
|
||||
cursor = {
|
||||
no_hardware_cursors = 1;
|
||||
};
|
||||
|
||||
monitor = [
|
||||
"eDP-1, preferred, auto, 1.33"
|
||||
];
|
||||
workspace = [
|
||||
"special:terminal, on-created-empty:foot"
|
||||
"special:mixer_gui, on-created-empty:pavucontrol"
|
||||
"special:file_manager_gui, on-created-empty:nautilus"
|
||||
"special:file_manager_tui, on-created-empty:foot -- yazi"
|
||||
];
|
||||
|
||||
windowrulev2 = [
|
||||
# fixes fullscreen windows (mostly games)
|
||||
"stayfocused, initialtitle:^()$, initialclass:^(steam)$"
|
||||
"minsize 1 1, initialtitle:^()$, initialclass:^(steam)$"
|
||||
"maximize, initialtitle:^(\S+)$, initialclass:^(steamwebhelper)$"
|
||||
|
||||
"immediate, initialclass:^(steam_app_)(.*)$"
|
||||
"fullscreen, initialclass:^(steam_app_)(.*)$"
|
||||
|
||||
# inhibit idle on every fullscreen app except games
|
||||
"idleinhibit always, fullscreen:1,!initialclass:^(steam_app_)(.*)$"
|
||||
];
|
||||
|
||||
render = {
|
||||
explicit_sync = 1;
|
||||
explicit_sync_kms = 1;
|
||||
expand_undersized_textures = false;
|
||||
};
|
||||
|
||||
animations = {
|
||||
enabled = true;
|
||||
bezier = "myBezier, 0.05, 0.9, 0.1, 1.1";
|
||||
animation = [
|
||||
"windows, 1, 5, myBezier"
|
||||
"windowsOut, 1, 5, default, popin 80%"
|
||||
"windowsMove, 1, 5, default, popin 80%"
|
||||
"fade, 1, 5, default"
|
||||
"border, 1, 5, default"
|
||||
"borderangle, 0, 8, default"
|
||||
"workspaces, 0"
|
||||
"specialWorkspace, 0"
|
||||
];
|
||||
};
|
||||
|
||||
input = {
|
||||
kb_options = "compose:ralt";
|
||||
touchpad = {
|
||||
natural_scroll = true;
|
||||
scroll_factor = 0.8;
|
||||
tap-to-click = true;
|
||||
clickfinger_behavior = true;
|
||||
};
|
||||
};
|
||||
|
||||
gestures = {
|
||||
workspace_swipe = true;
|
||||
workspace_swipe_direction_lock = false;
|
||||
workspace_swipe_cancel_ratio = 0.15;
|
||||
};
|
||||
|
||||
misc = {
|
||||
force_default_wallpaper = 0;
|
||||
disable_hyprland_logo = true;
|
||||
middle_click_paste = false;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
14
modules/hm/programs/hypr/lock.nix
Normal file
14
modules/hm/programs/hypr/lock.nix
Normal file
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
lib,
|
||||
inputs,
|
||||
pkgs,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.modules.hyprland.enable {
|
||||
programs.hyprlock = {
|
||||
enable = true;
|
||||
package = inputs.hyprlock.packages.${pkgs.system}.hyprlock;
|
||||
};
|
||||
};
|
||||
}
|
22
modules/hm/programs/hypr/paper.nix
Normal file
22
modules/hm/programs/hypr/paper.nix
Normal file
|
@ -0,0 +1,22 @@
|
|||
{
|
||||
lib,
|
||||
osConfig,
|
||||
inputs,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.modules.hyprland.enable {
|
||||
services.hyprpaper = {
|
||||
enable = true;
|
||||
package = inputs.hyprpaper.packages.${pkgs.system}.default;
|
||||
|
||||
settings = {
|
||||
preload = ["${osConfig.local.style.wallpaper}"];
|
||||
wallpaper = [", ${osConfig.local.style.wallpaper}"];
|
||||
};
|
||||
};
|
||||
|
||||
systemd.user.services.hyprpaper.Unit.After = lib.mkForce "graphical-session.target";
|
||||
systemd.user.services.hyprpaper.Service.Slice = "background-graphical.slice";
|
||||
};
|
||||
}
|
20
modules/hm/programs/media/default.nix
Normal file
20
modules/hm/programs/media/default.nix
Normal file
|
@ -0,0 +1,20 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
imports = [./zathura.nix];
|
||||
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
programs.mpv.enable = true;
|
||||
home.packages = [
|
||||
pkgs.gnome-calculator
|
||||
pkgs.gthumb
|
||||
pkgs.spotify
|
||||
pkgs.stremio
|
||||
pkgs.tidal-hifi
|
||||
pkgs.celluloid
|
||||
];
|
||||
};
|
||||
}
|
23
modules/hm/programs/media/zathura.nix
Normal file
23
modules/hm/programs/media/zathura.nix
Normal file
|
@ -0,0 +1,23 @@
|
|||
{
|
||||
lib,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
programs.zathura = {
|
||||
enable = true;
|
||||
options = {
|
||||
font = "Inter 12";
|
||||
selection-notification = true;
|
||||
|
||||
selection-clipboard = "clipboard";
|
||||
adjust-open = "best-fit";
|
||||
pages-per-row = "1";
|
||||
scroll-page-aware = "true";
|
||||
scroll-full-overlap = "0.01";
|
||||
scroll-step = "100";
|
||||
zoom-min = "10";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
40
modules/hm/programs/misc.nix
Normal file
40
modules/hm/programs/misc.nix
Normal file
|
@ -0,0 +1,40 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
# miscellaneous programs that do not need to be configured
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
home.packages = with pkgs; [
|
||||
cinny-desktop
|
||||
entr
|
||||
fractal
|
||||
geary
|
||||
imhex
|
||||
logisim-evolution
|
||||
mission-center
|
||||
nautilus
|
||||
obsidian
|
||||
playerctl
|
||||
proton-pass
|
||||
simple-scan
|
||||
vesktop
|
||||
wl-clipboard
|
||||
];
|
||||
|
||||
programs = {
|
||||
fzf.enable = true;
|
||||
fastfetch.enable = true;
|
||||
hyfetch = {
|
||||
enable = true;
|
||||
settings = {
|
||||
preset = "nonbinary";
|
||||
mode = "rgb";
|
||||
backend = "fastfetch";
|
||||
color_align.mode = "horizontal";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
17
modules/hm/programs/terminal/default.nix
Normal file
17
modules/hm/programs/terminal/default.nix
Normal file
|
@ -0,0 +1,17 @@
|
|||
{
|
||||
lib,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
./emulators
|
||||
./programs
|
||||
./shell
|
||||
];
|
||||
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
home.sessionVariables = {
|
||||
EDITOR = "nvim";
|
||||
};
|
||||
};
|
||||
}
|
3
modules/hm/programs/terminal/emulators/default.nix
Normal file
3
modules/hm/programs/terminal/emulators/default.nix
Normal file
|
@ -0,0 +1,3 @@
|
|||
{
|
||||
imports = [./foot.nix];
|
||||
}
|
19
modules/hm/programs/terminal/emulators/foot.nix
Normal file
19
modules/hm/programs/terminal/emulators/foot.nix
Normal file
|
@ -0,0 +1,19 @@
|
|||
{
|
||||
lib,
|
||||
config,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.modules.hyprland.enable {
|
||||
programs.foot = {
|
||||
enable = true;
|
||||
settings = {
|
||||
main = {
|
||||
term = "xterm-256color";
|
||||
font = "monospace:size=14";
|
||||
shell = "${lib.getExe config.programs.fish.package}";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
26
modules/hm/programs/terminal/programs/bat.nix
Normal file
26
modules/hm/programs/terminal/programs/bat.nix
Normal file
|
@ -0,0 +1,26 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
programs.bat = {
|
||||
enable = true;
|
||||
config.theme = "base16";
|
||||
};
|
||||
|
||||
home = {
|
||||
sessionVariables = {
|
||||
MANPAGER = "sh -c 'col -bx | bat --language man' ";
|
||||
MANROFFOPT = "-c";
|
||||
};
|
||||
|
||||
packages = with pkgs.bat-extras; [
|
||||
batman
|
||||
];
|
||||
|
||||
shellAliases.man = "batman";
|
||||
};
|
||||
};
|
||||
}
|
12
modules/hm/programs/terminal/programs/default.nix
Normal file
12
modules/hm/programs/terminal/programs/default.nix
Normal file
|
@ -0,0 +1,12 @@
|
|||
{
|
||||
imports = [
|
||||
./bat.nix
|
||||
./direnv.nix
|
||||
./git.nix
|
||||
./gnupg.nix
|
||||
./misc.nix
|
||||
./nix-index.nix
|
||||
./tmux.nix
|
||||
./yazi.nix
|
||||
];
|
||||
}
|
14
modules/hm/programs/terminal/programs/direnv.nix
Normal file
14
modules/hm/programs/terminal/programs/direnv.nix
Normal file
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
lib,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
programs = {
|
||||
direnv = {
|
||||
enable = true;
|
||||
nix-direnv.enable = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
60
modules/hm/programs/terminal/programs/git.nix
Normal file
60
modules/hm/programs/terminal/programs/git.nix
Normal file
|
@ -0,0 +1,60 @@
|
|||
{
|
||||
lib,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
programs.git = {
|
||||
enable = true;
|
||||
userName = "Anthony Rodriguez";
|
||||
userEmail = "anthony@nezia.dev";
|
||||
signing = {
|
||||
signByDefault = true;
|
||||
key = "EE3BE97C040A86CE";
|
||||
};
|
||||
extraConfig = {
|
||||
push.autoSetupRemote = true;
|
||||
init = {
|
||||
defaultBranch = "main";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
programs.lazygit = {
|
||||
enable = true;
|
||||
};
|
||||
|
||||
home.shellAliases = {
|
||||
lg = "lazygit";
|
||||
g = "git";
|
||||
gs = "git status";
|
||||
gsh = "git show HEAD";
|
||||
gshs = "DELTA_FEATURES=+side-by-side git show HEAD";
|
||||
ga = "git add";
|
||||
gaa = "git add :/";
|
||||
gap = "git add -p";
|
||||
gc = "git commit";
|
||||
gca = "git commit --amend";
|
||||
gcm = "git commit --message";
|
||||
gcf = "git commit --fixup";
|
||||
gk = "git checkout";
|
||||
gkp = "git checkout -p";
|
||||
gd = "git diff";
|
||||
gds = "DELTA_FEATURES=+side-by-side git diff";
|
||||
gdc = "git diff --cached";
|
||||
gdcs = "DELTA_FEATURES=+side-by-side git diff --cached";
|
||||
gf = "git fetch";
|
||||
gl = "git log";
|
||||
glp = "git log -p";
|
||||
glps = "DELTA_FEATURES=+side-by-side git log -p";
|
||||
gp = "git push";
|
||||
gpf = "git push --force-with-lease";
|
||||
gr = "git reset";
|
||||
gra = "git reset :/";
|
||||
grp = "git reset -p";
|
||||
gt = "git stash";
|
||||
gtp = "git stash pop";
|
||||
gu = "git pull";
|
||||
};
|
||||
};
|
||||
}
|
14
modules/hm/programs/terminal/programs/gnupg.nix
Normal file
14
modules/hm/programs/terminal/programs/gnupg.nix
Normal file
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
lib,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
programs.gpg.enable = true;
|
||||
services.gpg-agent = {
|
||||
enable = true;
|
||||
enableBashIntegration = true;
|
||||
enableFishIntegration = true;
|
||||
};
|
||||
};
|
||||
}
|
20
modules/hm/programs/terminal/programs/misc.nix
Normal file
20
modules/hm/programs/terminal/programs/misc.nix
Normal file
|
@ -0,0 +1,20 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
home.packages = with pkgs; [
|
||||
# archives
|
||||
zip
|
||||
unzip
|
||||
unrar
|
||||
|
||||
# utils
|
||||
fd
|
||||
file
|
||||
ripgrep
|
||||
];
|
||||
};
|
||||
}
|
19
modules/hm/programs/terminal/programs/nix-index.nix
Normal file
19
modules/hm/programs/terminal/programs/nix-index.nix
Normal file
|
@ -0,0 +1,19 @@
|
|||
{
|
||||
lib,
|
||||
inputs,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
imports = [inputs.nix-index-db.hmModules.nix-index];
|
||||
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
programs = {
|
||||
nix-index = {
|
||||
enable = true;
|
||||
symlinkToCacheHome = true; # needed for comma
|
||||
};
|
||||
command-not-found.enable = false;
|
||||
nix-index-database.comma.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
30
modules/hm/programs/terminal/programs/tmux.nix
Normal file
30
modules/hm/programs/terminal/programs/tmux.nix
Normal file
|
@ -0,0 +1,30 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
programs.tmux = {
|
||||
enable = true;
|
||||
prefix = "C-space";
|
||||
escapeTime = 10;
|
||||
clock24 = true;
|
||||
keyMode = "vi";
|
||||
mouse = true;
|
||||
baseIndex = 1;
|
||||
extraConfig = ''
|
||||
set-option -a terminal-features "''${TERM}:RGB"
|
||||
bind c new-window -c "#{pane_current_path}"
|
||||
bind '"' split-window -v -c "#{pane_current_path}"
|
||||
bind '%' split-window -h -c "#{pane_current_path}"
|
||||
bind C-k clear-history
|
||||
'';
|
||||
plugins = with pkgs; [
|
||||
tmuxPlugins.vim-tmux-navigator
|
||||
tmuxPlugins.yank
|
||||
];
|
||||
};
|
||||
programs.fzf.tmux.enableShellIntegration = true;
|
||||
};
|
||||
}
|
33
modules/hm/programs/terminal/programs/yazi.nix
Normal file
33
modules/hm/programs/terminal/programs/yazi.nix
Normal file
|
@ -0,0 +1,33 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.modules.hyprland.enable {
|
||||
programs.yazi = let
|
||||
# https://github.com/iynaix/dotfiles/blob/8bb1568019ea26f034ac1af9c499b3ff102391a5/home-manager/shell/yazi.nix#L9-L11
|
||||
mkYaziPlugin = name: text: {
|
||||
"${name}" = toString (pkgs.writeTextDir "${name}.yazi/init.lua" text) + "/${name}.yazi";
|
||||
};
|
||||
in {
|
||||
enable = true;
|
||||
enableFishIntegration = true;
|
||||
plugins = mkYaziPlugin "smart-enter" ''
|
||||
return {
|
||||
entry = function()
|
||||
local h = cx.active.current.hovered
|
||||
ya.manager_emit(h and h.cha.is_dir and "enter" or "open", { hovered = true })
|
||||
end,
|
||||
}
|
||||
'';
|
||||
keymap.manager.prepend_keymap = [
|
||||
{
|
||||
on = "l";
|
||||
run = "plugin --sync smart-enter";
|
||||
desc = "Enter the child directory, or open the file";
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,8 +1,7 @@
|
|||
{
|
||||
imports = [
|
||||
./fish.nix
|
||||
./starship.nix
|
||||
./zoxide.nix
|
||||
./nushell.nix
|
||||
./fish.nix
|
||||
];
|
||||
}
|
51
modules/hm/programs/terminal/shell/fish.nix
Normal file
51
modules/hm/programs/terminal/shell/fish.nix
Normal file
|
@ -0,0 +1,51 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
config,
|
||||
osConfig,
|
||||
...
|
||||
}: let
|
||||
starshipTransient = lib.strings.optionalString config.programs.starship.enableTransience ''
|
||||
function starship_transient_prompt_func
|
||||
starship module character
|
||||
end
|
||||
|
||||
function starship_transient_rprompt_func
|
||||
starship module cmd_duration
|
||||
end
|
||||
'';
|
||||
in {
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
programs.fish = {
|
||||
enable = true;
|
||||
interactiveShellInit =
|
||||
starshipTransient
|
||||
+ ''
|
||||
set fish_greeting # Disable greeting
|
||||
fish_vi_key_bindings # Enable Vi mode
|
||||
|
||||
'';
|
||||
plugins = [
|
||||
{
|
||||
name = "fzf";
|
||||
inherit (pkgs.fishPlugins.fzf) src;
|
||||
}
|
||||
{
|
||||
name = "autopair";
|
||||
inherit (pkgs.fishPlugins.autopair) src;
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
programs.bash = {
|
||||
enable = true;
|
||||
initExtra = ''
|
||||
if [[ $(${pkgs.procps}/bin/ps --no-header --pid=$PPID --format=comm) != "fish" && -z ''${BASH_EXECUTION_STRING} ]]
|
||||
then
|
||||
shopt -q login_shell && LOGIN_OPTION='--login' || LOGIN_OPTION=""
|
||||
exec ${pkgs.fish}/bin/fish $LOGIN_OPTION
|
||||
fi
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
15
modules/hm/programs/terminal/shell/starship.nix
Normal file
15
modules/hm/programs/terminal/shell/starship.nix
Normal file
|
@ -0,0 +1,15 @@
|
|||
{
|
||||
lib,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
programs.starship = {
|
||||
enable = true;
|
||||
enableTransience = true;
|
||||
settings = {
|
||||
add_newline = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
12
modules/hm/programs/terminal/shell/zoxide.nix
Normal file
12
modules/hm/programs/terminal/shell/zoxide.nix
Normal file
|
@ -0,0 +1,12 @@
|
|||
{
|
||||
lib,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
programs.zoxide = {
|
||||
enable = true;
|
||||
enableBashIntegration = false;
|
||||
};
|
||||
};
|
||||
}
|
35
modules/hm/programs/walker.nix
Normal file
35
modules/hm/programs/walker.nix
Normal file
|
@ -0,0 +1,35 @@
|
|||
{
|
||||
lib,
|
||||
inputs,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
inputs.walker.homeManagerModules.default
|
||||
];
|
||||
config = lib.mkIf osConfig.local.modules.hyprland.enable {
|
||||
programs.walker = {
|
||||
enable = true;
|
||||
runAsService = true;
|
||||
# All options from the config.json can be used here.
|
||||
config = {
|
||||
list = {
|
||||
height = 200;
|
||||
};
|
||||
app_launch_prefix = "uwsm app -- ";
|
||||
websearch.prefix = "?";
|
||||
switcher.prefix = "/";
|
||||
};
|
||||
};
|
||||
|
||||
systemd.user.services.walker = {
|
||||
Unit = {
|
||||
PartOf = lib.mkForce [];
|
||||
After = lib.mkForce ["graphical-session.target"];
|
||||
};
|
||||
Service = {
|
||||
Slice = lib.mkForce "background-graphical.slice";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
190
modules/hm/programs/waybar.nix
Normal file
190
modules/hm/programs/waybar.nix
Normal file
|
@ -0,0 +1,190 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.modules.hyprland.enable {
|
||||
programs.waybar = {
|
||||
enable = true;
|
||||
systemd.enable = true;
|
||||
settings = {
|
||||
mainBar = {
|
||||
layer = "top";
|
||||
position = "top";
|
||||
|
||||
modules-left = [
|
||||
"hyprland/window"
|
||||
"pulseaudio"
|
||||
"cpu"
|
||||
"memory"
|
||||
"idle_inhibitor"
|
||||
];
|
||||
|
||||
modules-center = ["hyprland/workspaces"];
|
||||
modules-right = [
|
||||
"custom/swaync"
|
||||
"custom/power"
|
||||
"network"
|
||||
"battery"
|
||||
"tray"
|
||||
"clock"
|
||||
];
|
||||
|
||||
tray = {
|
||||
icon-size = 16;
|
||||
spacing = 12;
|
||||
};
|
||||
|
||||
battery = {
|
||||
interval = 10;
|
||||
states = {
|
||||
warning = 30;
|
||||
critical = 15;
|
||||
};
|
||||
format = "{icon} {capacity}%";
|
||||
format-charging = " {capacity}% - {time}";
|
||||
format-full = " {capacity}% - Full";
|
||||
format-icons = [
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
];
|
||||
max-length = 25;
|
||||
};
|
||||
|
||||
"pulseaudio" = {
|
||||
format = "{icon} {volume}%";
|
||||
format-bluetooth = "{icon} {volume}%";
|
||||
format-muted = "";
|
||||
format-icons = {
|
||||
"alsa_output.pci-0000_00_1f.3.analog-stereo" = "";
|
||||
"alsa_output.pci-0000_00_1f.3.analog-stereo-muted" = "";
|
||||
headphone = "";
|
||||
hands-free = "";
|
||||
headset = "";
|
||||
phone = "";
|
||||
phone-muted = "";
|
||||
portable = "";
|
||||
car = "";
|
||||
default = [
|
||||
""
|
||||
""
|
||||
];
|
||||
};
|
||||
scroll-step = 1;
|
||||
on-click = "pavucontrol";
|
||||
ignored-sinks = [
|
||||
"Easy Effects Sink"
|
||||
];
|
||||
};
|
||||
|
||||
"power-profiles-daemon" = {
|
||||
format-icons = {
|
||||
default = "";
|
||||
performance = "";
|
||||
balanced = "";
|
||||
power-saver = "";
|
||||
};
|
||||
};
|
||||
|
||||
"custom/power" = {
|
||||
format = "";
|
||||
tooltip = false;
|
||||
on-click = lib.getExe pkgs.wlogout;
|
||||
};
|
||||
|
||||
"memory" = {
|
||||
interval = 5;
|
||||
format = " {}%";
|
||||
tooltip = true;
|
||||
};
|
||||
|
||||
"cpu" = {
|
||||
interval = 5;
|
||||
format = " {usage:2}%";
|
||||
tooltip = true;
|
||||
};
|
||||
|
||||
"idle_inhibitor" = {
|
||||
format = "{icon}";
|
||||
format-icons = {
|
||||
activated = "";
|
||||
deactivated = "";
|
||||
};
|
||||
tooltip = "true";
|
||||
};
|
||||
|
||||
"clock" = {
|
||||
format = " {:L%H:%M}";
|
||||
tooltip = true;
|
||||
tooltip-format = "<big>{:%A, %d.%B %Y }</big>\n<tt><small>{calendar}</small></tt>";
|
||||
};
|
||||
|
||||
"network" = {
|
||||
format-icons = [
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
];
|
||||
format-ethernet = " {bandwidthDownOctets}";
|
||||
format-wifi = "{icon} {signalStrength}%";
|
||||
format-disconnected = "";
|
||||
tooltip = false;
|
||||
on-click = "XDG_CURRENT_DESKTOP=gnome gnome-control-center";
|
||||
};
|
||||
|
||||
"hyprland/window" = {
|
||||
max-length = 22;
|
||||
separate-outputs = false;
|
||||
};
|
||||
|
||||
"hyprland/workspaces" = {
|
||||
format = "{name}";
|
||||
format-icons = {
|
||||
default = " ";
|
||||
active = " ";
|
||||
urgent = " ";
|
||||
};
|
||||
on-scroll-up = "hyprctl dispatch workspace e+1";
|
||||
on-scroll-down = "hyprctl dispatch workspace e-1";
|
||||
};
|
||||
|
||||
"custom/swaync" = {
|
||||
tooltip = false;
|
||||
format = "<big>{icon}</big>";
|
||||
format-icons = {
|
||||
none = "";
|
||||
notification = "<span foreground='red'><sup></sup></span>";
|
||||
dnd-notification = "<span foreground='red'><sup></sup></span>";
|
||||
dnd-none = "";
|
||||
inhibited-notification = "<span foreground='red'><sup></sup></span>";
|
||||
inhibited-none = "";
|
||||
dnd-inhibited-notification = "<span foreground='red'><sup></sup></span>";
|
||||
dnd-inhibited-none = "";
|
||||
};
|
||||
return-type = "json";
|
||||
escape = true;
|
||||
exec-if = "which ${pkgs.swaynotificationcenter}/bin/swaync-client";
|
||||
exec = "${pkgs.swaynotificationcenter}/bin/swaync-client --subscribe-waybar";
|
||||
on-click = "${pkgs.swaynotificationcenter}/bin/swaync-client --toggle-panel --skip-wait";
|
||||
on-click-middle = "${pkgs.swaynotificationcenter}/bin/swaync-client --toggle-dnd --skip-wait";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
systemd.user.services.waybar = {
|
||||
Unit.After = lib.mkForce "graphical-session.target";
|
||||
Service.Slice = "app-graphical.slice";
|
||||
};
|
||||
|
||||
home.packages = [
|
||||
pkgs.pavucontrol
|
||||
];
|
||||
};
|
||||
}
|
69
modules/hm/programs/wlogout.nix
Normal file
69
modules/hm/programs/wlogout.nix
Normal file
|
@ -0,0 +1,69 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
config,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.modules.hyprland.enable {
|
||||
programs.wlogout = {
|
||||
enable = true;
|
||||
|
||||
layout = let
|
||||
systemd = let
|
||||
systemd = lib.getExe' pkgs.systemd;
|
||||
in {
|
||||
loginctl = systemd "loginctl";
|
||||
systemctl = systemd "systemctl";
|
||||
};
|
||||
in [
|
||||
{
|
||||
action = "${systemd.loginctl} lock-session";
|
||||
keybind = "l";
|
||||
label = "lock";
|
||||
text = "Lock";
|
||||
}
|
||||
|
||||
{
|
||||
action = "${systemd.systemctl} hibernate";
|
||||
keybind = "h";
|
||||
label = "hibernate";
|
||||
text = "Hibernate";
|
||||
}
|
||||
|
||||
{
|
||||
action = "${
|
||||
systemd.loginctl
|
||||
} terminate-user ${
|
||||
config.home.username
|
||||
}";
|
||||
|
||||
keybind = "q";
|
||||
label = "logout";
|
||||
text = "Logout";
|
||||
}
|
||||
|
||||
{
|
||||
action = "${systemd.systemctl} poweroff";
|
||||
keybind = "p";
|
||||
label = "shutdown";
|
||||
text = "Shutdown";
|
||||
}
|
||||
|
||||
{
|
||||
action = "${systemd.systemctl} suspend";
|
||||
keybind = "s";
|
||||
label = "suspend";
|
||||
text = "Suspend";
|
||||
}
|
||||
|
||||
{
|
||||
action = "${systemd.systemctl} reboot";
|
||||
keybind = "r";
|
||||
label = "reboot";
|
||||
text = "Reboot";
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
42
modules/hm/programs/xdg.nix
Normal file
42
modules/hm/programs/xdg.nix
Normal file
|
@ -0,0 +1,42 @@
|
|||
{
|
||||
lib,
|
||||
config,
|
||||
osConfig,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||
xdg = {
|
||||
enable = true;
|
||||
cacheHome = config.home.homeDirectory + "/.local/cache";
|
||||
|
||||
mimeApps = {
|
||||
enable = true;
|
||||
defaultApplications = {
|
||||
"default-web-browser" = ["firefox.desktop"];
|
||||
"text/html" = ["firefox.desktop"];
|
||||
"x-scheme-handler/http" = ["firefox.desktop"];
|
||||
"x-scheme-handler/https" = ["firefox.desktop"];
|
||||
"x-scheme-handler/about" = ["firefox.desktop"];
|
||||
"x-scheme-handler/unknown" = ["firefox.desktop"];
|
||||
"x-scheme-handler/chrome" = ["chromium-browser.desktop"];
|
||||
"inode/directory" = ["yazi.desktop"];
|
||||
"application/pdf" = ["org.pwmt.zathura-pdf-mupdf.desktop"];
|
||||
"image/png" = ["org.gnome.gThumb.desktop"];
|
||||
"image/svg" = [" org.gnome.gThumb.desktop"];
|
||||
"image/jpeg" = ["org.gnome.gThumb.desktop"];
|
||||
"image/gif" = [" org.gnome.gThumb.desktop"];
|
||||
"video/mp4" = ["io.github.celluloid_player.Celluloid.desktop"];
|
||||
"video/avi" = ["io.github.celluloid_player.Celluloid.desktop"];
|
||||
"video/mkv" = ["io.github.celluloid_player.Celluloid.desktop"];
|
||||
};
|
||||
};
|
||||
userDirs = {
|
||||
enable = true;
|
||||
createDirectories = true;
|
||||
extraConfig = {
|
||||
XDG_SCREENSHOTS_DIR = "${config.xdg.userDirs.pictures}/Screenshots";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
8
modules/hm/services/default.nix
Normal file
8
modules/hm/services/default.nix
Normal file
|
@ -0,0 +1,8 @@
|
|||
{
|
||||
imports = [
|
||||
./gammastep.nix
|
||||
./syncthing.nix
|
||||
./swaync
|
||||
./udiskie.nix
|
||||
];
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue