treewide: add ironbar for niri

This commit is contained in:
Anthony Rodriguez 2024-11-13 23:19:57 +01:00
parent f8fef1e4ff
commit 587708328d
Signed by: nezia
GPG key ID: EE3BE97C040A86CE
8 changed files with 193 additions and 51 deletions

View file

@ -63,6 +63,21 @@
} }
}, },
"crane": { "crane": {
"locked": {
"lastModified": 1730060262,
"narHash": "sha256-RMgSVkZ9H03sxC+Vh4jxtLTCzSjPq18UWpiM0gq6shQ=",
"owner": "ipetkov",
"repo": "crane",
"rev": "498d9f122c413ee1154e8131ace5a35a80d8fa76",
"type": "github"
},
"original": {
"owner": "ipetkov",
"repo": "crane",
"type": "github"
}
},
"crane_2": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
"lanzaboote", "lanzaboote",
@ -419,9 +434,32 @@
"type": "github" "type": "github"
} }
}, },
"lanzaboote": { "ironbar": {
"inputs": { "inputs": {
"crane": "crane", "crane": "crane",
"naersk": "naersk",
"nixpkgs": [
"nixpkgs"
],
"rust-overlay": "rust-overlay"
},
"locked": {
"lastModified": 1731364081,
"narHash": "sha256-7E1dh2H+36AJBO7PCHhLLEuxr2HDaEa6nif14pOoJXY=",
"owner": "JakeStanger",
"repo": "ironbar",
"rev": "a76957216b27f7d23128a02740cad2d78d9e4de6",
"type": "github"
},
"original": {
"owner": "JakeStanger",
"repo": "ironbar",
"type": "github"
}
},
"lanzaboote": {
"inputs": {
"crane": "crane_2",
"flake-compat": "flake-compat_3", "flake-compat": "flake-compat_3",
"flake-parts": "flake-parts_2", "flake-parts": "flake-parts_2",
"flake-utils": "flake-utils_2", "flake-utils": "flake-utils_2",
@ -429,7 +467,7 @@
"nixpkgs" "nixpkgs"
], ],
"pre-commit-hooks-nix": "pre-commit-hooks-nix", "pre-commit-hooks-nix": "pre-commit-hooks-nix",
"rust-overlay": "rust-overlay" "rust-overlay": "rust-overlay_2"
}, },
"locked": { "locked": {
"lastModified": 1718178907, "lastModified": 1718178907,
@ -479,6 +517,24 @@
} }
}, },
"naersk": { "naersk": {
"inputs": {
"nixpkgs": "nixpkgs_4"
},
"locked": {
"lastModified": 1721727458,
"narHash": "sha256-r/xppY958gmZ4oTfLiHN0ZGuQ+RSTijDblVgVLFi1mw=",
"owner": "nix-community",
"repo": "naersk",
"rev": "3fb418eaf352498f6b6c30592e3beb63df42ef11",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "naersk",
"type": "github"
}
},
"naersk_2": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
"nvf", "nvf",
@ -510,7 +566,7 @@
"nvf", "nvf",
"nixpkgs" "nixpkgs"
], ],
"rust-overlay": "rust-overlay_2" "rust-overlay": "rust-overlay_3"
}, },
"locked": { "locked": {
"lastModified": 1714571717, "lastModified": 1714571717,
@ -530,7 +586,7 @@
"inputs": { "inputs": {
"niri-stable": "niri-stable", "niri-stable": "niri-stable",
"niri-unstable": "niri-unstable", "niri-unstable": "niri-unstable",
"nixpkgs": "nixpkgs_4", "nixpkgs": "nixpkgs_5",
"nixpkgs-stable": "nixpkgs-stable_2", "nixpkgs-stable": "nixpkgs-stable_2",
"xwayland-satellite-stable": "xwayland-satellite-stable", "xwayland-satellite-stable": "xwayland-satellite-stable",
"xwayland-satellite-unstable": "xwayland-satellite-unstable" "xwayland-satellite-unstable": "xwayland-satellite-unstable"
@ -689,6 +745,22 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs_10": {
"locked": {
"lastModified": 1726871744,
"narHash": "sha256-V5LpfdHyQkUF7RfOaDPrZDP+oqz88lTJrMT1+stXNwo=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "a1d92660c6b3b7c26fb883500a80ea9d33321be2",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixpkgs-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1715266358, "lastModified": 1715266358,
@ -723,18 +795,16 @@
}, },
"nixpkgs_4": { "nixpkgs_4": {
"locked": { "locked": {
"lastModified": 1731139594, "lastModified": 1730272153,
"narHash": "sha256-IigrKK3vYRpUu+HEjPL/phrfh7Ox881er1UEsZvw9Q4=", "narHash": "sha256-B5WRZYsRlJgwVHIV6DvidFN7VX7Fg9uuwkRW9Ha8z+w=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "76612b17c0ce71689921ca12d9ffdc9c23ce40b2", "rev": "2d2a9ddbe3f2c00747398f3dc9b05f7f2ebb0f53",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "NixOS", "id": "nixpkgs",
"ref": "nixos-unstable", "type": "indirect"
"repo": "nixpkgs",
"type": "github"
} }
}, },
"nixpkgs_5": { "nixpkgs_5": {
@ -754,6 +824,22 @@
} }
}, },
"nixpkgs_6": { "nixpkgs_6": {
"locked": {
"lastModified": 1731139594,
"narHash": "sha256-IigrKK3vYRpUu+HEjPL/phrfh7Ox881er1UEsZvw9Q4=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "76612b17c0ce71689921ca12d9ffdc9c23ce40b2",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_7": {
"locked": { "locked": {
"lastModified": 1726871744, "lastModified": 1726871744,
"narHash": "sha256-V5LpfdHyQkUF7RfOaDPrZDP+oqz88lTJrMT1+stXNwo=", "narHash": "sha256-V5LpfdHyQkUF7RfOaDPrZDP+oqz88lTJrMT1+stXNwo=",
@ -769,7 +855,7 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs_7": { "nixpkgs_8": {
"locked": { "locked": {
"lastModified": 1656753965, "lastModified": 1656753965,
"narHash": "sha256-BCrB3l0qpJokOnIVc3g2lHiGhnjUi0MoXiw6t1o8H1E=", "narHash": "sha256-BCrB3l0qpJokOnIVc3g2lHiGhnjUi0MoXiw6t1o8H1E=",
@ -785,7 +871,7 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs_8": { "nixpkgs_9": {
"locked": { "locked": {
"lastModified": 1711404521, "lastModified": 1711404521,
"narHash": "sha256-cYhDZ3RYLiXAi4LQDGuQjjDDbtP00Wd/Vjal/jWyTuA=", "narHash": "sha256-cYhDZ3RYLiXAi4LQDGuQjjDDbtP00Wd/Vjal/jWyTuA=",
@ -801,22 +887,6 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs_9": {
"locked": {
"lastModified": 1726871744,
"narHash": "sha256-V5LpfdHyQkUF7RfOaDPrZDP+oqz88lTJrMT1+stXNwo=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "a1d92660c6b3b7c26fb883500a80ea9d33321be2",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixpkgs-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nmd": { "nmd": {
"flake": false, "flake": false,
"locked": { "locked": {
@ -839,7 +909,7 @@
"flake-utils": "flake-utils_3", "flake-utils": "flake-utils_3",
"mnw": "mnw", "mnw": "mnw",
"nil": "nil", "nil": "nil",
"nixpkgs": "nixpkgs_6", "nixpkgs": "nixpkgs_7",
"nmd": "nmd", "nmd": "nmd",
"plugin-alpha-nvim": "plugin-alpha-nvim", "plugin-alpha-nvim": "plugin-alpha-nvim",
"plugin-bufdelete-nvim": "plugin-bufdelete-nvim", "plugin-bufdelete-nvim": "plugin-bufdelete-nvim",
@ -2618,7 +2688,7 @@
}, },
"portfolio": { "portfolio": {
"inputs": { "inputs": {
"nixpkgs": "nixpkgs_8" "nixpkgs": "nixpkgs_9"
}, },
"locked": { "locked": {
"lastModified": 1730891412, "lastModified": 1730891412,
@ -2663,8 +2733,8 @@
}, },
"rnix-lsp": { "rnix-lsp": {
"inputs": { "inputs": {
"naersk": "naersk", "naersk": "naersk_2",
"nixpkgs": "nixpkgs_7", "nixpkgs": "nixpkgs_8",
"utils": "utils_2" "utils": "utils_2"
}, },
"locked": { "locked": {
@ -2689,11 +2759,12 @@
"deploy-rs": "deploy-rs", "deploy-rs": "deploy-rs",
"firefox-addons": "firefox-addons", "firefox-addons": "firefox-addons",
"home-manager": "home-manager_2", "home-manager": "home-manager_2",
"ironbar": "ironbar",
"lanzaboote": "lanzaboote", "lanzaboote": "lanzaboote",
"niri": "niri", "niri": "niri",
"nix-index-db": "nix-index-db", "nix-index-db": "nix-index-db",
"nixos-hardware": "nixos-hardware", "nixos-hardware": "nixos-hardware",
"nixpkgs": "nixpkgs_5", "nixpkgs": "nixpkgs_6",
"nvf": "nvf", "nvf": "nvf",
"plasma-manager": "plasma-manager", "plasma-manager": "plasma-manager",
"portfolio": "portfolio", "portfolio": "portfolio",
@ -2703,6 +2774,27 @@
} }
}, },
"rust-overlay": { "rust-overlay": {
"inputs": {
"nixpkgs": [
"ironbar",
"nixpkgs"
]
},
"locked": {
"lastModified": 1730341826,
"narHash": "sha256-RFaeY7EWzXOmAL2IQEACbnrEza3TgD5UQApHR4hGHhY=",
"owner": "oxalica",
"repo": "rust-overlay",
"rev": "815d1b3ee71716fc91a7bd149801e1f04d45fbc5",
"type": "github"
},
"original": {
"owner": "oxalica",
"repo": "rust-overlay",
"type": "github"
}
},
"rust-overlay_2": {
"inputs": { "inputs": {
"flake-utils": [ "flake-utils": [
"lanzaboote", "lanzaboote",
@ -2727,7 +2819,7 @@
"type": "github" "type": "github"
} }
}, },
"rust-overlay_2": { "rust-overlay_3": {
"inputs": { "inputs": {
"flake-utils": [ "flake-utils": [
"nvf", "nvf",
@ -2754,7 +2846,7 @@
"type": "github" "type": "github"
} }
}, },
"rust-overlay_3": { "rust-overlay_4": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
"wezterm", "wezterm",
@ -2897,7 +2989,7 @@
}, },
"treefmt-nix": { "treefmt-nix": {
"inputs": { "inputs": {
"nixpkgs": "nixpkgs_9" "nixpkgs": "nixpkgs_10"
}, },
"locked": { "locked": {
"lastModified": 1730321837, "lastModified": 1730321837,
@ -2955,7 +3047,7 @@
"nixpkgs": [ "nixpkgs": [
"nixpkgs" "nixpkgs"
], ],
"rust-overlay": "rust-overlay_3", "rust-overlay": "rust-overlay_4",
"zlib": "zlib" "zlib": "zlib"
}, },
"locked": { "locked": {

View file

@ -13,6 +13,7 @@
eachSystem = f: nixpkgs.lib.genAttrs (import systems) (system: f nixpkgs.legacyPackages.${system}); eachSystem = f: nixpkgs.lib.genAttrs (import systems) (system: f nixpkgs.legacyPackages.${system});
treefmtEval = eachSystem (pkgs: treefmt-nix.lib.evalModule pkgs ./treefmt.nix); treefmtEval = eachSystem (pkgs: treefmt-nix.lib.evalModule pkgs ./treefmt.nix);
in { in {
imports = [./modules];
devShells = eachSystem (pkgs: { devShells = eachSystem (pkgs: {
default = pkgs.mkShell { default = pkgs.mkShell {
packages = [ packages = [
@ -24,7 +25,6 @@
}; };
}); });
formatter = eachSystem (pkgs: treefmtEval.${pkgs.system}.config.build.wrapper); formatter = eachSystem (pkgs: treefmtEval.${pkgs.system}.config.build.wrapper);
nixosModules = import ./modules;
nixosConfigurations = let nixosConfigurations = let
lib' = import ./lib {inherit inputs lib';}; lib' = import ./lib {inherit inputs lib';};
in in
@ -58,15 +58,17 @@
ags.url = "github:Aylur/ags"; ags.url = "github:Aylur/ags";
basix.url = "github:notashelf/basix"; basix.url = "github:notashelf/basix";
deploy-rs.url = "github:serokell/deploy-rs"; deploy-rs.url = "github:serokell/deploy-rs";
ironbar = {
url = "github:JakeStanger/ironbar";
inputs.nixpkgs.follows = "nixpkgs";
};
firefox-addons = { firefox-addons = {
url = "gitlab:rycee/nur-expressions?dir=pkgs/firefox-addons"; url = "gitlab:rycee/nur-expressions?dir=pkgs/firefox-addons";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
niri.url = "github:sodiboo/niri-flake"; niri.url = "github:sodiboo/niri-flake";
nvf.url = "github:notashelf/nvf"; nvf.url = "github:notashelf/nvf";
portfolio.url = "github:nezia1/portfolio"; portfolio.url = "github:nezia1/portfolio";
plasma-manager = { plasma-manager = {
url = "github:nix-community/plasma-manager"; url = "github:nix-community/plasma-manager";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";

View file

@ -0,0 +1,36 @@
{inputs, ...}: {
imports = [inputs.ironbar.homeManagerModules.default];
programs.ironbar = {
enable = true;
systemd = true;
config = {
position = "top";
anchor_to_edges = true;
center = [
{
type = "focused";
show_icon = true;
show_title = true;
icon_size = 20;
truncate = "end";
}
];
end = [
{type = "volume";}
{type = "clock";}
{type = "tray";}
];
};
style = ''
.tray {
margin-top: 5px;
padding: 10px;
border-radius: 50px;
}
.tray .item {
border-radius: 50px;
min-height: 25px;
padding: 0;
'';
};
}

View file

@ -7,6 +7,7 @@
... ...
}: let }: let
colors = inputs.basix.schemeData.base16.${osConfig.theme.scheme}.palette; colors = inputs.basix.schemeData.base16.${osConfig.theme.scheme}.palette;
inherit (lib) getExe mkIf;
in { in {
imports = [./binds.nix]; imports = [./binds.nix];
@ -91,6 +92,10 @@ in {
"DISPLAY" = ":0"; "DISPLAY" = ":0";
"_JAVA_AWT_WM_NONREPARENTING" = "1"; # https://wiki.archlinux.org/title/Sway#Java_applications "_JAVA_AWT_WM_NONREPARENTING" = "1"; # https://wiki.archlinux.org/title/Sway#Java_applications
}; };
spawn-at-startup = [
(mkIf config.programs.ironbar.enable {command = [(getExe inputs.ironbar.packages.${pkgs.system}.default)];})
];
}; };
}; };

View file

@ -9,7 +9,7 @@ in {
system = "x86_64-linux"; system = "x86_64-linux";
modules = [ modules = [
./vamos ./vamos
inputs.self.nixosModules.theme ../modules
inputs.nixos-hardware.nixosModules.framework-13-7040-amd inputs.nixos-hardware.nixosModules.framework-13-7040-amd
]; ];
}; };
@ -18,7 +18,7 @@ in {
system = "x86_64-linux"; system = "x86_64-linux";
modules = [ modules = [
./solaire ./solaire
inputs.self.nixosModules.theme ../modules
]; ];
}; };

View file

@ -28,7 +28,7 @@ in {
"${home}/services/udiskie.nix" "${home}/services/udiskie.nix"
"${home}/programs/niri" "${home}/programs/niri"
"${home}/programs/ags" "${home}/programs/ironbar"
"${home}/programs/fuzzel.nix" "${home}/programs/fuzzel.nix"
"${home}/programs/swaybg.nix" "${home}/programs/swaybg.nix"
"${home}/programs/swaylock.nix" "${home}/programs/swaylock.nix"

View file

@ -1,3 +1,3 @@
{ {
theme = import ./theme; imports = [./theme];
} }

View file

@ -1,19 +1,26 @@
{pkgs, ...}: { {pkgs, ...}: {
fonts = { fonts = {
fontDir = {
enable = true;
decompressFonts = true;
};
packages = with pkgs; [ packages = with pkgs; [
noto-fonts noto-fonts
noto-fonts-cjk-sans noto-fonts-cjk-sans
noto-fonts-emoji noto-fonts-emoji
noto-fonts-extra noto-fonts-extra
(nerdfonts.override {fonts = ["IntelOneMono"];}) intel-one-mono
]; ];
enableDefaultPackages = false; enableDefaultPackages = false;
fontconfig.defaultFonts = { fontconfig = {
enable = true;
defaultFonts = {
serif = ["Noto Serif"]; serif = ["Noto Serif"];
sansSerif = ["Inter"]; sansSerif = ["Inter Medium"];
monospace = ["IntoneMono NF"]; monospace = ["Intel One Mono"];
emoji = ["Noto Color Emoji"]; emoji = ["Noto Color Emoji"];
}; };
}; };
};
} }