C
C
Chvalov2018-07-27 03:02:32
Debian
Chvalov, 2018-07-27 03:02:32

How to make Ruby work as a user?

Installed ruby ​​and rails from the redmine user
From the user, only the command is available for execution rvm
Commands ruby -vor bundledo not work
Writes that the command was not found
Registered PATH:

~/.profile
# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/bin" ] ; then
    PATH="$HOME/bin:$PATH"
fi

# set PATH so it includes rvm bin if it exists
if [ -d "$HOME/.rvm/bin" ] ; then
  PATH="$PATH:$HOME/.rvm/bin"
fi

if [ -s "$HOME/.rvm/scripts/rvm" ] ; then
  source "$HOME/.rvm/scripts/rvm"
fi

if [ -s "$HOME/.rvm/scripts/completion" ] ; then
  source "$HOME/.rvm/scripts/completion"
fi

Nothing helped, also registered exportin .bashrc
# Add RVM to PATH for scripting. Make sure this is the last PATH variable change.
export PATH="$PATH:$HOME/.rvm/bin:$HOME/.rvm/scripts/rvm"

No changes, what to do in such a situation ??
Works only after executing the command:
source /home/redmine/.rvm/scripts/rvm
but entering the command every time is not an option!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
C
Chvalov, 2018-07-27
@Chvalov

In ~/.bashrcor ~/.profileput:

# This loads RVM into a shell session.
 && . "$HOME/.rvm/scripts/rvm"

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question