feat: Package program with nix
This commit is contained in:
parent
6980d07d8f
commit
bf4fa2c6d0
4 changed files with 56 additions and 0 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -1 +1,2 @@
|
||||||
/target
|
/target
|
||||||
|
/result
|
||||||
|
|
24
flake.lock
Normal file
24
flake.lock
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
{
|
||||||
|
"nodes": {
|
||||||
|
"nixpkgs": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1700678569,
|
||||||
|
"narHash": "sha256-2Ki+2UvOidxEb3xB4ADqlbPQ2BZOF4uZMR094O8or2I=",
|
||||||
|
"path": "/nix/store/jbw0627xpxp92zmlhlry1hra99dacxdf-source",
|
||||||
|
"rev": "8f1180704ac35baded1a74164365ac7cdfba6f38",
|
||||||
|
"type": "path"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"id": "nixpkgs",
|
||||||
|
"type": "indirect"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"root": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": "nixpkgs"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"root": "root",
|
||||||
|
"version": 7
|
||||||
|
}
|
10
flake.nix
Normal file
10
flake.nix
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
{
|
||||||
|
description = "A tmux session navigator written in Rust.";
|
||||||
|
inputs.nixpkgs.url = "nixpkgs";
|
||||||
|
outputs = { self, nixpkgs }:
|
||||||
|
{
|
||||||
|
packages = nixpkgs.lib.mapAttrs (system: pkgs: {
|
||||||
|
default = pkgs.callPackage ./package.nix {};
|
||||||
|
}) nixpkgs.legacyPackages;
|
||||||
|
};
|
||||||
|
}
|
21
package.nix
Normal file
21
package.nix
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
{ fetchFromGitea, rustPlatform }:
|
||||||
|
|
||||||
|
rustPlatform.buildRustPackage rec {
|
||||||
|
pname = "navigation";
|
||||||
|
version = "1.0.0";
|
||||||
|
|
||||||
|
src = fetchFromGitea {
|
||||||
|
domain = "git.disroot.org";
|
||||||
|
owner = "lwad";
|
||||||
|
repo = pname;
|
||||||
|
rev = version;
|
||||||
|
hash = "sha256-B882aL9Y0bLWhIfNoZNuW1WRri0Nwv5GpbNe5jxzGOE=";
|
||||||
|
};
|
||||||
|
|
||||||
|
cargoHash = "sha256-VDz3S8Akf9VGMFmBe01oAIkMClMjj4xF4DYS88RPQVg=";
|
||||||
|
|
||||||
|
meta = {
|
||||||
|
description = "A tmux session navigator written in Rust.";
|
||||||
|
homepage = "https://git.disroot.org/lwad/navigator";
|
||||||
|
};
|
||||||
|
}
|
Loading…
Reference in a new issue