Username: Password: Remember me
# Maintainer: Antonio Davide Trogu <trogu.davide[at]gmail[dot].com>
 
pkgname=electron2
pkgver=2.0.17
pkgrel=1
pkgdesc="Framework for writing cross-platform desktop applications using JavaScript, HTML and CSS."
arch=('x86_64')
url="https://github.com/atom/electron"
license=('MIT')
depends=('libgcrypt15' 'libnotify' 'gconf' 'alsa-lib' 'nss' 'libxtst' 'gtk2' 'libgnome-keyring')
optdepends=('nodejs')
conflicts=('electron3')
replaces=('atom-shell' 'electron3')
source=("electron.zip::https://github.com/atom/electron/releases/download/v$pkgver/electron-v$pkgver-linux-x64.zip")
md5sums=('4227149c22871b98583f475a7c78c443')
 
package() {
  rm electron.zip
 
  install -d "$pkgdir/usr/share/electron"
  cp -a "${srcdir}/." "$pkgdir/usr/share/electron"
 
  install -d "$pkgdir/usr/bin"
  ln -s "/usr/share/electron/electron" "$pkgdir/usr/bin/electron"
 
  install -Dm644 "$pkgdir/usr/share/electron/LICENSE" "$pkgdir/usr/share/licenses/electron/LICENSE"
  rm "$pkgdir/usr/share/electron/LICENSE"
  ln -sf "/usr/lib/libgcrypt.so.11" "$pkgdir/usr/share/electron/libgcrypt.so.11"
  #ln -sf "/usr/lib/libnotify.so.4" "$pkgdir/usr/share/electron/libnotify.so.4"
  ln -sf "/usr/lib/libudev.so" "$pkgdir/usr/share/electron/libudev.so.0"
 
  find "$pkgdir" -type d -exec chmod 755 {} +
  find "$pkgdir" -type f -exec chmod 644 {} +
  chmod 755 "$pkgdir/usr/share/electron/electron"
}