hg clone を debianで使いたい

apt-get install hg ……じゃないらしい、という訳で検索。

結論:
$sudo apt-get install mercurial

以下、調べた過程

そもそもhgって何?

http://sourceforge.jp/hg/

MercurialはPythonで実装されたクロスプラットフォームのソースコード管理システムです。

(中略)

バージョン管理というのは、指定した任意の時点における指定したファイルやディレクトリの内容を「リポジトリ」と呼ばれるデータベースに記録しておくことで、変更の内容をあとから容易に参照できるようにすることです。

恥ずかしながら、リンク先の全文を読んだ時は、なるほど、わからn・・・とかなりかけたのですが、いや、まぁちゃんと読めば一応わかった……と、思います。勉強になります。そういえば、そもそも「リポジトリ」が正確には何なのかも恥ずかしながら理解していなかったもので。

既存のMercurialリポジトリをコピーしてローカルリポジトリを作成する場合は「hg clone」コマンドを実行します。

$ hg clone <リポジトリのURL>

なるほどです。
とりあえずcloneが使いたい。

インストールはどうやるのか。

http://troter.jp/how-to-install-mercurial/

Debian/Ubuntu

apt-getでインストールする事が出来ます。

% apt-get install mercurial

なるほどです。

$sudo apt-get install mercurial と入れてみる。

Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
mercurial-common
Suggested packages:
qct wish kdiff3 kdiff3-qt kompare meld xxdiff tkcvs mgdiff python-mysqldb
python-pygments python-openssl
The following NEW packages will be installed:
mercurial mercurial-common
0 upgraded, 2 newly installed, 0 to remove and 151 not upgraded.
Need to get 2,413 kB of archives.
After this operation, 8,067 kB of additional disk space will be used.
Do you want to continue [Y/n]? y
Get:1 http://ftp.jp.debian.org/debian/ wheezy/main mercurial-common all 2.2.2-3 [2,320 kB]
Get:2 http://ftp.jp.debian.org/debian/ wheezy/main mercurial amd64 2.2.2-3 [93.1 kB]
Fetched 2,413 kB in 1s (1,440 kB/s)
Selecting previously unselected package mercurial-common.
(Reading database ... 164444 files and directories currently installed.)
Unpacking mercurial-common (from .../mercurial-common_2.2.2-3_all.deb) ...
Selecting previously unselected package mercurial.
Unpacking mercurial (from .../mercurial_2.2.2-3_amd64.deb) ...
Processing triggers for man-db ...
Setting up mercurial-common (2.2.2-3) ...
Setting up mercurial (2.2.2-3) ...

$ hg
Mercurial Distributed SCM

basic commands:

add add the specified files on the next commit

(中略)

update update working directory (or switch revisions)

use "hg help" for the full list of commands or "hg -v" for details

出来ました。