aboutsummarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorConnor Prussin2017-08-15 11:22:46 -0700
committerConnor Prussin2017-08-15 11:33:44 -0700
commit360842973a45d540c51001963d40d7fd5ef0fa1e (patch)
tree4757a0635fd609ed10dd7ca4a3e52ebf968ea6cf /PKGBUILD
downloadaur-360842973a45d540c51001963d40d7fd5ef0fa1e.tar.gz
Initial commit
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD89
1 files changed, 89 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..250f92023b6f
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,89 @@
+# Maintainer Connor Prussin <connor at prussin dot net>
+# Contributor: icasdri <icasdri at gmail dot com>
+# Contributor: Yardena Cohen <yardenack at gmail dot com>
+# Contributor: Boohbah <boohbah at gmail.com>
+# Contributor: Eric Belanger <eric at archlinux.org>
+# Contributor: Daniel J Griffiths <ghost1227 at archlinux.us>
+# Contributor: Wesley Merkel <ooesili at gmail.com>
+
+##### OPTIONS ###############################################################
+
+# Set the following variable accordingly:
+# * x if you would like to use x as the kill-process shortcut in htop
+# * d if you would like to use d as the kill-process shortcut in htop
+# (we need one of these as htop's default shortcut k conflicts with vim
+# movement keys!)
+
+kill_process_shortcut=x
+#kill_process_shortcut=d
+
+#############################################################################
+
+_pkgname=htop
+pkgname=htop-vim-solarized
+pkgver=2.0.2
+pkgrel=1
+pkgdesc="Interactive process viewer with solarized and vim keybindings patch"
+arch=('i686' 'x86_64')
+url="https://github.com/cprussin/htop-vim-solarized"
+license=('GPL')
+depends=('ncurses')
+makedepends=('git' 'python2')
+optdepends=('lsof: show files opened by a process'
+ 'strace: attach to a running process')
+provides=('htop')
+conflicts=('htop')
+options=('!emptydirs')
+source=(
+ 'http://hisham.hm/htop/releases/2.0.2/htop-2.0.2.tar.gz'
+ 'solarized-colors.patch'
+ 'vim-keybindings-common.patch'
+ 'vim-keybindings-d-for-kill.patch'
+ 'vim-keybindings-x-for-kill.patch'
+)
+sha384sums=('3b64dae53f248dbfb1cf5dafc066e6a27614a264ebc3487357d501f4a00abd149dffcfd3c5548341b1af20312c5d9a84'
+ 'ebc4339ff3d5d43606d9f5e398832cb9382bfa175b30e36cfbcaf6112206c33ea0d42e39246e3a73785d3f584cf88214'
+ '8325ae4f8e7732e9c1c067b94314da13adc86c6cb4747e78cf4332a432c7c4e12d368f7bb50ad1d404f127aa3afdb077'
+ '353a675f5453b5b1ab503f9cbcb02e45b32bf429797f11e3cea96848fb4ad931129da7afa52b373fd6871c41657d52af'
+ '3b2071d412a6a98bf5d4d3a4bc74f69b205f9464b00063aa21e9947b80df2a008bb82aff7f8168b0dfbac0647bc0cb76')
+
+prepare() {
+ cd "${srcdir}/${_pkgname}-${pkgver}"
+
+ patch_list=(
+ 'solarized-colors.patch'
+ 'vim-keybindings-common.patch'
+ "vim-keybindings-${kill_process_shortcut}-for-kill.patch"
+ )
+
+ msg2 "Using '$kill_process_shortcut' as the kill-process shortcut in htop"
+
+ for _p in "${patch_list[@]}"
+ do
+ msg2 "Applying $_p"
+ patch -p1 -i "../$_p"
+ done
+
+ ./autogen.sh
+
+ sed -i 's|ncursesw/curses.h|curses.h|' RichString.[ch] configure
+ sed -i 's|python|python2|' scripts/MakeHeader.py
+
+ ./configure \
+ --prefix=/usr \
+ --enable-unicode \
+ --enable-openvz \
+ --enable-vserver \
+ --enable-cgroup \
+ --enable-oom
+}
+
+build() {
+ cd "${srcdir}/${_pkgname}-${pkgver}"
+ make
+}
+
+package() {
+ cd "${srcdir}/${_pkgname}-${pkgver}"
+ make DESTDIR="${pkgdir}" install
+}