summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: aa53b340c91639b770d7dc15e7df35c22166a5c1 (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
33
34
35
36
37
38
39
# Maintainer: Hans Ole Hatzel <hhatzel@gmail.com>
pkgname=otf-fira-mono-italic-git
pkgver=7205478c
pkgrel=2
pkgdesc="Italic and bold-italic version of Fira Mono"
arch=("any")
url="https://github.com/Avi-D-coder/fira-mono-italic"
license=("custom:OFL")
depends=("fontconfig" "xorg-mkfontdir" "xorg-mkfontscale")
makedepends=("git")
install=otf.install
source=("$pkgname::git+https://github.com/Avi-D-coder/fira-mono-italic" 'otf.install')
md5sums=("SKIP"
         "ae560f6f3cc2687fbfaec8073567ee2f")

pkgver() {
    cd "$srcdir/${pkgname}"
    git describe --long --tags --always | sed "s/\([^-]*-g\)/r\1/;s/-/./g"
}

package() {
    cd "$srcdir/${pkgname}"

    local weights=(
        'Regular Italic'
        'Bold Italic'
    )
    local font="Fira Mono"

    for weight in "${weights[@]}"; do
        echo $weight
        local name="${font}-${weight}.otf"
        ls "distr/otf/"
        install -Dm644 "distr/otf/${name}" "$pkgdir/usr/share/fonts/OTF/${name}"
    done
    install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}

# vim:sw=4:ts=4:et: