summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 5738a6ac89b46242bb5b40d349de3c7b2d86ddd8 (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
# Maintainer: Adam Goldsmith <contact@adamgoldsmith.name>

pkgname=sidequest-git
_pkgname=SideQuest
pkgver=v0.10.17.2.g768b1f7
pkgrel=1
pkgdesc="A tool to help simplify getting content onto Oculus Quest, Go, and other VR headsets."
arch=('any')
url="https://sidequestvr.com/"
license=('MIT')
depends=(electron4)
makedepends=(yarn)
provides=(sidequest)
conflicts=(sidequest)
options=(!strip)
source=("git+https://github.com/SideQuestVR/SideQuest"
        "sidequest"
        "openUrl-fix.patch"
        "SideQuest.desktop")
md5sums=('SKIP'
         'ef9bbe8b6707d3f195c6982a289f142a'
         '8412856865e2253c13f257f73bfe7e75'
         'aa393219b320d8b96c83714882de8b32')

pkgver() {
  cd "${srcdir}/${_pkgname}"
  git describe --tags | sed 's/-/./g'
}

prepare() {
  cd "${srcdir}/${_pkgname}"
  patch -p1 -i "${srcdir}/openUrl-fix.patch"
}

build() {
  cd "${srcdir}/${_pkgname}"
  yarn install
  yarn dist
}

package() {
  install -Dm644 "${_pkgname}.desktop" "${pkgdir}/usr/share/applications/${pkgname}.desktop"
  install -Dm755 "${_pkgname,,}" "$pkgdir/usr/bin/${_pkgname,,}"

  cd "${srcdir}/${_pkgname}"

  install -Dm644 "build/icons/512x512.png" "${pkgdir}/usr/share/icons/hicolor/512x512/apps/${_pkgname,,}.png"
  install -Dm644 "dist/linux-unpacked/resources/app.asar" "${pkgdir}/usr/share/${_pkgname}/app.asar"
  cp -r --no-preserve=mode,ownership "dist/linux-unpacked/resources/app.asar.unpacked" "${pkgdir}/usr/share/${_pkgname}/"
}

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