1 { lib, rustPlatform, fetchFromGitHub, fetchpatch, installShellFiles }:
3 rustPlatform.buildRustPackage rec {
7 src = fetchFromGitHub {
11 hash = "sha256-uNdtgx9/9+KOfQvHiKNrT8NFWtR2tfJuI2bMwywBC/4=";
14 cargoHash = "sha256-ctYQMBAdSUfEek2vcCa3gnI9N6ZG9b+VvtAzT20jlXY=";
17 # Cargo.lock is outdated.
18 # https://github.com/I60R/page/pull/45.
20 url = "https://github.com/I60R/page/commit/83f936b64620ba74043c1db31207b4366c0f7e3d.patch";
21 hash = "sha256-qA5oP4K/6eG0A+syVNb1izl+bnYll5V6sWM3LVFTb4o=";
25 nativeBuildInputs = [ installShellFiles ];
27 completions_dir=$(find "target" -name "assets" -type d -printf "%T+\t%p\n" | sort | awk 'NR==1{print $2}')
28 installShellCompletion --bash $completions_dir/page.bash
29 installShellCompletion --fish $completions_dir/page.fish
30 installShellCompletion --zsh $completions_dir/_page
34 description = "Use neovim as pager";
35 homepage = "https://github.com/I60R/page";
36 license = licenses.mit;
38 maintainers = [ maintainers.s1341 ];