aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--default.nix85
-rw-r--r--pkgs/mtop/default.nix24
-rw-r--r--pkgs/note/default.nix18
-rw-r--r--pkgs/terminal-velocity/default.nix33
-rw-r--r--pkgs/terminal-velocity/fix_build.patch (renamed from patches/terminal_velocity_fix_build.patch)0
-rw-r--r--pkgs/terminal-velocity/python3_support.patch (renamed from patches/terminal_velocity_python3_support.patch)0
-rw-r--r--pkgs/terminal-velocity/sort_found_notes.patch (renamed from patches/terminal_velocity_sort_found_notes.patch)0
-rw-r--r--pkgs/tiv/default.nix19
-rw-r--r--pkgs/tiv/tiv_builder.sh (renamed from hooks/tiv_builder.sh)0
9 files changed, 98 insertions, 81 deletions
diff --git a/default.nix b/default.nix
index 51ebcc2..38d7e0b 100644
--- a/default.nix
+++ b/default.nix
@@ -74,87 +74,10 @@ let
74 }; 74 };
75 }; 75 };
76 76
77 buildPerlPackage = perlPackages.buildPerlPackage; 77 mypkgs.mtop = callPackage ./pkgs/mtop {};
78 mypkgs.note = buildPerlPackage rec { 78 mypkgs.note = callPackage ./pkgs/note {};
79 name = "note-1.3.26"; 79 mypkgs.terminal-velocity = callPackage ./pkgs/terminal-velocity {};
80 src = fetchurl { 80 mypkgs.tiv = callPackage ./pkgs/tiv {};
81 url = "mirror://cpan/authors/id/T/TL/TLINDEN/${name}.tar.gz";
82 sha256 = "1h645rnb5vpms48fcyzvp7cwwcbf9k5xq49w2bpniyzzgk2brjrq";
83 };
84 outputs = ["out" "man"];
85 propagatedBuildInputs = [ perlPackages.YAML ];
86 meta = with stdenv.lib; {
87 description = "A perl script for maintaining notes";
88 homepage = http://www.daemon.de/NOTE;
89 license = licenses.gpl3;
90 maintainers = with maintainers; [ { name = "T.v.Dein"; email = "tlinden@cpan.org"; } ];
91 platforms = platforms.unix;
92 };
93 };
94
95 mypkgs.terminal-velocity = with python36Packages; buildPythonApplication rec {
96 pname = "terminal-velocity-git";
97 version = "0.2.0";
98
99 patches = [
100 ./patches/terminal_velocity_sort_found_notes.patch
101 ./patches/terminal_velocity_python3_support.patch
102 # FIXME: update this patch when version changes
103 ./patches/terminal_velocity_fix_build.patch
104 ];
105
106 propagatedBuildInputs = [ chardet urwid (sh.overridePythonAttrs { doCheck = false; }) pyyaml ];
107 buildInputs = [ m2r (restructuredtext_lint.overridePythonAttrs { doCheck = false; }) pygments ];
108
109 postInstall = ''
110 rm $out/bin/terminal_velocity
111 '';
112 src = fetchPypi {
113 inherit pname version;
114 sha256 = "13yrkcmvh5h5fwnai61sbmqkrjyisz08n62pq0ada2lyyqf7g6b9";
115 };
116 };
117
118 mypkgs.mtop = buildPerlPackage rec {
119 name = "mtop-${version}";
120 version = "0.6.6";
121 src = fetchurl {
122 url = "http://downloads.sourceforge.net/project/mtop/mtop/v${version}/mtop-${version}.tar.gz";
123 sha256 = "0x0x5300b1j9i0xxk8rsrki0pspyzj2vylhzv8qg3l6j26aw0zrf";
124 };
125 outputs = ["out"];
126 buildInputs = [ perlPackages.DBI perlPackages.DBDmysql perlPackages.Curses ];
127
128 postInstall = ''
129 cd "$out"
130 preConfigure || true
131 '';
132 meta = with stdenv.lib; {
133 description = "MySQL top (monitor and examine slow queries)";
134 homepage = http://mtop.sourceforge.net/;
135 license = licenses.gpl3;
136 maintainers = with maintainers; [ { name = "Marc Prewitt"; email = "mprewitt@chelsea.net"; } ];
137 platforms = platforms.unix;
138 };
139 };
140
141 mypkgs.tiv = buildPerlPackage rec {
142 name = "tiv-${version}";
143 version = "2015";
144 src = fetchurl {
145 url = "http://xyne.archlinux.ca/projects/tiv/src/tiv-${version}.tar.xz";
146 sha256 = "1vq073v7z7vmcd57lhs4rf4jasji69cpjgkz4dykp94a77p1qq90";
147 };
148 outputs = ["out"];
149 buildInputs = [ perlPackages.PerlMagick ];
150 perlPreHookScript = ./hooks/tiv_builder.sh;
151 perlPreHook = ''
152 source ${perlPreHookScript}
153 '';
154 installPhase = ''
155 install -Dm755 tiv "$out/bin/tiv"
156 '';
157 };
158 81
159 mypkgs.cnagios = stdenv.mkDerivation (fetchedGithub ./fetched/cnagios.json // rec { 82 mypkgs.cnagios = stdenv.mkDerivation (fetchedGithub ./fetched/cnagios.json // rec {
160 configureFlags = [ 83 configureFlags = [
diff --git a/pkgs/mtop/default.nix b/pkgs/mtop/default.nix
new file mode 100644
index 0000000..4a89430
--- /dev/null
+++ b/pkgs/mtop/default.nix
@@ -0,0 +1,24 @@
1{ buildPerlPackage, fetchurl, perlPackages, lib }:
2buildPerlPackage rec {
3 name = "mtop-${version}";
4 version = "0.6.6";
5 src = fetchurl {
6 url = "http://downloads.sourceforge.net/project/mtop/mtop/v${version}/mtop-${version}.tar.gz";
7 sha256 = "0x0x5300b1j9i0xxk8rsrki0pspyzj2vylhzv8qg3l6j26aw0zrf";
8 };
9 outputs = ["out"];
10 buildInputs = with perlPackages; [ DBI DBDmysql Curses ];
11
12 postInstall = ''
13 cd "$out"
14 preConfigure || true
15 '';
16
17 meta = with lib; {
18 description = "MySQL top (monitor and examine slow queries)";
19 homepage = http://mtop.sourceforge.net/;
20 license = licenses.gpl3;
21 maintainers = with maintainers; [ { name = "Marc Prewitt"; email = "mprewitt@chelsea.net"; } ];
22 platforms = platforms.unix;
23 };
24}
diff --git a/pkgs/note/default.nix b/pkgs/note/default.nix
new file mode 100644
index 0000000..0c422bc
--- /dev/null
+++ b/pkgs/note/default.nix
@@ -0,0 +1,18 @@
1{ lib, buildPerlPackage, fetchurl, perlPackages }:
2buildPerlPackage rec {
3 name = "note-1.3.26";
4 src = fetchurl {
5 url = "mirror://cpan/authors/id/T/TL/TLINDEN/${name}.tar.gz";
6 sha256 = "1h645rnb5vpms48fcyzvp7cwwcbf9k5xq49w2bpniyzzgk2brjrq";
7 };
8 outputs = ["out" "man"];
9 propagatedBuildInputs = with perlPackages; [ YAML ];
10
11 meta = with lib; {
12 description = "A perl script for maintaining notes";
13 homepage = http://www.daemon.de/NOTE;
14 license = licenses.gpl3;
15 maintainers = with maintainers; [ { name = "T.v.Dein"; email = "tlinden@cpan.org"; } ];
16 platforms = platforms.unix;
17 };
18}
diff --git a/pkgs/terminal-velocity/default.nix b/pkgs/terminal-velocity/default.nix
new file mode 100644
index 0000000..9e79dee
--- /dev/null
+++ b/pkgs/terminal-velocity/default.nix
@@ -0,0 +1,33 @@
1{ python36Packages }:
2with python36Packages;
3buildPythonApplication rec {
4 pname = "terminal-velocity-git";
5 version = "0.2.0";
6 src = fetchPypi {
7 inherit pname version;
8 sha256 = "13yrkcmvh5h5fwnai61sbmqkrjyisz08n62pq0ada2lyyqf7g6b9";
9 };
10
11 patches = [
12 ./sort_found_notes.patch
13 ./python3_support.patch
14 # FIXME: update this patch when version changes
15 ./fix_build.patch
16 ];
17
18 propagatedBuildInputs = [
19 chardet
20 urwid
21 (sh.overridePythonAttrs { doCheck = false; })
22 pyyaml
23 ];
24 buildInputs = [
25 m2r
26 (restructuredtext_lint.overridePythonAttrs { doCheck = false; })
27 pygments
28 ];
29
30 postInstall = ''
31 rm $out/bin/terminal_velocity
32 '';
33}
diff --git a/patches/terminal_velocity_fix_build.patch b/pkgs/terminal-velocity/fix_build.patch
index b08e0c4..b08e0c4 100644
--- a/patches/terminal_velocity_fix_build.patch
+++ b/pkgs/terminal-velocity/fix_build.patch
diff --git a/patches/terminal_velocity_python3_support.patch b/pkgs/terminal-velocity/python3_support.patch
index bd4aec7..bd4aec7 100644
--- a/patches/terminal_velocity_python3_support.patch
+++ b/pkgs/terminal-velocity/python3_support.patch
diff --git a/patches/terminal_velocity_sort_found_notes.patch b/pkgs/terminal-velocity/sort_found_notes.patch
index 2bc563c..2bc563c 100644
--- a/patches/terminal_velocity_sort_found_notes.patch
+++ b/pkgs/terminal-velocity/sort_found_notes.patch
diff --git a/pkgs/tiv/default.nix b/pkgs/tiv/default.nix
new file mode 100644
index 0000000..c03aabe
--- /dev/null
+++ b/pkgs/tiv/default.nix
@@ -0,0 +1,19 @@
1{ buildPerlPackage, fetchurl, perlPackages }:
2buildPerlPackage rec {
3 name = "tiv-${version}";
4 version = "2015";
5 src = fetchurl {
6 url = "http://xyne.archlinux.ca/projects/tiv/src/tiv-${version}.tar.xz";
7 sha256 = "1vq073v7z7vmcd57lhs4rf4jasji69cpjgkz4dykp94a77p1qq90";
8 };
9
10 outputs = ["out"];
11 buildInputs = with perlPackages; [ PerlMagick ];
12 perlPreHookScript = ./tiv_builder.sh;
13 perlPreHook = ''
14 source $perlPreHookScript
15 '';
16 installPhase = ''
17 install -Dm755 tiv "$out/bin/tiv"
18 '';
19}
diff --git a/hooks/tiv_builder.sh b/pkgs/tiv/tiv_builder.sh
index ea16682..ea16682 100644
--- a/hooks/tiv_builder.sh
+++ b/pkgs/tiv/tiv_builder.sh