1{ lib, rustPlatform, fetchFromGitHub
2, fuse
3, pkg-config
4}:
5
6rustPlatform.buildRustPackage rec {
7 pname = "catfs";
8 version = "0.9.0-unstable-2023-10-09";
9
10 src = fetchFromGitHub {
11 owner = "kahing";
12 repo = pname;
13 rev = "35430f800e68da18fb6bbd25a8f15bf32fa1f166";
14 hash = "sha256-hbv4SNe0yqjO6Oomev9uKqG29TiJeI8G7LH+Wxn7hnQ=";
15 };
16
17 cargoLock = {
18 lockFile = ./Cargo.lock;
19 outputHashes = {
20 "fd-0.2.3" = "sha256-Xps5s30urCZ8FZYce41nOZGUAk7eRyvObUS/mMx6Tfg=";
21 };
22 };
23
24 nativeBuildInputs = [ pkg-config ];
25
26 buildInputs = [ fuse ];
27
28 # require fuse module to be active to run tests
29 # instead, run command
30 doCheck = false;
31 doInstallCheck = true;
32 installCheckPhase = ''
33 $out/bin/catfs --help > /dev/null
34 '';
35
36 meta = with lib; {
37 description = "Caching filesystem written in Rust";
38 mainProgram = "catfs";
39 homepage = "https://github.com/kahing/catfs";
40 license = licenses.asl20;
41 platforms = platforms.linux;
42 maintainers = [ ];
43 };
44}