RVM won't install system-wide on RHEL 6 - installation

I've been attempting to install rvm system-wide on a Red Hat Enterprise 6 system. In three tries, it always installed to my home directory.
I am a sudoer; sudo yum install emacs installed a /usr/bin/emacs.
Here is the command I gave:
sudo \curl -sSL https://get.rvm.io | bash -s stable --rails
Except for the --rails option, it's a straight copy from the installation instructions.
Regardless, the first line of the output is "Installing RVM to /home/fritza/.rvm/", and the next to last is "To start using RVM you need to run source /home/fritza/.rvm/scripts/rvm". There is no /usr/local/rvm, which is supposed to be a result of a system-wide installation.
I can't find any reference to this problem. Any ideas?
A possibility:
This is a system managed by a bureaucracy at the large higher-ed institution I work for. Maybe there is some kind of access control that blocks me from /usr/local. But if that were the case, surely the installer would have told me and quit, rather than switch over to a local install?
Other possibility:
RVM chooses the install location solely on the basis of whether it’s invoked through sudo. Could there be something in my installation that makes the installer believe it was launched into my environment?

Embarrassing error on my part...
I placed the sudo command at the start of the line instead of after the bar, for the invocation of bash.

Related

Command 'rvm' not found, did you mean:

I just installed rvm on my kali machine but after rebooting it, the terminal said that the command wasn't found and asked if I meant something else. I used curl -sSL https://get.rvm.io | bash -s stable --ruby to install and run the rvm install script. Everything went smooth and when the script finished, it said that all I had to do to get rvm running was execute source /usr/local/rvm/scripts/rvm, which I did. I even checked my path to make sure that everything was normal, and I think it is. Here is what it is:
/usr/local/rvm/gems/ruby-3.0.0/bin:/usr/local/rvm/gems/ruby-3.0.0#global/bin:/usr/local/rvm/rubies/ruby-3.0.0/bin:/opt/impacket/build/scripts-3.9:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/root/.dotnet/tools:/usr/local/go/bin/:/root/go-workspace/bin
Can someone help me solve this?
You'll need to update your bashrc (or equivalent) so that the rvm stuff gets imported every time.
Just add source /usr/local/rvm/scripts/rvm to the end of that file

how to install libX11 on OSx 10.9?

