yochananmarqos

freetube

Oct 18th, 2021 (edited)
1,484
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. pkgname=freetube
  2. _pkgname=FreeTube
  3. _pkgver=0.15.0-beta
  4. pkgver=${_pkgver//-/.}
  5. pkgrel=1
  6. pkgdesc='An open source desktop YouTube player built with privacy in mind.'
  7. arch=('x86_64' 'aarch64' 'armv7h')
  8. url="https://freetubeapp.io"
  9. license=('AGPL3')
  10. depends=('electron13')
  11. makedepends=('npm' 'yarn')
  12. source=("$_pkgname-$_pkgver.tar.gz::https://github.com/FreeTubeApp/FreeTube/archive/v$_pkgver.tar.gz"
  13.         'package-only-necessary.diff'
  14.         "$pkgname.desktop"
  15.         "$pkgname.sh")
  16. sha256sums=('7e5f12444f881cc708b271aa4abd5ab9064c0577a297e7e0d4a02936b95f249b'
  17.             '40bc70f6e2996ba6d2e77e385a618737b7f4c68c9c0bc52bbb2de93dbb01de2f'
  18.             '1b518ac2f42db51294316b15313e997c7f0ff6245cf1eb74830fe7caeea4e70b'
  19.             'e4dab57eefc975469edf981984c76be17b574a51438e86f0df159ca6e2d8d637')
  20.  
  21. prepare() {
  22.   cd "$_pkgname-$_pkgver"
  23.   patch _scripts/build.js < ../package-only-necessary.diff
  24. }
  25.  
  26. build() {
  27.   cd "$_pkgname-$_pkgver"
  28.   yarn config set cache-folder "$srcdir/yarn-cache"
  29.   yarn install
  30.   yarn run build
  31. }
  32.  
  33. package() {
  34.   cd "$_pkgname-$_pkgver"
  35.   install -Dm644 build/linux-unpacked/resources/app.asar -t "$pkgdir/usr/lib/$pkgname"
  36.   install -Dm644 _icons/icon.svg "$pkgdir/usr/share/pixmaps/$pkgname.svg"
  37.   install -Dm755 "$srcdir/$pkgname.sh" "$pkgdir/usr/bin/$pkgname"
  38.   install -Dm644 "$srcdir/$pkgname.desktop" -t "$pkgdir/usr/share/applications"
  39. }
RAW Paste Data