summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: e4a45ae5d87b5d5af4f6b914d2e2a6516b78e445 (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
# Maintainer: Yardena Cohen <yardenack at gmail dot com>

shortname=unpaywall
gitname=${shortname}-extension
pkgname=chromium-${shortname}-git
pkgver=293.ba7d152
pkgrel=1
pkgdesc="Chromium extension to find free journal articles"
arch=('any')
url="https://github.com/ourresearch/${gitname}"
license=('MIT')
makedepends=(git)
source=("git+${url}.git")
sha512sums=('SKIP')

pkgver() {
    cd "${srcdir}/${gitname}"
    local ver="$(git rev-list --count HEAD).$(git rev-parse --short HEAD)"
    printf "%s" "${ver//-/.}"
}
package() {
    mkdir -p "${pkgdir}/usr/share/chromium/${shortname}"
    shopt -u dotglob
    cp -dr --no-preserve=ownership "${srcdir}/${gitname}"/extension/* "${pkgdir}/usr/share/chromium/${shortname}/"
}