mirror of
https://github.com/socatlolmeow/drift.git
synced 2026-11-03 11:20:20 +00:00
26 lines
828 B
Nix
26 lines
828 B
Nix
{
|
|
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
|
|
|
|
outputs = { self, nixpkgs }:
|
|
let
|
|
systems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ];
|
|
forAll = nixpkgs.lib.genAttrs systems;
|
|
in {
|
|
packages = forAll (system:
|
|
let pkgs = nixpkgs.legacyPackages.${system};
|
|
in {
|
|
default = pkgs.rustPlatform.buildRustPackage {
|
|
pname = "drift";
|
|
version = "0.1.0";
|
|
src = ./.;
|
|
cargoLock.lockFile = ./Cargo.lock;
|
|
nativeBuildInputs = [ pkgs.makeWrapper ];
|
|
postInstall = ''
|
|
wrapProgram $out/bin/drift \
|
|
--prefix PATH : ${pkgs.lib.makeBinPath [ pkgs.mpv pkgs.yt-dlp ]}
|
|
'';
|
|
meta.mainProgram = "drift";
|
|
};
|
|
});
|
|
};
|
|
}
|