For this week assignment we have two important tasks:
Installing Mercurial which is a free distributed source control management tool. It handles projects of any size and offers an easy and intuitive interface.
Build a personal site in the class archive describing you and your final project
We are going to use mercurial for managing and storing our documents and for tracking our progress also.
The Mercurial program is named hg. Every Mercurial command starts with hg, followed by the command name, and by any relevant options and arguments.
The following links are very useful at the beginnig for understanding the fundamentals of the system
Understanding Mercurial - the concepts behind Mercurial.
Tutorial - a more exhaustive tutorial.
And then for troubleshooting:
Mercurial: The Definitive Guide - a very detailed description of Mercurial including behind the scenes, an indepth article on the design of Mercurial.
For the installation we used the tutorial, by Toshiro Tabushi from FabLab Lima. This is a very easy to follow step by step guide. The main steps are:
Cygwin installation. Cygwin is a collection of tools which provide a Linux look and feel environment for Windows.
Mercurial Installation
SSH Installation and configuration. Secure Shell (SSH) is a network protocol for secure data communication, command execution and other secure network services between two networked computers.
Cloning the Repository with mercurial. The Repository is a data structure, usually stored in a server, that contains a set of files and directories, historical records of changes and a set of references to commit objects, called heads.
Upload to the Academy web.
The following pictures shows: the first one, the commands for repository clonning (at left) and how is the structure in a windows view.
The second shows the edition of the hgrc file or mercurial configuration file and also a view of te edited file with wordpad at left.
To start and clone |
Daily use |
Maintenance |
hg init (start archive) | hg pull (pull from archive) | hg log (history) |
hg clone (copy archive) | hg update (update file system, alias up) | hg remove (remove versioned file alias rm) |
hg clone -e "ssh_path -i ~/.ssh/key_name" ssh://hg@fab.cba.mit.edu/archive_name local_archive_name | hg add (add files) | hg remove --after (remove deleted files from versioning) |
hg merge (merge diverged versions) |
hg status (repository status, alias st) | |
hg commit -m "message" (alias ci) | hg rollback (roll back the last transaction) |
|
hg push (push to archive) | hg help (with no arguments print a list of commands) |
The hg log command gives us a view of the history of changes in the repository.
As we can see in the figure at left, the archive was created by Neil on Sun Jan 22 and one day after Alex and Anna made transactions on it. If you want to know what happened and when in the archive, you can retreive it. |
This assignment is the cornerstone for success in our work