Step 1. Installing Mercurial
Download the suitable version of Mercurial from http://mercurial.berkwood.com/ (for Mac OS X 10.4 download Mercurial 1.2.1). After installing type ‘hg’ in the Terminal to check if Mercurial was installed successfully. If Terminal says ‘Command not found’ then add the path to Mercurial installation (/usr/local/bin) to your ~/.profile file:
To check if directory is in your PATH now type the following in the Terminal:
The directory in question should appear in the list
$ echo $PATH /opt/local/bin:/opt/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin
Step 2. Configuring Mercurial
Before making commits it’s required to setup the username of Mercurial user. To do this open ~/.hgrc file for editing. If the file is not visible in Finder do the following in terminal to make hidden files visible or alternatively just edit the file in terminal:
To make hidden files visible in Finder:
defaults write com.apple.finder AppleShowAllFiles TRUE killall Finder
Then add username to the [ui] section of .hgrc file:
[ui] username = dashas
Step 3. Setting up an initial repository
Go to your webroot folder (~/sites) and make sure it doesn’t already contain the folder with the same name of the repository you want to create (MediaAlbumWeb).
To set up a local repository you have to clone it from the existing one. If you don’t have such a repository available for cloning then you will have to create one.
If there is a latest Mercurial repository available to clone then go to the step 7.
Then in the Terminal do the following:
$ cd ~/sites/ $ hg init MediaAlbumWebServer
Using Finder copy files you want to store in the repository to the newly created MediaAlbumWebServer repository and run the following command in terminal:
$ cd MediaAlbumWebServer $ hg add
Then make a commit to the repository:
$ hg commit -m 'Initial commit'
Step 4. Installing Eclipse
Download and install Eclipse from http://eclipse.org/downloads/ or find it on Taopix DataShare/Eclipse.
For Mac OS X 10.4 download Mac Carbon version.
Step 5. Installing Mercurial plugin for Eclipse
First install Mac GnuPGP. Download the files http://sourceforge.net/projects/macgpg2/files/ or take it from Taopix DataShare/Eclipse folder.
Install the package from http://hge.javaforge.com/hgeclipse using Eclipse Help->Install New Software option.
For Mac OS X 10.4 install Mercurial Eclipse plugin instead from http://www.vectrace.com/eclipse-update/.
Select HgEclipse -> HgEclipse (uncheck Mercurial executable for Windows).
Step 6. Configure Eclipse plugin for Mercurial
Go to Eclipse Preferences -> Team -> Mercurial and specify the paths to hg and gpg2 files on your local machine.
Step 7. Setting up a local repository
To create a local repository open Eclipse and go to menu File -> Import -> Mercurial -> Clone repository using Mercurial and click Next button. Select the location of the repository to clone and enter your authentication details if applicable. In the clone destination enter the path where you want your local repository (MediaAlbumWeb) folder to be created. And then click Finish.
Then when you see the list of folders in your repository, mark what files and folders you would want to exclude from repository. For example, right click on ‘parsed’, ‘templates_c’ folders and config/mediaalbumweb.conf file and mark them as ignored.
Step 8. Installing Fogbugz plugin
Install the plugin (Help -> Install New Software menu) from http://eclipsebugz.sourceforge.net.
In order to work Fogbugz plugin needs a Fogbugz RSS feed. To get one go to Fogbugz Filters -> Manage saved filters saved filters and click on RSS icon. If you don’t have any saved filters create one and you will see an icon.
As an example, feed:https://taopixdasha.fogbugz.com/default.asp?pg=pgRss&ixPerson=2&ixFilter=1