「🔨」 fix(Flake): No more skill issue in flake
This commit is contained in:
2
.gitignore
vendored
2
.gitignore
vendored
@ -1,3 +1,5 @@
|
||||
obj/
|
||||
ex00/megaphone
|
||||
megaphone
|
||||
.direnv
|
||||
flake.lock
|
||||
|
39
flake.nix
39
flake.nix
@ -2,23 +2,34 @@
|
||||
description = "A Nix-flake-based C/C++ development environment";
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||
pogit.url = "github:y-syo/pogit";
|
||||
pogit = {
|
||||
url = "github:y-syo/pogit";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
};
|
||||
|
||||
outputs = inputs@{ self, nixpkgs, pogit }:
|
||||
outputs = inputs@{ nixpkgs, ... }:
|
||||
let
|
||||
pkgs = nixpkgs.legacyPackages.x86_64-linux; # Use x86_64-linux as an example
|
||||
supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ];
|
||||
forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f {
|
||||
pkgs = import nixpkgs { inherit system; };
|
||||
});
|
||||
in {
|
||||
devShell.x86_64-linux = pkgs.mkShell {
|
||||
buildInputs = with pkgs; [
|
||||
gcc
|
||||
clang
|
||||
gdb
|
||||
norminette
|
||||
valgrind
|
||||
git
|
||||
inputs.pogit.packages.${pkgs.system}.default
|
||||
];
|
||||
};
|
||||
devShells = forEachSupportedSystem ({ pkgs }: {
|
||||
default = pkgs.mkShell.override
|
||||
{}
|
||||
{
|
||||
packages = with pkgs; [
|
||||
gcc
|
||||
clang
|
||||
norminette
|
||||
valgrind
|
||||
git
|
||||
gdb
|
||||
inputs.pogit.packages.${pkgs.system}.default
|
||||
bear
|
||||
];
|
||||
};
|
||||
});
|
||||
};
|
||||
}
|
||||
|
Reference in New Issue
Block a user