mirror of
https://github.com/alexpasmantier/television.git
synced 2025-06-01 09:00:16 +00:00

Hey again, just realized there was an update with toolchain change 1.81 -> 1.83, so updating the hash for it :) Co-authored-by: Vitalii Lukyanov <tukanoid@outlok.com>
67 lines
1.4 KiB
Nix
67 lines
1.4 KiB
Nix
{
|
|
inputs = {
|
|
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
|
|
|
|
nixpkgs-mozilla = {
|
|
url = "github:mozilla/nixpkgs-mozilla";
|
|
flake = false;
|
|
};
|
|
|
|
flake-utils.url = "github:numtide/flake-utils";
|
|
naersk.url = "github:nix-community/naersk";
|
|
};
|
|
|
|
outputs = {
|
|
self,
|
|
flake-utils,
|
|
naersk,
|
|
nixpkgs,
|
|
nixpkgs-mozilla,
|
|
}:
|
|
flake-utils.lib.eachDefaultSystem (
|
|
system: let
|
|
pkgs = (import nixpkgs) {
|
|
inherit system;
|
|
|
|
overlays = [
|
|
(import nixpkgs-mozilla)
|
|
];
|
|
};
|
|
|
|
toolchain =
|
|
(
|
|
pkgs.rustChannelOf
|
|
{
|
|
rustToolchain = ./rust-toolchain.toml;
|
|
sha256 = "s1RPtyvDGJaX/BisLT+ifVfuhDT1nZkZ1NcK8sbwELM=";
|
|
}
|
|
)
|
|
.rust;
|
|
|
|
naersk' = pkgs.callPackage naersk {
|
|
cargo = toolchain;
|
|
rustc = toolchain;
|
|
};
|
|
in {
|
|
packages.default = naersk'.buildPackage {
|
|
src = ./.;
|
|
};
|
|
apps = {
|
|
default = flake-utils.lib.mkApp {
|
|
drv = self.packages.${system}.default;
|
|
exePath = "/bin/tv";
|
|
};
|
|
};
|
|
|
|
devShells.default = pkgs.mkShell {
|
|
nativeBuildInputs = [toolchain];
|
|
packages = with pkgs; [
|
|
rustfmt
|
|
clippy
|
|
rust-analyzer
|
|
];
|
|
};
|
|
}
|
|
);
|
|
}
|