function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
jr0cket-salesforcejr0cket-salesforce 

Completing the Git Challenge - a simple guide to Git

To participate in the final pitch for the summer of hacks, you need to register your team on challenge post

http://sohlondon.challengepost.com/

You also need to email your github accout name (or all your teams Github account names) to summerofhacks@bemyapp.com.  If you do not have a Github account, you can create one for free at https://github.com/

Installing Git

You can install Git from http://git-scm.com/ or if you prefer a GUI tool you can use Github for windows (https://windows.github.com/) / mac (https://mac.github.com/) or you can use MavensMate.com or Force.com IDE.


Getting your app data out of your Salesforce org (metadata)

As part of the challenge you need to regularly submit your code and all the metadata (metadata is generated when you click to create objects and other things in the Org).

To get your metadata, you can download it with tools like MavensMate.com or the Force.com IDE.  If you are not using either of those you can the Force.com CLI (command line interface).  For details of getting your metadata with the Force.com CLI, follow this detailed guide (http://www.scribd.com/doc/233908496/Force-com-CLI-Submitting-Metadata).

Completing the Git Challege

Once you have the metadata and code in the same folder then you are ready for your git challenge.  First of all, add the private repository given to you by BeMyApp and pull down the contents of that repository (if using a GUI tool you do the same actions below, these are the command line actions).
 
git clone <address given to you by bemyapp> path/to/your/metadata-and-code>
git pull origin master

Now you are ready to add all your App code and metadata.  The easiest way is to use the fullstop to say add everything

git add .

You can check you have added everything using the git status command.  If there are untracked files, then add those files using their filename

Now create a commit of everything you have added

git commit -m "git challenge X"

Then you send all the code & metadata in that commit to the repository that BeMyApp gave to you.

git push origin master

Now get on with bulding your app.

For the next git challenge it is even easier

git add .
git commit -m "
git challenge X"
git push origin master


If you have any questions then ask the evangelist - John & Christophe.  There is also a more detailed Git workshop at http://jr0cket.co.uk/git-workshop/

Thank you