mirror of
https://github.com/Zedfrigg/ironbar.git
synced 2025-08-17 06:41:03 +02:00
refactor(nix): use flake-parts
and flake-compat
- redefine `{default,shell}.nix` to derive from `flake.nix` (using `flake-compat`) - use `flake-parts`' `_module.args.pkgs` machinery to apply overlays (instead of `pkgsFor`) - extract `homeManagerModule` to `nix/module.nix` - rename package at `nix/default.nix` to `nix/package.nix` Co-authored-by: reo101 <pavel.atanasov2001@gmail.com>
This commit is contained in:
parent
5c2f290fb1
commit
5affad3400
6 changed files with 272 additions and 208 deletions
36
shell.nix
36
shell.nix
|
@ -1,23 +1,13 @@
|
|||
{ pkgs ? import <nixpkgs> {} }:
|
||||
|
||||
pkgs.mkShell {
|
||||
buildInputs = with pkgs; [
|
||||
cargo
|
||||
clippy
|
||||
rustfmt
|
||||
gtk3
|
||||
gtk-layer-shell
|
||||
gcc
|
||||
openssl
|
||||
libdbusmenu-gtk3
|
||||
libpulseaudio
|
||||
libinput
|
||||
libevdev
|
||||
luajit
|
||||
luajitPackages.lgi
|
||||
];
|
||||
|
||||
nativeBuildInputs = with pkgs; [
|
||||
pkg-config
|
||||
];
|
||||
}
|
||||
(import
|
||||
(
|
||||
let
|
||||
lock = builtins.fromJSON (builtins.readFile ./flake.lock);
|
||||
nodeName = lock.nodes.root.inputs.flake-compat;
|
||||
in
|
||||
fetchTarball {
|
||||
url = lock.nodes.${nodeName}.locked.url or "https://github.com/edolstra/flake-compat/archive/${lock.nodes.${nodeName}.locked.rev}.tar.gz";
|
||||
sha256 = lock.nodes.${nodeName}.locked.narHash;
|
||||
}
|
||||
)
|
||||
{ src = ./.; }
|
||||
).shellNix
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue