homebrew-cask/Casks/r.rb

35 lines
1.4 KiB
Ruby
Raw Normal View History

2014-03-04 03:17:42 +08:00
class R < Cask
2014-08-09 22:10:15 +08:00
if MacOS.version < :mavericks
2014-07-13 00:24:41 +08:00
url 'http://cran.rstudio.com/bin/macosx/R-3.1.1-snowleopard.pkg'
sha256 '4db95d2bffdaa342a89d01088f47cfe6575ed7e953c31ea4dea629a0942b56b6'
2014-09-10 23:37:06 +08:00
pkg 'R-3.1.1-snowleopard.pkg'
2014-08-09 22:10:15 +08:00
else
url 'http://cran.rstudio.com/bin/macosx/R-3.1.1-mavericks.pkg'
sha256 'd2f4e4f68628d998f81146eacd929ef6fb9bc01ca93d968e6562a3a6372c4d93'
2014-09-10 23:37:06 +08:00
pkg 'R-3.1.1-mavericks.pkg'
2014-04-23 01:03:04 +08:00
end
2014-03-04 03:17:42 +08:00
homepage 'http://www.r-project.org/'
2014-07-13 00:24:41 +08:00
version '3.1.1'
uninstall :pkgutil => [
# eg org.r-project.R.maverics.fw.pkg
# org.r-project.R.mavericks.GUI.pkg
'org\.r-project\.R\..*(fw|GUI)\.pkg',
# eg org.r-project.x86_64.tcltk.x11
'org.r-project\..*\.tcltk.x11',
],
:files => [
# symlinks
'/usr/bin/R',
'/usr/bin/Rscript',
'/Library/Frameworks/R.Framework/Versions/Current',
# :pkgutil won't delete this dir if the fontconfig cache was written to at
# /Library/Frameworks/R.Framework/Versions/3.1/Resources/fontconfig/cache
2014-04-23 01:03:04 +08:00
'/Library/Frameworks/R.Framework/Versions/3.1',
]
2014-09-14 01:19:44 +08:00
zap :files => [
'~/.R',
'~/.Rhistory',
'~/.Rprofile',
]
2014-03-04 03:17:42 +08:00
end