evm
evm copied to clipboard
Automate `sudo mkdir /usr/local/evm` with Gem installation method
Hi,
Would it be convenient for the installation method that uses Gem to automate this?
I would not prefer that actually. First, there are many different ways to install Evm, not just via Ruby gem. Second, I don't like doing destructive operations like this automatically. I would like the user to have more control.
In case this is not automated, it would be nice with a bit more friendly error messages when the directory does not exist. For example this:
$ evm install emacs-24.3-bin
/Users/bjorne/.evm/lib/evm/package.rb:34:in `mkdir': No such file or directory - /usr/local/evm/emacs-24.3-bin (Errno::ENOENT)
from /Users/bjorne/.evm/lib/evm/package.rb:34:in `install!'
from /Users/bjorne/.evm/lib/evm/command/install.rb:20:in `initialize'
from /Users/bjorne/.evm/lib/evm/cli.rb:31:in `new'
from /Users/bjorne/.evm/lib/evm/cli.rb:31:in `parse'
from /Users/bjorne/.evm/bin/evm:7:in `<main>'
It would be nice if a the post-install message would remind the user about creating /usr/local/evm
as well.
+1 for adding a nice error message when /usr/local/evm
doesn't exist or is not owned by the user.
Pull requests are welcome! :)
I'm confused, do I need to create the directory and update PATH when I do gem install evm
?
I tried this, but there is no binary to execute, which evm
is blank. I looked in the gem installation directory but only the lib
and recipes
directories are there, which seems to match with the gemspec
file. So, how do I execute this from the command line?
@mattdeboard Evm has two directories. One where you install Evm and another where the Emacs versions are installed. The one we are talking about here is the one where the Emacs versions are installed and that should not be added to PATH
. You do however need to add the Evm installation directory to PATH
.