summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: d5282c2536298018957b05a18db5e03f3a1c067a (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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
# Maintainer Joost Bremmer <contact@madeofmagicandowires.online>
pkgbase=shortcut-git
pkgname=('shortcut-pages-git' 'shortcut-pages-extra-git' 'shortcut-c-client-git')
pkgver=0.2.0
pkgrel=2
pkgdesc="A commandline client to list shortcuts"
url="https://github.com/mt-empty/shortcut-c-client"
arch=('x86_64')
license=('unknown')
makedepends=('git')
source=("shortcut-pages::git+https://github.com/mt-empty/shortcut-pages.git"
        "shortcut-c-client::git+https://github.com/mt-empty/shortcut-c-client.git")
sha256sums=('SKIP'
            'SKIP')

pkgver() {
  cd "${srcdir}/shortcut-pages"
    printf "0.2.0.r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}

build() {
  cd "${srcdir}/shortcut-c-client"
  make DEST_DIR="/usr/share" shortcut
}


package_shortcut-pages-git() {
  pkgname=shortcut-pages-git
  pkgdesc="A collections of keyboard shortcuts for Desktop application and websites"
  url="https://github.com/mt-empty/shortcut-pages"
  arch=('any')
  license=('unknown')
  provides=('shortcut-pages')

  cd "$srcdir/shortcut-pages/GUI"

  install -dvm755 "${pkgdir}/usr/share/shortcut/pages"
  find . -type f -iname "*.md" -exec  \
    install -Dvm644 "{}" "${pkgdir}/usr/share/shortcut/pages/{}" \;
}

package_shortcut-pages-extra-git() {
  pkgname=shortcut-pages-extra-git
  pkgdesc="An extra collection of cheatsheets for nonGUI applications and games"
  url="https://github.com/mt-empty/shortcut-pages"
  arch=('any')
  license=('unknown')
  provides=('shortcut-pages-extra' 'shortcut-pages')

  cd "$srcdir/shortcut-pages/misc/nonGUI"

    install -dvm755 "${pkgdir}/usr/share/shortcut/pages"
    find . -type f -iname "*.md" -not -regex "\.\/\(c\|git\|r\|unity\|\)\.md$" -exec \
      install -Dvm644 "{}" "${pkgdir}/usr/share/shortcut/pages/{}" \;
}

package_shortcut-c-client-git() {
  pkgname="shortcut-c-client-git"
  pkgdesc="A command line client for shortcut-pages"
  url="https://github.com/mt-empty/shortcut-c-client"
  arch=('x86_64')
  license=('unknown')
  depends=('shortcut-pages')
  optdepends=('shortcut-pages-extra')
  provides=('shorcut')

  cd "$srcdir/shortcut-c-client"
  install -Dvm755 shortcut "${pkgdir}/usr/bin/shortcut"
}

# vim: set ts=2 sts=2 sw=2 et: