summaryrefslogtreecommitdiff
path: root/pcr/ruby1/ruby.install
diff options
context:
space:
mode:
authoraurelien <aurelien@cwb.io>2013-09-23 10:33:22 +0200
committeraurelien <aurelien@cwb.io>2013-09-23 10:33:22 +0200
commit2735c9d273c54b555681f30f5c685998fed7b484 (patch)
treef8172dbea44d1c4751a99a62fb236a14c9d2dc20 /pcr/ruby1/ruby.install
parentd78a32a6ccb8663a62a093b54e947e2efc840fe0 (diff)
parent97f65e06566f3bb15bc7395624017b8e6ca0d043 (diff)
downloadabslibre-2735c9d273c54b555681f30f5c685998fed7b484.tar.gz
abslibre-2735c9d273c54b555681f30f5c685998fed7b484.tar.bz2
abslibre-2735c9d273c54b555681f30f5c685998fed7b484.zip
Merge branch 'master' of ssh://parabolagnulinux.org:1863/srv/git/abslibre
Diffstat (limited to 'pcr/ruby1/ruby.install')
-rw-r--r--pcr/ruby1/ruby.install22
1 files changed, 22 insertions, 0 deletions
diff --git a/pcr/ruby1/ruby.install b/pcr/ruby1/ruby.install
new file mode 100644
index 000000000..21e9b98a2
--- /dev/null
+++ b/pcr/ruby1/ruby.install
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+print_gem_default_target() {
+ echo 'The default location of gem installs is $HOME/.gem/ruby'
+ echo 'Add the following line to your PATH if you plan to install using gem'
+ echo '$(ruby1 -rubygems -e "puts Gem.user_dir")/bin'
+ echo 'If you want to install to the system wide location, you must either:'
+ echo 'edit /etc/gem1rc or run gem with the --no-user-install flag.'
+}
+
+# arg 1: the new package version
+post_install() {
+ print_gem_default_target
+}
+
+# arg 1: the new package version
+# arg 2: the old package version
+post_upgrade() {
+ if [ "$(vercmp $2 1.9.3_p125-4)" -lt 0 ]; then
+ print_gem_default_target
+ fi
+}