summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMeow2015-06-15 20:50:54 +0800
committerMeow2015-06-15 20:50:54 +0800
commitd3a1b77853a33274b13043d502de3a4a3f57720f (patch)
tree256efc49b93d005750598a33dc4c79f6861e0370
downloadaur-d3a1b77853a33274b13043d502de3a4a3f57720f.tar.gz
Initial import
-rw-r--r--.SRCINFO21
-rw-r--r--PKGBUILD54
-rw-r--r--rstudio-desktop-bin.install11
3 files changed, 86 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..99d258c50bc
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,21 @@
+pkgbase = rstudio-desktop-bin
+ pkgdesc = A new integrated development environment (IDE) for R (binary version from RStudio official website)
+ pkgver = 0.99.441
+ pkgrel = 2
+ url = http://www.rstudio.org/
+ install = rstudio-desktop-bin.install
+ arch = i686
+ arch = x86_64
+ license = GPL
+ depends = r>=2.11.1
+ depends = shared-mime-info
+ depends = qt5-webkit
+ depends = qt5-svg
+ provides = rstudio-desktop=0.99.441
+ conflicts = rstudio-desktop
+ conflicts = rstudio-desktop-git
+ conflicts = rstudio-desktop-preview-bin
+ source = http://download1.rstudio.org/rstudio-0.99.441-.deb
+
+pkgname = rstudio-desktop-bin
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..1cd6f84cf72
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,54 @@
+# Maintainer: Meow < a.li.devtty at gmail dot com >
+
+# Get download links and md5 sums for latest version of RStudio desktop
+cat <<_EOF_ >/dev/null
+## R code #############
+require(XML)
+page = htmlTreeParse("http://www.rstudio.com/products/rstudio/download/",useInternalNodes = T)
+links = sapply(getNodeSet(page,'//table[@class="downloads"]/thead/tr/th[text()="Installers"]/../../..//a[contains(@href,".deb")]'),xmlGetAttr,'href')
+md5sums = sapply(getNodeSet(page,'//table[@class="downloads"]/thead/tr/th[text()="Installers"]/../../..//a[contains(@href,".deb")]/../..//code'),xmlValue)
+print(cbind(links,md5sums))
+#######################
+_EOF_
+
+pkgname=rstudio-desktop-bin
+pkgver=0.99.441
+pkgrel=2
+pkgdesc="A new integrated development environment (IDE) for R (binary version from RStudio official website)"
+arch=('i686' 'x86_64')
+license=('GPL')
+url="http://www.rstudio.org/"
+depends=('r>=2.11.1' 'shared-mime-info' 'qt5-webkit' 'qt5-svg')
+conflicts=('rstudio-desktop' 'rstudio-desktop-git' 'rstudio-desktop-preview-bin')
+provides=("rstudio-desktop=${pkgver}")
+#options=(!strip)
+
+
+
+_x86md5=69337bf40062da23b441bbaff6753667
+_x64md5=6a5dc03fac32df8725c9f57e3608e029
+case "$CARCH" in
+ 'i686')
+ _arch=i386
+ md5sums=($_x86md5)
+ ;;
+ 'x86_64')
+ _arch=amd64
+ md5sums=($_x64md5)
+ ;;
+esac
+source=("http://download1.rstudio.org/rstudio-${pkgver}-${_arch}.deb")
+install="$pkgname".install
+
+package() {
+ msg "Converting debian package..."
+ cd "$srcdir"
+ tar zxpf data.tar.gz -C "$pkgdir"
+ install -dm755 "$pkgdir/usr/bin"
+ cd "$pkgdir/usr/lib/rstudio/bin"
+ rm lib*.so.*
+ cd "$pkgdir/usr/bin"
+ ln -s -f ../lib/rstudio/bin/rstudio rstudio-bin
+ find "$pkgdir/usr" -type d -print0 | xargs -0 chmod 755
+}
+# vim:ft=sh tabstop=2 expandtab
diff --git a/rstudio-desktop-bin.install b/rstudio-desktop-bin.install
new file mode 100644
index 00000000000..c4f58f1700d
--- /dev/null
+++ b/rstudio-desktop-bin.install
@@ -0,0 +1,11 @@
+post_install() {
+ xdg-icon-resource forceupdate --theme hicolor &>/dev/null
+ update-mime-database /usr/share/mime &>/dev/null
+ update-desktop-database -q
+}
+post_upgrade() {
+ post_install
+}
+post_remove() {
+ post_install
+}