-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathov.nix
38 lines (32 loc) · 1010 Bytes
/
ov.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
# [ov](https://github.com/noborus/ov) is a Feature-rich terminal-based text viewer.
{ lib, buildGo122Module, fetchFromGitHub, installShellFiles }:
buildGo122Module rec {
pname = "ov";
version = "0.32.0";
src = fetchFromGitHub {
owner = "noborus";
repo = "ov";
rev = "v${version}";
sha256 = "sha256-mQ1KwElD8RizOT2trHWo4T1QiZ974xwhQCCa5snpnZM=";
};
ldflags = [
"-s"
"-w"
"-X main.Version=${version}"
];
vendorHash = "sha256-XACdtJdACMKQ5gSJcjGAPNGPFL1Tbt6QOovl15mvFGI=";
nativeBuildInputs = [ installShellFiles ];
postInstall = ''
installShellCompletion --cmd ov \
--bash <($out/bin/ov --completion bash) \
--fish <($out/bin/ov --completion fish) \
--zsh <($out/bin/ov --completion zsh)
'';
meta = with lib; {
description = "Feature-rich terminal-based text viewer";
homepage = "https://github.com/noborus/ov";
license = licenses.mit;
mainProgram = "ov";
maintainers = with maintainers; [ jpetrucciani ];
};
}