Skip to content

Commit

Permalink
nix: Update Flake formatting to RFC style
Browse files Browse the repository at this point in the history
Signed-off-by: Steffen Vogel <[email protected]>
  • Loading branch information
stv0g committed May 25, 2024
1 parent ec10b0e commit 4255923
Showing 1 changed file with 22 additions and 17 deletions.
39 changes: 22 additions & 17 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,22 @@
flake-utils.url = "github:numtide/flake-utils";
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
};
outputs = {
self,
nixpkgs,
flake-utils,
}:
flake-utils.lib.eachDefaultSystem
(
system: let
outputs =
{
self,
nixpkgs,
flake-utils,
}:
flake-utils.lib.eachDefaultSystem (
system:
let
pkgs = nixpkgs.legacyPackages.${system};
frameworks = pkgs.darwin.apple_sdk.frameworks;
in {
in
{
devShell = pkgs.mkShell {
buildInputs = with pkgs;
buildInputs =
with pkgs;
[
pkg-config
clang
Expand All @@ -29,16 +32,18 @@
pcsclite
pcsctools
]
++ lib.optionals pkgs.stdenv.isDarwin [
frameworks.PCSC
];
++ lib.optionals pkgs.stdenv.isDarwin [ frameworks.PCSC ];

shellHook = if pkgs.stdenv.isDarwin then ''
export CGO_LDFLAGS="-F${frameworks.PCSC}/Library/Frameworks";
'' else "";
shellHook =
if pkgs.stdenv.isDarwin then
''
export CGO_LDFLAGS="-F${frameworks.PCSC}/Library/Frameworks";
''
else
"";
};

formatter = nixpkgs.alejandra;
formatter = nixpkgs.nixfmt-rfc-style;
}
);
}

0 comments on commit 4255923

Please sign in to comment.