I am trying to install ROOT (cern.root.ch). When I run ./configure , I get a message that libX11 is missing and must be installed.
I did some research and found that I need to install
) XQuartz (I already have the latest version.)
) Command line tools in Xcode.
I tried installing Command Line Tools from apple's developer website. The installation goes through smoothly but how do I know whether it has been installed? I still get libX11 missing error with root's configure command.
I also tried xcode-select --install and it once went through smoothly and then later again gives error saying this package is no longer maintained - or something of that sort.
I understand I may have multiple installations... But I am still facing the problem of not having libX11 and not being able to install ROOT.
Thanks,
Hershal.
This link and the one referenced in it suggests you use homebrew (brew) to install it
$ ruby <(curl -fsS https://raw.github.com/mxcl/homebrew/go)
$ brew doctor
Remember to add the Homebrew directory to your PATH by adding the directory (found with brew --prefix) to your .bashrc, .zshrc or whatever shell file you’re using (.bashrc is the OS X default). We’ll also add the XQuartz binaries to the PATH in case anything needs them in the future.
export PATH=/usr/local/bin:/opt/X11/bin:$PATH
Start a new Terminal session to pick up the changes.
Now that Homebrew is installed, we can use it to install the required dependencies. Each may take some time as Homebrew generally compiles from source.
$ brew install gfortran # Fortran compiler
$ brew install python # Python interpreter
$ brew install pcre # Regular Expressions library
$ brew install fftw # Fast Fourier Transforms
$ brew install cmake # Cross-platform make
install root
$ brew tap homebrew/science
$ brew install --with-cocoa root
You don't say whether you have installed XCode as well as the commandline tools but I think you will need it

Installing SASS through my terminal on my MAC -newbie

I have done multiple searches for installing SASS through my terminal on my Mac, when I write the command gem install sass, it tells me
-bash: $: command not found"
so I tried the alternative sudo install process. My result is
-bash: $: command not found".
Am I missing something here?
Sorry for the dumb question. I'm just a web designer/developer trying to learn SASS, I did get a response once telling me this "WARNING: Improper use of the sudo command could lead to data loss or the deletion of important system files. Please double-check your typing when using sudo. Type "man sudo" for more information. To proceed, enter your password, or type Ctrl-C to abort. Password:"(My typing was correct) so I type my PW. it then tells me it's the wrong PW. - I have one PW on this machine. What am I doing wrong?
I did get this error message after a third try " You don't have write permissions into the /Library/Ruby/Gems/1.8 directory.
Jasons-MacBook-Pro:~ JHess$ "
Do I not have the right permissions set up to perform the SASS install? I found a similar question on Stack regarding this issue - and it told me to install RVM. What exactly is RVM? Is it some type of bundled package?
Any help would be GREATLY appreciated. I just attended a web conference in VA, "ConvergeRVA" and just recently graduated college, I'm not a seasoned vet like most peeps on here. But I would love to start learning SASS.
Note: I am running Mac OS X Lion 10.7.5
In order to use Sass you need Ruby installed. The error messages shows you have an old version 1.8.7
Update to a current version using RVM.
RVM is a command-line tool which allows you to easily install, manage, and work with multiple ruby environments
Copy and paste this into your terminal.
\curl -sSL https://get.rvm.io | bash -s stable --ruby
look at http://screencasts.org/episodes/how-to-use-rvm to learn how to use it.
After this is done try gem install sass again
You haven't installed Mac OS X Command Line Tools. It can be found at:
Xcode > Preferences > Downloads > Command Line Tool
Download & Install it, and restart the Terminal.

Linux Install RVM without using CURL

My current environment (including a corporate proxy) is not allowing me to install RVM with CURL or WGET for something reason. Is there another way to install RVM from source without these utilities? Every web search I've done returns the 'curl' way.
Any ideas?
modifying rvm scripts is not a good idea
I was thinking about your question/my answer while trying to sleep... and I couldn't get an eye closed without writing you another answer. Hacking the rvm install script is really not what you should do. Rvm uses curl everywhere (installation, downloading rubies, updating, ...). And you have to download many more things -- for example gems. Replacing every curl-call in every script is not maintainable.
proposed solution
The good thing about rvm is, that is stores all its data in the ~/.rvm directory. Considering this, you can install rvm on a remote computer (or VM), which is as similar as possible (same OS, same OS version, same libraries) to your development computer. Install all the rubies, gemsets and gems you need. Then move the zipped ~/.rvm directory to your development computer and unpack it to ~/.rvm.
Don't forget to do
echo "source $HOME/.rvm/scripts/rvm" >> ~/.bash_profile
to source rvm while loading your bash.
If you ever have to update or install gems or ruby versions, do your business on the remote computer, and copy ~/.rvm again.
my experience with this setup
I use this setup (although it is automated with our CI server) for ¬2 years now for a production environment which is in a similar wicked corporate network. Changing gems/rubies is harder than it should be, but it works without an internet connection.
Edit: Added a paragraph about my experience with this setup
You find the rvm install script here. You can
download it
modify the parts where curl is used
execute the script, which now refers to the manually downloaded files
1. Download
Download this file to /tmp/rvm-installer .
Now download the rvm.tar.gz file to /tmp/rvm-1.19.6.tar.gz
2. modify the file
At line 148 begins function fetch_version. Replace it with the following function:
fetch_version()
{
echo '1.19.6' # the current version, as of writing this
}
At line 161 (within install_release) the get_and_unpack function is called.
replace the function call with:
get_and_unpack \
/tmp/rvm-${_version}.tar.gz \
rvm-${_version}.tar.gz
At line 212 (within get_and_unpack) replace
__rvm_curl ${_url} -o ${rvm_archives_path}/${_file} ||
with:
mv ${_url} ${rvm_archives_path}/${_file} ||
3. finally install rvm
cd /tmp
cat rvm-installer | bash -s -- --version latest --autolibs=enabled
Disclaimer: This is still a hack. It installs rvm, but I don't know about updating (here rvm uses curl again). Good luck :)

rvm install on rhel6

ok, so i'm coming from a python virtualenv environment, so please bear with me...
i am trying to install rvm on a non-internet visible machine (ie it doesn't have direct outside access). so
curl -L https://get.rvm.io | bash -s stable --ruby
would not work. no problems i thought, i'll just copy the file over from another machine and do a cat that worked, however, because rvm tries to download the source files directly from the web, it again failed....
so i found that if i put the tarballs under ~/.rvm/archives, i can install rvm as a single user (and take up ~200MB of my home space)... however, i want to install for multiuser for production purposes and use .rvm directories in my project. however, my /usr/local is read only (afs mount).... so rvm fails again.
any ideas? i don't particularly like the idea of having a rvm user and group.
I believe you can supply --path=/opt/rvm to the RVM install script to change the location of a multi-user installation.
I don't believe the RVM group can be changed as it relies on that group to operate correctly.
hmm... so i decided to look at the rvm-install script (ie https://get.rvm.io). basically, it was hardcoded to /usr/local/rvm, so i just changed that to /opt/rvm.
i then also had to add a check for the rvm tarball under the get_and_unpack function:
if [ -e ${rvm_archives_path}/${_file} ]
then
true
elif curl -L ${_url} -o ${rvm_archives_path}/${_file}
then download the file at https://github.com/wayneeseguin/rvm/tarball/master into /opt/rvm/archives/wayneeseguin-rvm-master.tgz
that installed rvm fine into /opt/rvm.
however, logging back in will result in -bash: __rvm_add_to_path: command not found. this is because the profile.d script is hard coded to /usr/local/, so doing a find and replace on /etc/profile.d/rvm.sh to /opt/ did the trick.
however, all the files are still group'd to rvm. which is fine, but another group i have to justify to my unix-admin.

Resources