diff options
author | Johannes Wienke | 2018-06-23 15:21:35 +0200 |
---|---|---|
committer | Johannes Wienke | 2018-07-16 20:39:45 +0200 |
commit | 6dcc9e49b320761078f4b82ba4bd8b27f145efbf (patch) | |
tree | 5252181e9d9f45bfc4c3c142cbdf764eaf684935 | |
download | aur-6dcc9e49b320761078f4b82ba4bd8b27f145efbf.tar.gz |
Initial release of the git package
-rw-r--r-- | .SRCINFO | 35 | ||||
-rw-r--r-- | PKGBUILD | 60 | ||||
-rw-r--r-- | autosuspend-git.install | 4 |
3 files changed, 99 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..1f907f6f2240 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,35 @@ +pkgbase = autosuspend-git + pkgdesc = A daemon to suspend your server in case of inactivity + pkgver = 2.0.0.186 + pkgrel = 1 + url = https://github.com/languitar/autosuspend + install = autosuspend-git.install + arch = any + license = GPL2 + makedepends = python-setuptools + makedepends = python-pytest-runner + makedepends = python-sphinx + makedepends = python-sphinx_rtd_theme + makedepends = python-sphinx-issues + depends = python + depends = python-psutil + optdepends = python-dbus: logind session discovery + optdepends = python-mpd2: MPD playing status check + optdepends = python-requests: network-based checks + optdepends = python-lxml: XPath check + optdepends = python-dbus: logind-based checks + optdepends = python-icalendar: iCalendar checks + optdepends = python-dateutil: iCalendar checks + optdepends = python-tzlocal: iCalendar checks + optdepends = python-requests-file: file:// URL support + optdepends = iputils: ping check + optdepends = xprintidle: X server idle time check + provides = autosuspend + conflicts = autosuspend + backup = etc/autosuspend.conf + backup = etc/autosuspend-logging.conf + source = git+https://github.com/languitar/autosuspend.git + sha256sums = SKIP + +pkgname = autosuspend-git + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..8f263e3f0664 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,60 @@ +# Maintainer: Johannes Wienke <languitar@semipol.de> + +pkgname=autosuspend-git +pkgver=2.0.0.186 +pkgrel=1 +pkgdesc="A daemon to suspend your server in case of inactivity" +arch=(any) +url="https://github.com/languitar/autosuspend" +license=('GPL2') +depends=('python' 'python-psutil') +optdepends=('python-dbus: logind session discovery' + 'python-mpd2: MPD playing status check' + 'python-requests: network-based checks' + 'python-lxml: XPath check' + 'python-dbus: logind-based checks' + 'python-icalendar: iCalendar checks' + 'python-dateutil: iCalendar checks' + 'python-tzlocal: iCalendar checks' + 'python-requests-file: file:// URL support' + 'iputils: ping check' + 'xprintidle: X server idle time check') +makedepends=('python-setuptools' 'python-pytest-runner' 'python-sphinx' 'python-sphinx_rtd_theme' 'python-sphinx-issues') +provides=('autosuspend') +conflicts=('autosuspend') +source=("git+https://github.com/languitar/autosuspend.git") +sha256sums=('SKIP') +install="${pkgname}.install" +backup=('etc/autosuspend.conf' + 'etc/autosuspend-logging.conf') + +pkgver() { + cd "autosuspend" + rev="$(git rev-list --count HEAD)" + base="$(cat VERSION | tail -n 1 | sed 's/\.dev.*//')" + echo -n "${base}.${rev}" +} + +build() { + cd "autosuspend" + python3 setup.py build_sphinx -a -b html + python3 setup.py build_sphinx -a -b man +} + +package() { + cd "autosuspend" + python3 setup.py install --root="$pkgdir/" --install-data=/usr + # setuptools install_data is a nightmare, and cannot be made to respect the + # filesystem hierarchy. Do things manually instead. + mv "$pkgdir/usr/etc" "$pkgdir" + + # man pages + mkdir -p "${pkgdir}/usr/share/man/man1" + cp doc/build/man/autosuspend.1 "${pkgdir}/usr/share/man/man1" + mkdir -p "${pkgdir}/usr/share/man/man5" + cp doc/build/man/autosuspend.conf.5 "${pkgdir}/usr/share/man/man5" + + # HTML help + mkdir -p "${pkgdir}/usr/share/doc" + cp -R doc/build/html "${pkgdir}/usr/share/doc/${pkgname}" +} diff --git a/autosuspend-git.install b/autosuspend-git.install new file mode 100644 index 000000000000..fb25c1496ad6 --- /dev/null +++ b/autosuspend-git.install @@ -0,0 +1,4 @@ +post_upgrade() { + echo ">> The script has been renamed from autosuspend.py to autosuspend." + echo ">> Provided systemd services are updated." +} |