I would like to install Mercurial on a Linux system where I don't have root
access.
How can I do this in a way so that I can easily uninstall Mercurial again and upgrade it when new versions are released?
Also, can I get a package for Windows that does not require admin rights to install?
It is very easy to compile and install Mercurial in your home directory, I've done so myself.
This linked wiki-post will certainly provide some aid if you have questions;
Use make install-home
to install hg
to your home directory, it'll put the binary file in ~/bin and associative files in ~/lib.
When uninstalling or upgrading to a new version you could either delete the files that the makefile have put in, or let make install-home
(if upgrading) overwrite the existing files.
Make sure to update your $PATH
after installation so that it includes ~/bin
.
Following the link below will lead you to the download section of Mercurial. There you'll be able to find installation bundles for Windows that doesn't require administration rights.
I'm aware that this question is already answered but someone could be in the situation I was and that is to have to install without C compiler and make.
Full description of the solution can be found on following link.
List of commands, without using make
wget http://pypi.python.org/packages/2.5/s/setuptools/setuptools-0.6c11-py2.5.egg
mkdir -p ~/software/lib/python2.5/site-packages
export PYTHONPATH=~/software/lib/python2.5/site-packages
sh setuptools-0.6c11-py2.5.egg --prefix=~/software
export PATH=${PATH}:~/software/bin
easy_install --prefix=~/software docutils
cd ~/software
wget https://www.mercurial-scm.org/release/mercurial-2.5.2.tar.gz
tar xzvf mercurial-2.5.2.tar.gz
cd mercurial-2.5.2.tar.gz
python setup.py --pure install --home="~/software" --force
cd ~/software/lib/python
mv hgext/ ../python2.5/site-packages/
mv mercurial ../python2.5/site-packages/
mv mercurial-2.5.2.egg-info ../python2.5/site-packages/
Append following lines to .bashrc
:
export PYTHONPATH=~/software/lib/python2.5/site-packages
export PATH=${PATH}:~/software/bin
Check:
~$ hg
Mercurial Distributed SCM
etc...
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With