Skip to content

Commit

Permalink
🎨 format flake.nix
Browse files Browse the repository at this point in the history
format with https://nixfmt.serokell.io, convert spaces to tabs
  • Loading branch information
ttytm committed Dec 19, 2024
1 parent c780d99 commit b92378d
Showing 1 changed file with 56 additions and 50 deletions.
106 changes: 56 additions & 50 deletions flake.nix
Original file line number Diff line number Diff line change
@@ -1,54 +1,60 @@
{
inputs = {
nixpkgs = {
url = "github:NixOS/nixpkgs/nixpkgs-unstable";
};
inputs = {
nixpkgs = {
url = "github:NixOS/nixpkgs/nixpkgs-unstable";
};

flake-utils = {
url = "github:numtide/flake-utils";
};
};
outputs = inputs @ {
self,
nixpkgs,
flake-utils,
...
}:
flake-utils.lib.eachDefaultSystem (system: let
pkgs = nixpkgs.legacyPackages.${system};
wthrr-the-weathercrab = {
lib,
openssl,
pkg-config,
rustPlatform,
}:
rustPlatform.buildRustPackage {
name = "wthrr-the-weathercrab";
src = lib.cleanSource ./.;
cargoLock.lockFile = ./Cargo.lock;
nativeBuildInputs = [
pkg-config
rustPlatform.bindgenHook
];
buildInputs = [openssl];
flake-utils = {
url = "github:numtide/flake-utils";
};
};
outputs =
inputs@{
self,
nixpkgs,
flake-utils,
...
}:
flake-utils.lib.eachDefaultSystem (
system:
let
pkgs = nixpkgs.legacyPackages.${system};
wthrr-the-weathercrab =
{
lib,
openssl,
pkg-config,
rustPlatform,
}:
rustPlatform.buildRustPackage {
name = "wthrr-the-weathercrab";
src = lib.cleanSource ./.;
cargoLock.lockFile = ./Cargo.lock;
nativeBuildInputs = [
pkg-config
rustPlatform.bindgenHook
];
buildInputs = [ openssl ];

checkFlags = [
# connecting to internet does not work in the sandbox
"--skip=modules::location::tests::geolocation_response"
"--skip=modules::localization::tests::translate_string"
];

meta = with lib; {
license = licenses.mit;
homepage = "https://github.com/ttytm/wthrr-the-weathercrab";
platforms = platforms.all;
};
};
in {
packages.default = pkgs.callPackage wthrr-the-weathercrab {};
apps.default = {
type = "app";
program = "${self.outputs.packages.${system}.default}/bin/wthrr";
};
});
checkFlags = [
# connecting to internet does not work in the sandbox
"--skip=modules::location::tests::geolocation_response"
"--skip=modules::localization::tests::translate_string"
];

meta = with lib; {
license = licenses.mit;
homepage = "https://github.com/ttytm/wthrr-the-weathercrab";
platforms = platforms.all;
};
};
in
{
packages.default = pkgs.callPackage wthrr-the-weathercrab { };
apps.default = {
type = "app";
program = "${self.outputs.packages.${system}.default}/bin/wthrr";
};
}
);
}

0 comments on commit b92378d

Please sign in to comment.