How To Clone An Older GIT Commit

A git repository contains the all history at all time. So when you are cloning a repository, you are cloning it with its full history, and then, you can make a branch from whatever commit you want:


git checkout -b aNewBranch SHA1

Example:

Derek@DELL8400 ~/workspace3/EDT-Tweaks2 (sensation)
$ git checkout -b Aug29 180a318445b04c1912e29fcbfc547849fe2dc5c5
Switched to a new branch ‘Aug29’

How To Resolve Invalid Project Description Error in Eclipse Working on Android Project

Frequently when I import projects from GIT via EGIT in Eclipse I  get the error “Invalid Project Description”  This bugged the hell out of me.

There are two kinds of places where projects can be located:

1) In the “default” location. This means that the project directory is a direct child directory of the workspace directory (aka the platform instance location), and the project directory name matches the project name.

2) Outside the default location, in a directory that is neither a parent or child of the platform instance location. In this case the directory name does not need to match the project name.

To ensure a successful import you have to make sure the directory you are creating inside of your \workspace\ dir matches that of the name defined in the .project file.

In my example: \workspace3\warmupdater is the same name that is defined in the .project file.  This will yield a successful import without the error “Invalid Project Description”

<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>warmupdater</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>com.android.ide.eclipse.adt.ResourceManagerBuilder</name>
<arguments>
</arguments>
</buildCommand>
...
..

Source

How to Set Up SmartGit With GitHub

  1. Create a Github.com account
  2. Download GIT For Windows (msysgit) –>  http://code.google.com/p/msysgit/
  3. Install msysgit choosing the following options:  Use git bash only [default].   Checkout Style:   Choose:  “check out as is commit as is”
  4. Launch GIT GUI
  5. In GIT GUI click menuitem:  Help | Show SSH Key | Click Generate Key and enter a passphrase
  6. Confirm new RSA keys were created in C:\Users\YourUserName\.ssh
  7. Open C:\Users\YourUserName\.ssh\id_rsa.pub with Notepad++ and copy to clipboard.
  8. Login to Github and navigate to your Account Settings | SSH public keys and Create a new key. Paste the contents of  your RSA public key you just copied.  Name it anything you want
  9. Download and Install SmartGIT –> http://www.syntevo.com/smartgit/index.html
  10. Launch SmartGIT.  It should automatically find your rsa keys.
  11. Clone a project Project | Clone | Remote URL:  git@github.com:myn/warm-z-twopointtwo-base.git  (or any other githum repo)
  12. If it asks for a password, use your github.com password.