summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 2e6a078a9ef0cb8e362bd3d28c2995da52cdccbe (plain)
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
# Maintainer: Muflone http://www.muflone.com/contacts/english/
# Contributor: Ryan Young <ry an. ry. young@gmail.com> (omit spaces)

pkgname=temp-throttle-git
pkgver=r37.4199e7e
pkgrel=1
pkgdesc="A shell script for throttling system CPU frequency based on a desired maximum temperature."
arch=('any')
url="https://github.com/Sepero/temp-throttle"
license=('GPL2')
depends=('bash')
makedepends=('git')
source=('git://github.com/Sepero/temp-throttle.git'
        'temp-throttle@.service')
sha256sums=('SKIP'
            '18ae3edd7b41508da279df6d67f1c5d86e1dbfe2daebbc42bbe39c26031b22e0')

pkgver() {
  cd "${pkgname%-git}"
  printf "r$(git rev-list --count HEAD).$(git rev-parse --short HEAD)"
}

package() {
  cd "${pkgname%-git}"
  install -m 755 -d "${pkgdir}/usr/bin"
  install -m 755 'temp_throttle.sh' "${pkgdir}/usr/bin/${pkgname%-git}"
  install -m 755 -d "${pkgdir}/usr/share/doc/${pkgname}"
  install -m 644 -t "${pkgdir}/usr/share/doc/${pkgname}" "README.md"
  install -m 755 -d "${pkgdir}/usr/lib/systemd/system"
  install -m 644 -t "${pkgdir}/usr/lib/systemd/system" "${srcdir}/${pkgname%-git}@.service"
}