Git Tutorial addendum

  • warning: preg_match(): Compilation failed: unknown option bit(s) set at offset 0 in /var/www/lscube.org/htdocs/drupal/includes/bootstrap.inc on line 896.
  • warning: preg_match(): Compilation failed: unknown option bit(s) set at offset 0 in /var/www/lscube.org/htdocs/drupal/includes/unicode.inc on line 47.
  • warning: preg_match(): Compilation failed: unknown option bit(s) set at offset 0 in /var/www/lscube.org/htdocs/drupal/includes/bootstrap.inc on line 896.
  • warning: preg_match(): Compilation failed: unknown option bit(s) set at offset 0 in /var/www/lscube.org/htdocs/drupal/includes/bootstrap.inc on line 896.
  • warning: preg_match(): Compilation failed: unknown option bit(s) set at offset 0 in /var/www/lscube.org/htdocs/drupal/includes/bootstrap.inc on line 896.
  • warning: preg_match(): Compilation failed: unknown option bit(s) set at offset 0 in /var/www/lscube.org/htdocs/drupal/includes/bootstrap.inc on line 896.

Here a list of useful snippets, some are taken from sourcemage wiki as integration to the git tutorial, another useful guide is in the wine wiki

Adding a remote branch

$ git clone git://live.polito.it/var/git/libnemesi
$ cd libnemesi
$ git branch sekrit
$ git checkout sekrit
#[hack... git commit hack ...]
#now publish it!
$ git push origin sekrit

Removing a remote branch

$ git push origin :sekrit

Tracking a remote branch

$ git checkout --track -b local_name origin/remote_name