01. Principles & Practices, Project Management

Jump to Assignment: 01 | 02 | 03

The first week we learned how to use the GetSimple CMS for use as our personal profile and documentation. A quick tutorial on html followed. Next we installed the Cygwin Terminal for use with mercurial version control.

Useful Commands
Several useful and frequently used commands are listed below:

  • pwd - lets you know where you are (if you get lost!).
  • ~/ - go back to directory. 'ls' - List the files in the current directory.
  • ls -a - List files including the hidden files (hidden files start with a "." such as .ssh)
  • ls -l - Long list all the files in the curent directory, show permissions and the file size.
  • cd .. - go back one directory.
  • hg rm - remove files.
  • hg rm-A -

Push & Pull Commands
The push and pull commands will be the most used commands as we update our sites and its contents. The most usefull and inportant commands are listed below.

  • hg add - once in a directory you will run the command "hg add" to add files. Press enter and files will be added to the desired directory.
  • hg status - after adding something to a directory, you can check its status. You will notice that Mercurial will aad a ? before a new file (meaning that it found something it hasn't seen before) or a ! before the file (meaning it is missing that file - meaning that it was recently removed).
  • hg commit -m "describe what you are doing" - this will be written any time you wish to commit to a command. example here is hg commit -m "adding files".
  • hg pull - mercurial pulls files from archive and shows chages (at the end will ask you something. "hg update" or "hg heads" or "hg merge" etc. Always do what Mercurial asks you to do!)
  • hg heads - type in hg heads and we can see the most recent change made and who it was chaged by.
  • hg merge -m # - when merging you need to type in the latest number shown, which is the latest  changeset number available. after this we run commit command again hg commit -m "merging"
  • hg push - pushes the changes to the archive. (Always read when pushing! Never force push!)
  • hg update - updates file list (if files are shown then you can pull again to receive them).

More commands listed @ Basic UNIX Commands.

Mercurial Homework Assignment 1

This weeks homework assignmnet was to create a text file using mercurial, add text to it, save it and push to the archive. The image below shows the progress of the full session.

 

Published on   February 18th, 2013