Sha256: 08a0b0eaa156dc03b0f4b1fdb3097bd9763caa3bc839a598ef3d15c6a3a85e25
Contents?: true
Size: 532 Bytes
Versions: 1
Compression:
Stored size: 532 Bytes
Contents
# frozen_string_literal: true set :chruby_path, '/etc/profile.d/chruby.sh' task :chruby, :env do |_, args| unless args[:env] puts "Task 'chruby' needs a Ruby version as an argument." puts "Example: invoke :chruby, 'ruby-2.4'" exit 1 end comment %(chruby to version: \\"#{args[:env]}\\") command %( if [[ ! -s "#{fetch(:chruby_path)}" ]]; then echo "! chruby.sh init file not found" exit 1 fi ) command %(source #{fetch(:chruby_path)}) command %(chruby "#{args[:env]}" || exit 1) end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
mina-1.2.5 | tasks/mina/chruby.rb |