Sha256: 8950fb196dc7d01eabbdf3744da40497ad465a3cbf3f41f300d455ecd14c8fea

Contents?: true

Size: 820 Bytes

Versions: 3

Compression:

Stored size: 820 Bytes

Contents

#!/usr/bin/env bash

environment_id="ruby-1.9.3-p0@loaf"

if [[ -d "${rvm_path:-$HOME/.rvm}/environments" \
  && -s "${rvm_path:-$HOME/.rvm}/environments/$environment_id" ]]
then
  \. "${rvm_path:-$HOME/.rvm}/environments/$environment_id"

  if [[ -s "${rvm_path:-$HOME/.rvm}/hooks/after_use" ]]
  then
    . "${rvm_path:-$HOME/.rvm}/hooks/after_use"
  fi
else
  # If the environment file has not yet been created, use the RVM CLI to select.
  if ! rvm --create  "$environment_id"
  then
    echo "Failed to create RVM environment '${environment_id}'."
    return 1
  fi
fi

if [[ $- == *i* ]] # check for interactive shells
then
    echo "Using: $(tput setaf 2)$GEM_HOME$(tput sgr0)" # show the user the ruby and gemset they are using in green
else
  echo "Using: $GEM_HOME" # don't use colors in interactive shells
fi

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
loaf-0.3.0 .rvmrc
loaf-0.2.1 .rvmrc
loaf-0.2.0 .rvmrc