blob: 39231e6e14423cb3510cc17713d168ef0bda5db3 (
plain) (
blame)
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
|
{ lib
, stdenv
, fetchFromGitHub
, meson
, ncurses
, ninja
, pkg-config
}:
stdenv.mkDerivation (finalAttrs: {
pname = "loksh";
version = "7.4";
src = fetchFromGitHub {
owner = "dimkr";
repo = finalAttrs.pname;
rev = finalAttrs.version;
fetchSubmodules = true;
sha256 = "sha256-gQK9gq6MsKVyOikOW0sW/SbIM1K/3I8pn58P/SqzKys=";
};
nativeBuildInputs = [
meson
ninja
pkg-config
];
buildInputs = [
ncurses
];
strictDeps = true;
postInstall = ''
mv $out/bin/ksh $out/bin/loksh
mv $out/share/man/man1/ksh.1 $out/share/man/man1/loksh.1
mv $out/share/man/man1/sh.1 $out/share/man/man1/loksh-sh.1
'';
meta = with lib; {
homepage = "https://github.com/dimkr/loksh";
description = "Linux port of OpenBSD's ksh";
longDescription = ''
loksh is a Linux port of OpenBSD's ksh.
Unlike other ports of ksh, loksh targets only one platform, follows
upstream closely and keeps changes to a minimum. loksh does not add any
extra features; this reduces the risk of introducing security
vulnerabilities and makes loksh a good fit for resource-constrained
systems.
'';
license = licenses.publicDomain;
maintainers = with maintainers; [ cameronnemo ];
platforms = platforms.linux;
};
passthru = {
shellPath = "/bin/loksh";
};
})
|