[DUG] Anyone using GIT
Jolyon Smith
jsmith at deltics.co.nz
Tue Mar 31 10:32:39 NZDT 2015
The hump to get over is the distinction between a centralised repo (SVN) vs
distributed. i.e. the fact that your working copy IS the repo, the whole
repo. All the history. The whole enchillada.
A developer commits their work to their repository. ie. their working copy
is not just just their latest version of their work on the code, but ALL of
their revisions, so a developer can commit frequently and often to capture
incremental revisions. Then, when work is complete they would push those
changes out to other repositories that need to incorporate those changes.
Again, ALL the revisions are transmitted, not just the latest changes.
Obviously trying to keep track of numerous sync'ed clones of a repo could
be tricky, and you will ideally have a "master" repo that acts as a
centralising repo. In Git this would usually be achieved with a "bare"
repository.
A bare repository is the closest you get to a central/server repo in git.
A bare repo simply means that it is a repository that contains no working
code of it's own. If you navigate to that repo on disk you won't find any
source code or other repo contents in directly readable form (hence
"bare"). It is a repo that consists entirely of commit history.
.
To work with another repo you create a local clone. This initially
contains all of the history in tat repo up to the point you clone it along
with a reference back to the original repo as a "remote", allowing you to
push any changes back up (or pull further changes back down).
For collaborative projects where the entire team is not directly under the
repo owner's control, they will typically require that any changes you wish
to submit be co-ordinated via a pull request. That is, you fork their
repo, make your changes in a clone of that fork and then instead of
directly pushing your changes into the original repo you send a
pull-request which notifies the repo owner of the change. They are then
able to review your change in your fork and pull it into the repo only if
they are happy.
But this is just one workflow and with the flexibility offered by Git there
are numerous workflow options to evaluate, in addition to understanding the
core concepts they build on.
All of this I have picked up simply by reading the docs and experimenting.
:)
It isn't rocket science, As I said, it's getting your head around the
distributed approach that is key.
GitHub provides a useful playground to experiment with git. Set yourself
up a free account and start playing with some public repos (you only have
to pay to host private ones, or so it used to be). Be prepared to make
mistakes as you get to grips with the concepts. Don't set out to create a
"real" repo at first - it almost certainly won't fit your needs out of the
gate.
Incidentally, I highly recommend Tortoise Git.
On 30 March 2015 at 17:03, Sean Cross <Sean.Cross at catalystrisk.co.nz> wrote:
> We just started using it this month. I found
> http://www.diaryofaninja.com/blog/2014/08/20/so-you-want-your-team-to-start-using-git-ndash-part-1-getting-started
> to be very helpful. Syncfusion also do a " GIS Succinctly" ebook available
> for free from their website.
>
> Regards
>
> Sean
>
> -----Original Message-----
> From: delphi-bounces at listserver.123.net.nz [mailto:
> delphi-bounces at listserver.123.net.nz] On Behalf Of Rohit Gupta
> Sent: Monday, 30 March 2015 10:55 a.m.
> To: NZ Borland Developers Group - Delphi List
> Subject: [DUG] Anyone using GIT
>
> Has anyone been using GIT for a while ?
>
> I am looking for someone to give us a crash course on it. We will
> reimburse you for your time.
>
> Regards
>
> Rohit
>
> _______________________________________________
> NZ Borland Developers Group - Delphi mailing list
> Post: delphi at listserver.123.net.nz
> Admin: http://delphi.org.nz/mailman/listinfo/delphi
> Unsubscribe: send an email to delphi-request at listserver.123.net.nz with
> Subject: unsubscribe
>
> _______________________________________________
> NZ Borland Developers Group - Delphi mailing list
> Post: delphi at listserver.123.net.nz
> Admin: http://delphi.org.nz/mailman/listinfo/delphi
> Unsubscribe: send an email to delphi-request at listserver.123.net.nz with
> Subject: unsubscribe
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://listserver.123.net.nz/pipermail/delphi/attachments/20150331/664da534/attachment-0001.html
More information about the Delphi
mailing list