Merge pull request #76 from koos303/master
Fix Bundler symlinking on system path
This commit is contained in:
@@ -45,3 +45,8 @@ script:
|
|||||||
| grep -q '2'
|
| grep -q '2'
|
||||||
&& (echo 'Really deleted ruby test: pass' && exit 0)
|
&& (echo 'Really deleted ruby test: pass' && exit 0)
|
||||||
|| (echo 'Really deleted ruby test: fail' && exit 1)
|
|| (echo 'Really deleted ruby test: fail' && exit 1)
|
||||||
|
- >
|
||||||
|
ls ~/.rvm/wrappers/default/
|
||||||
|
| grep -q 'bundler'
|
||||||
|
&& (echo 'Bundler symlinked on system path test: pass' && exit 0)
|
||||||
|
|| (echo 'Bundler symlinked on system path test: fail' && exit 1)
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
galaxy_info:
|
galaxy_info:
|
||||||
author: Nick Janetakis
|
author: Nick Janetakis
|
||||||
description: The official rvm role to install and manage your ruby versions.
|
description: The official rvm role to install and manage your ruby versions.
|
||||||
company:
|
company:
|
||||||
license: license (MIT)
|
license: license (MIT)
|
||||||
min_ansible_version: 1.5
|
min_ansible_version: 1.5
|
||||||
|
|
||||||
|
|||||||
@@ -24,13 +24,20 @@
|
|||||||
when: detect_default_ruby_version.stdout == '' or
|
when: detect_default_ruby_version.stdout == '' or
|
||||||
rvm1_default_ruby_version not in detect_default_ruby_version.stdout
|
rvm1_default_ruby_version not in detect_default_ruby_version.stdout
|
||||||
|
|
||||||
|
- name: Detect installed ruby patch number
|
||||||
|
shell: >
|
||||||
|
{{ rvm1_rvm }} list strings | grep {{ item }} | tail -n 1
|
||||||
|
with_items: rvm1_rubies
|
||||||
|
changed_when: False
|
||||||
|
register: ruby_patch
|
||||||
|
|
||||||
- name: Install bundler if not installed
|
- name: Install bundler if not installed
|
||||||
shell: >
|
shell: >
|
||||||
{{ rvm1_install_path }}/wrappers/{{ item }}@global/gem list
|
ls {{ rvm1_install_path }}/wrappers/{{ item.stdout }}
|
||||||
| if ! grep "^bundler " ; then {{ rvm1_install_path }}/wrappers/{{ item }}@global/gem install bundler ; fi
|
| if ! grep "^bundler " ; then {{ rvm1_install_path }}/wrappers/{{ item.stdout }}/gem install bundler ; fi
|
||||||
args:
|
args:
|
||||||
creates: '{{ rvm1_install_path }}/wrappers/{{ item }}@global/bundler'
|
creates: '{{ rvm1_install_path }}/wrappers/{{ item.stdout }}/bundler'
|
||||||
with_items: rvm1_rubies
|
with_items: ruby_patch.results
|
||||||
register: bundler_install
|
register: bundler_install
|
||||||
changed_when: '"Successfully installed bundler" in bundler_install.stdout'
|
changed_when: '"Successfully installed bundler" in bundler_install.stdout'
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,6 @@
|
|||||||
|
|
||||||
- hosts: localhost
|
- hosts: localhost
|
||||||
remote_user: travis
|
remote_user: travis
|
||||||
sudo: true
|
|
||||||
|
|
||||||
vars:
|
vars:
|
||||||
rvm1_rubies:
|
rvm1_rubies:
|
||||||
|
|||||||
Reference in New Issue
Block a user