Differences between revisions 24 and 606 (spanning 582 versions)
Revision 24 as of 2009-07-02 11:26:37
Size: 7139
Comment: easy_install merits a separate heading
Revision 606 as of 2021-10-01 20:25:20
Size: 9847
Editor: CarlReinke
Comment: Replace ancient Windows information with a link to the downloads page
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
#pragma section-numbers 2
= Download =
Source archives and binary packages for various systems. See WhatsNew for information on upgrading.
Line 3: Line 7:
= Source packages = == Binary packages ==
=== Windows ===
/!\ '''Like TortoiseSVN, [[https://www.mercurial-scm.org/pipermail/mercurial/2010-January/029680.html|we recommend]] turning off the indexing service on the working copies and repositories, and excluding them from virus scans.'''
Line 5: Line 11:
 * Source code of [[WhatsNew|released versions]] of Mercurial can be downloaded as usual .tar.gz files at [[http://www.selenic.com/mercurial/release/?M=D|http://www.selenic.com/mercurial/release/]].
 * The [[http://selenic.com/repo/hg-stable|hg-stable]] repository leads to stable releases - download [[http://www.selenic.com/mercurial-stable-snapshot.tar.gz|hourly snapshot]].
 * The [[http://selenic.com/repo/hg|hg]] repository is the main development repository - download [[http://www.selenic.com/mercurial-snapshot.tar.gz|hourly snapshot]].
 * Check DeveloperRepos for other relevant developer repositories where you can get clone the hg source.
 * Windows installers are available on the [[https://www.mercurial-scm.org/downloads|downloads page]]

=== Mac OS X ===
 * Mac OS X packages are available on the [[https://www.mercurial-scm.org/downloads|downloads page]]
 * [[http://pdb.finkproject.org/pdb/package.php/mercurial|Fink]]: install with 'fink install mercurial' - 3.3
 * [[https://trac.macports.org/browser/trunk/dports/devel/mercurial/Portfile|macports]]: install with 'sudo port install mercurial' - 3.3
 * [[https://github.com/Homebrew/homebrew-core/blob/master/Formula/mercurial.rb|homebrew]]: install with 'brew install mercurial' - 3.8.1
 * TortoiseHg for Mac available [[https://bitbucket.org/tortoisehg/files/downloads|here]] - 3.7.3

=== Linux (.deb) ===
 * '''Debian'''
  * [[https://packages.debian.org/sid/mercurial|Debian sid (unstable)]] - 5.5.2
  * [[https://packages.debian.org/bullseye/mercurial|Debian bullseye (testing)]] - 5.5.2
  * [[https://packages.debian.org/buster/mercurial|Debian buster (stable)]] - 4.8.2
  * [[https://packages.debian.org/stretch/mercurial|Debian stretch (oldstable)]] - 4.0
 * '''Ubuntu'''
  * [[https://packages.ubuntu.com/groovy/mercurial|Ubuntu Groovy]] - 5.5.1
  * [[https://packages.ubuntu.com/focal/mercurial|Ubuntu Focal]] - 5.3.1
  * [[https://packages.ubuntu.com/bionic/mercurial|Ubuntu Bionic]] - 4.5.3
  * [[https://packages.ubuntu.com/xenial/mercurial|Ubuntu Xenial]] - 3.7.3

Mercurial (from 1.0 onwards) is packaged for Debian-related distributions as two packages, ''mercurial'' and ''mercurial-common'' - you only need to care about this if you are downloading .deb files for manual installation - otherwise, APT dependency handling will take care of this for you when you install ''mercurial''.

Another way to get .deb packages is to build them from a Mercurial source repository with `make deb` (builds on local system) or `make docker-<distro>-<codename>` (e.g. `docker-debian-stretch` or `docker-ubuntu-bionic`, see Source:contrib/packaging/Makefile).

To get the '''latest''' Mercurial version, instead of the old versions listed above, try:
{{{
sudo add-apt-repository -y ppa:mercurial-ppa/releases
sudo apt-get update
sudo apt-get install -y python-pip python-dev
sudo pip install mercurial --upgrade
}}}
(see the full answer on [[https://stackoverflow.com/a/15773831/410713|stackoverflow]])

=== Linux (.rpm) ===
Since Mercurial version 3.4, the Mercurial project provides packages for the following systems:

 * [[http://www.mercurial-scm.org/release/centos5/RPMS/x86_64/|Centos 5]] (includes a python2.7 install)
 * [[http://www.mercurial-scm.org/release/centos6/RPMS/x86_64/|Centos 6]]
 * [[http://www.mercurial-scm.org/release/centos7/RPMS/x86_64/|Centos 7]]

You can download, install and upgrade the packages manually.

You can also add it as a "yum" package repository and get automatic updates: Add the following file at `/etc/yum.repos.d/mercurial.selenic.com.repo` and run `yum install mercurial`.

{{{
[mercurial.selenic.com]
name=mercurial.selenic.com
baseurl=https://www.mercurial-scm.org/release/centos$releasever
enabled=1
# Temporary until we get a serious signing scheme in place,
# check https://www.mercurial-scm.org/wiki/Download again
gpgcheck=0
}}}
/!\ Mercurial is stable and won't break on automatic updates. Mercurial do however not promise API stability so an update might break extensions or tools using Mercurial internals.

Similar Fedora packages can be built from a Mercurial source repository with commands like `make docker-fedora21`. "Unsupported" platforms can use `contrib/buildrpm` directly.

You can also install the package from your distribution

 * [[http://rpmfind.net/linux/rpm2html/search.php?query=mercurial&submit=Search+...&system=mandriva&arch=|Mandriva]]: install with {{{urpmi mercurial}}} - latest revision available
 * [[http://koji.fedoraproject.org/koji/packageinfo?packageID=2518|Fedora]] - latest version is available within few days after release, install with {{{yum install '*mercurial}}}*'
 * [[http://fedoraproject.org/wiki/EPEL|Fedora Projects EPEL]] for RHEL and CentOS 5: 1.3.1, install with {{{yum install '*mercurial}}}*'
 * [[http://download.opensuse.org/repositories/devel:/tools:/scm/|openSUSE]] - latest version is available shortly after release in the `devel:tools:scm` repository
 * [[http://arklinux.osuosl.org/dockyard-devel/SRPMS/|Ark Linux]] - 1.6.2
 * [[http://www.openpkg.org/product/packages/?package=mercurial|OpenPKG]] - 1.4

=== Linux (others) ===
 * [[http://archlinux.org/packages/?q=mercurial|Arch Linux]] - 4.6.2
 * [[http://packages.gentoo.org/package/dev-vcs/mercurial|Gentoo ebuild]]: install with {{{emerge mercurial}}} - 4.6.2
 * [[http://www.t2-project.org/packages/mercurial.html|T2 SDE]] - 4.6.2
 * [[http://slackware.osuosl.org/slackware-current/slackware/d/|Slackware]] - 4.6.2
 * [[http://ipkg.nslu2-linux.org/feeds/optware/|Optware cross compilation ipk]] - latest for Python 2.4 and 2.5

=== Solaris ===
 * [[http://unixpackages.com/packages/package-matrix?frm_search=mercurial|unixpackages.com]] - SPARC/Solaris 2.6-10 packages, x86/Solaris 8-11 packages - 2.3 (8 & 9), 4.2 (10 & 11)
 * [[http://www.opencsw.org|OpenCSW]]: [[http://www.opencsw.org/packages/mercurial|solaris package mercurial-3.8.2, sparc/solaris, x86/solaris]].

=== AIX ===
 * [[http://www.lunch.org.uk/wiki/aix_packages|Mercurial for AIX 5.2 and later]] - 3.0.2

=== BSD ===
 * [[http://www.freebsd.org/cgi/cvsweb.cgi/ports/devel/mercurial/|FreeBSD]]; use [[http://freebsd.org/cgi/man.cgi?query=pkg_add&apropos=0&sektion=0&manpath=FreeBSD+6.3-RELEASE&format=html|pkg_add]] for installing - 4.6 (on 2018-07-16)

 * [[ftp://ftp.netbsd.org/pub/pkgsrc/current/pkgsrc/devel/mercurial/README.html|NetBSD]] packages compiled from [[http://pkgsrc.se/devel/mercurial|pkgsrc]] - always very up-to-date, currently 4.6.1

=== Plan 9 from Bell Labs ===
 * To build from source, see: Plan9FromBellLabs
 * Binary packages are available from fgb's contrib:

{{{
% contrib/install stallion/mercurial
}}}
=== Other ===
{i} If you didn't find your favorite distro/package manager above, or if the package version listed on this wiki page seems too old, try https://repology.org/metapackage/mercurial/versions.

== Source packages ==
 * Source code of [[WhatsNew|released versions]] of Mercurial can be downloaded as usual .tar.gz files at [[https://www.mercurial-scm.org/release/?M=D|https://www.mercurial-scm.org/release/]].
 * The [[http://mercurial-scm.org/repo/hg-stable|hg-stable]] repository leads to stable releases - download [[http://mercurial-scm.org/repo/hg-stable/archive/tip.tar.gz|snapshot]].
 * The [[http://mercurial-scm.org/repo/hg|hg]] repository is the main development repository - download [[http://mercurial-scm.org/repo/hg/archive/tip.tar.gz|snapshot]].
 * Check DeveloperRepos for other relevant developer repositories where you can clone the hg source.
Line 12: Line 115:
= Binary packages = == Using pip ==
Mercurial can also be installed from [[https://pypi.python.org/pypi/Mercurial|PyPI]] with {{{pip}}}, which has shipped with Python since 2.7.9 and 3.4 or can be installed using the instructions on https://pip.pypa.io/en/stable/installing.html.
Line 14: Line 118:
If you have Python and setuptools installed, you can also use [[EasyInstall|easy_install]]. To install with {{{pip}}} you must have the same C compiler used to compile Python installed as well as the development headers for Python (typically called {{{python-dev}}} or {{{python-devel}}} on Linux).
Line 16: Line 120:
== Windows ==
 * [[TortoiseHg]] all-in-one installer with MS-Explorer integration. Version 0.8 includes Mercurial 1.3
 * [[http://mercurial.berkwood.com|Windows]] installer - latest release, previous builds, snapshots
 * [[http://bitbucket.org/tortoisehg/stable/downloads/|Nightly builds]] - sneak preview of next version of TortoiseHg and Mercurial. Warning: Do not use in production environment.
 * [[http://cygwin.com/|cygwin]] can install mercurial.
You may then install Mercurial simply by executing {{{pip install Mercurial}}}.
Line 22: Line 122:
== Mac OS X ==
 * [[http://mercurial.berkwood.com|Mac OS X]] packages (you may have to add `export LC_ALL=en_US.UTF-8` and `export LANG=en_US.UTF-8` to your `~/.profile`)
 * [[http://pdb.finkproject.org/pdb/package.php/mercurial-py25|fink package]]
 * [[http://www.macports.org/|macports]] can install mercurial by 'sudo port install mercurial'.
== Using conda ==
Conda is a cross-platform package manager with a focus on Python. You can install mercurial into a python2.7 conda environment with the following invocation:
Line 27: Line 125:
== Linux (.deb) ==
 * '''Debian'''
  * Debian squeeze (testing) includes [[http://packages.debian.org/squeeze/mercurial|1.1.2]] in the distribution.
  * Debian lenny (stable) includes [[http://packages.debian.org/lenny/mercurial|1.0.1]] in the distribution.
 * '''Ubuntu'''
  * Included in the distribution:
   * Ubuntu Hardy includes [[http://packages.ubuntu.com/hardy/mercurial|0.9.5]], with [[http://packages.ubuntu.com/hardy-backports/mercurial|1.0.1]] available if you [[https://help.ubuntu.com/community/UbuntuBackports|enable backports]]
   * Ubuntu Intrepid includes [[http://packages.ubuntu.com/intrepid/mercurial|1.0.1]].
   * Ubuntu Jaunty includes [[http://packages.ubuntu.com/jaunty/mercurial|1.1.2]].
  * Launchpad PPAs, carrying packages for Hardy, Intrepid and Jaunty:
   * [[https://launchpad.net/~mercurial-ppa/+archive/releases|mercurial-ppa/releases PPA]]: The latest Mercurial release.
   * [[https://launchpad.net/~mercurial-ppa/+archive/stable-snapshots|mercurial-ppa/stable-snapshots PPA]]: Automatic daily snapshot of `hg-stable` DeveloperRepos. <<BR>>''('''Please note''' that these packages are '''not''' releases. If you use these, you are testing unreleased code.)''
   * [[https://launchpad.net/~mercurial-ppa/+archive/snapshots|mercurial-ppa/snapshots PPA]]: Automatic daily snapshot of `hg` DeveloperRepos. <<BR>>''('''Please note''' that these packages are '''not''' releases. If you use these, you are testing unreleased code.)''
{{{
conda install -c conda-forge mercurial
}}}
This should work on OSX, Windows, and Linux. If you would like to update the conda package, see the instructions at https://github.com/conda-forge/mercurial-feedstock
Line 41: Line 130:
Mercurial (from 1.0 onwards) is packaged for Debian-related distributions as two packages, ''mercurial'' and ''mercurial-common'' - you only need to care about this if you are downloading .deb files for manual installation - otherwise, APT dependency handling will take care of this for you when you install ''mercurial''. == Using easy_install ==
/!\ {{{easy_install}}} is a legacy installation method which has been superseded by {{{pip}}} which should be preferred over {{{easy_install}}}. This method should not be used and is not recommended and will most likely cause conflict with other installs of Mercurial.
Line 43: Line 133:
== Linux (.rpm) ==
 * Mandriva includes Mercurial - install with {{{urpmi mercurial}}} or manually [[http://rpmfind.net/linux/rpm2html/search.php?query=mercurial&submit=Search+...&system=mandriva&arch=|search rpm]]
 * Fedora: All supported versions includes Mercurial - install with {{{yum install mercurial}}}. To get full functionality also run {{{yum install mercurial-hgk emacs-mercurial emacs-mercurial-el bash-completion meld kdiff3}}}. Beta releases can be tracked [[http://koji.fedoraproject.org/koji/packageinfo?packageID=2518|here]].
 * [[http://repos.opensuse.org/devel:/tools:/scm|OpenSUSE]]
 * [[http://www.arklinux.org/|Ark Linux]] always contains a current mercurial package. Ark Linux users should simply {{{apt-get update; apt-get install mercurial}}}. Users of other distributions can find the packages (which should work on pretty much any RPM based distribution that has Python 2.4) [[http://arklinux.osuosl.org/dockyard-devel|here]].
 * [[http://www.openpkg.org/product/packages/?package=mercurial|OpenPKG]] - lists 0.9.3, though 0.9.4 is downloadable
 * [[http://code.google.com/p/i18n-zh/wiki/Mercurial|CentOS 4.5]] - latest released version 0.9.4.
 * CentOS release 5 (final) - {{{yum install mercurial}}} from rpmforge repository, latest stable (1.0)
Mercurial can also be installed from [[https://pypi.python.org/pypi/Mercurial/|pypi]] with {{{easy_install}}}. You will need Python and the C compiler used to build it and {{{easy_install}}}. {{{easy_install}}} might be available in a {{{python-dev}}} or {{{python-setuptools-devel}}} package for your platform or you can grab it from http://peak.telecommunity.com/DevCenter/EasyInstall.
Line 52: Line 135:
== Linux (others) ==
 * [[http://archlinux.org/packages/search/?repo=all&category=all&q=mercurial&lastupdate=&limit=50|Arch Linux]]
 * [[http://packages.gentoo.org/package/dev-util/mercurial|Gentoo ebuild]]
 * [[http://www.t2-project.org/packages/mercurial.html|T2 SDE]] package of official releases
 * [[ftp://ftp.osuosl.org/pub/slackware/slackware-12.0/slackware/d/mercurial-0.9.4-i486-1.tgz|Slackware 12.0]] - 0.9.4 official package
 * [[http://ipkg.nslu2-linux.org/feeds/optware/|Optware cross compilation ipk]] - latest for Python 2.4 and 2.5
/!\ [[http://code.google.com/p/rdflib/issues/detail?id=104|Unable to find vcvarsall.bat]] fix error with mingw and install mercurial 1.7.3 with python 2.7
Line 59: Line 137:
== Solaris ==
 * [[http://www.opensolaris.org/os/community/tools/scmdownloads/|OpenSolaris package]]
 * [[http://www.blastwave.org/packages.php/mercurial|blastwave, solaris 8 to 10 package]]
 * [[http://sunfreeware.com|sunfreeware.com]] - SPARC/Solaris 7-10 packages, x86/Solaris 8-10 packages - 1.1.2
{{{
Create a file in C:\Python26\Lib\distutils and call it distutils.cfg
[build]
compiler=mingw32
}}}
With the right prerequisites you can install the latest version of Mercurial using:
Line 64: Line 144:
== BSD ==
 * [[http://www.freebsd.org/cgi/url.cgi?ports/devel/mercurial/pkg-descr|FreeBSD Mercurial port]] ([[http://www.freebsd.org/cgi/cvsweb.cgi/ports/devel/mercurial/|port-webdir]]). i386 package: [[ftp://ftp.freebsd.org/pub/FreeBSD/ports/i386/packages-stable/devel/mercurial-1.1.2.tbz|mercurial-1.1.2.tbz]].
   * Requires [[http://www.freebsd.org/cgi/cvsweb.cgi/ports/lang/python25/|python25]] (i386 package: [[ftp://ftp.freebsd.org/pub/FreeBSD/ports/i386/packages-stable/lang/python25-2.5.2_1.tbz|python25-2.5.2_1.tbz]]).
   Use [[http://www.freebsd.org/cgi/man.cgi?query=pkg_add&apropos=0&sektion=0&manpath=FreeBSD+6.3-RELEASE&format=html|pkg_add]] for installing.
 * [[ftp://ftp.netbsd.org/pub/pkgsrc/current/pkgsrc/devel/mercurial/README.html|NetBSD]] packages compiled from [[http://pkgsrc.se/devel/mercurial|pkgsrc]]
{{{
easy_install -U mercurial
}}}
= Source repository =
You can get Mercurial using Mercurial:
Line 70: Line 150:
{{{
https://www.mercurial-scm.org/repo/hg/ my-mercurial-clone
cd my-mercurial-clone
hg up "max(tagged())"
make install
}}}
----
CategoryProject
Line 71: Line 159:
== AIX ==
 * AIX RPM packages are available via [[http://www.lunch.org.uk/wiki/aix_packages]]. Binary packages are built on AIX 5.2.

= Using easy_install =

If you already have Python installed, you can install the latest version of Mercurial using {{{easy_install}}}:

{{{ easy_install -U mercurial }}}

This is also the easiest way of installing a Mercurial newer than the one provided by your distribution.

If you have Python, but not {{{easy_install}}}, grab it from http://peak.telecommunity.com/DevCenter/EasyInstall.

Note: you may need the {{{python-dev}}} package to run {{{easy_install}}}.
[[FrenchDownload|Francais]], [[ChineseDownload|中文]], [[JapaneseDownload|日本語]]

Download

Source archives and binary packages for various systems. See WhatsNew for information on upgrading.

1. Binary packages

1.1. Windows

/!\ Like TortoiseSVN, we recommend turning off the indexing service on the working copies and repositories, and excluding them from virus scans.

1.2. Mac OS X

  • Mac OS X packages are available on the downloads page

  • Fink: install with 'fink install mercurial' - 3.3

  • macports: install with 'sudo port install mercurial' - 3.3

  • homebrew: install with 'brew install mercurial' - 3.8.1

  • TortoiseHg for Mac available here - 3.7.3

1.3. Linux (.deb)

Mercurial (from 1.0 onwards) is packaged for Debian-related distributions as two packages, mercurial and mercurial-common - you only need to care about this if you are downloading .deb files for manual installation - otherwise, APT dependency handling will take care of this for you when you install mercurial.

Another way to get .deb packages is to build them from a Mercurial source repository with make deb (builds on local system) or make docker-<distro>-<codename> (e.g. docker-debian-stretch or docker-ubuntu-bionic, see contrib/packaging/Makefile).

To get the latest Mercurial version, instead of the old versions listed above, try:

sudo add-apt-repository -y ppa:mercurial-ppa/releases
sudo apt-get update
sudo apt-get install -y python-pip python-dev
sudo pip install mercurial --upgrade

(see the full answer on stackoverflow)

1.4. Linux (.rpm)

Since Mercurial version 3.4, the Mercurial project provides packages for the following systems:

You can download, install and upgrade the packages manually.

You can also add it as a "yum" package repository and get automatic updates: Add the following file at /etc/yum.repos.d/mercurial.selenic.com.repo and run yum install mercurial.

[mercurial.selenic.com]
name=mercurial.selenic.com
baseurl=https://www.mercurial-scm.org/release/centos$releasever
enabled=1
# Temporary until we get a serious signing scheme in place,
# check https://www.mercurial-scm.org/wiki/Download again
gpgcheck=0

/!\ Mercurial is stable and won't break on automatic updates. Mercurial do however not promise API stability so an update might break extensions or tools using Mercurial internals.

Similar Fedora packages can be built from a Mercurial source repository with commands like make docker-fedora21. "Unsupported" platforms can use contrib/buildrpm directly.

You can also install the package from your distribution

  • Mandriva: install with urpmi mercurial - latest revision available

  • Fedora - latest version is available within few days after release, install with yum install '*mercurial*'

  • Fedora Projects EPEL for RHEL and CentOS 5: 1.3.1, install with yum install '*mercurial*'

  • openSUSE - latest version is available shortly after release in the devel:tools:scm repository

  • Ark Linux - 1.6.2

  • OpenPKG - 1.4

1.5. Linux (others)

1.6. Solaris

1.7. AIX

1.8. BSD

  • FreeBSD; use pkg_add for installing - 4.6 (on 2018-07-16)

  • NetBSD packages compiled from pkgsrc - always very up-to-date, currently 4.6.1

1.9. Plan 9 from Bell Labs

  • To build from source, see: Plan9FromBellLabs

  • Binary packages are available from fgb's contrib:

% contrib/install stallion/mercurial

1.10. Other

{i} If you didn't find your favorite distro/package manager above, or if the package version listed on this wiki page seems too old, try https://repology.org/metapackage/mercurial/versions.

2. Source packages

After getting the source, continue to UnixInstall or WindowsInstall for help with installing.

3. Using pip

Mercurial can also be installed from PyPI with pip, which has shipped with Python since 2.7.9 and 3.4 or can be installed using the instructions on https://pip.pypa.io/en/stable/installing.html.

To install with pip you must have the same C compiler used to compile Python installed as well as the development headers for Python (typically called python-dev or python-devel on Linux).

You may then install Mercurial simply by executing pip install Mercurial.

4. Using conda

Conda is a cross-platform package manager with a focus on Python. You can install mercurial into a python2.7 conda environment with the following invocation:

conda install -c conda-forge mercurial

This should work on OSX, Windows, and Linux. If you would like to update the conda package, see the instructions at https://github.com/conda-forge/mercurial-feedstock

5. Using easy_install

/!\ easy_install is a legacy installation method which has been superseded by pip which should be preferred over easy_install. This method should not be used and is not recommended and will most likely cause conflict with other installs of Mercurial.

Mercurial can also be installed from pypi with easy_install. You will need Python and the C compiler used to build it and easy_install. easy_install might be available in a python-dev or python-setuptools-devel package for your platform or you can grab it from http://peak.telecommunity.com/DevCenter/EasyInstall.

/!\ Unable to find vcvarsall.bat fix error with mingw and install mercurial 1.7.3 with python 2.7

Create a file in C:\Python26\Lib\distutils and call it distutils.cfg
[build]
compiler=mingw32

With the right prerequisites you can install the latest version of Mercurial using:

easy_install -U mercurial

Source repository

You can get Mercurial using Mercurial:

https://www.mercurial-scm.org/repo/hg/ my-mercurial-clone
cd my-mercurial-clone
hg up "max(tagged())"
make install


CategoryProject

Francais, 中文, 日本語

Download (last edited 2021-10-01 20:25:20 by CarlReinke)