Changes between Initial Version and Version 1 of GitCookbook-Pm

Show
Ignore:
Timestamp:
09/09/09 01:35:35 (10 years ago)
Author:
pmichaud
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • GitCookbook-Pm

    v1 v1  
     1FWIW, here are the basic commands I use for working with the Rakudo git repository on a regular basis.  This is based on a very svn-centric view of working with a repository; git allows other management models, but this one seems to work well for Rakudo.  Note that I have a commitbit to the Rakudo master repository -- see below for the workflow for non-commitbit users. 
     2 
     3 
     41.  To checkout a copy of the master repository:    
     5    {{{ 
     6    git clone git@github.com:rakudo/rakudo.git}}} 
     7    }}} 
     8 
     92.  To modify files in my local copy of the repository 
     10    {{{ 
     11    cd rakudo 
     12    vi src/foo.txt 
     13    }}} 
     14 
     153.  To commit those modified files to my local copy of the repository, any of 
     16    {{{ 
     17    git commit src/foo.txt     # just one file 
     18    git commit src             # all modified files in src/ 
     19    git commit .               # all modified files in current dir and below 
     20    }}} 
     21 
     224.  To add and commit a file to the local repo 
     23    {{{ 
     24    git add src/bar.txt 
     25    git commit src/bar.txt 
     26    }}} 
     27 
     285.  To grab any other updates from the master repository 
     29    {{{ 
     30    git pull 
     31    }}} 
     32 
     336.  To push the changes in my local repository back to the master repository 
     34    {{{ 
     35    git push 
     36    }}} 
     37 
     38That covers 90% of my usage of git for the Rakudo repository.  If I didn't have a commitbit to the master repository, a simple mechanism for creating a patch that can be submitted to RT is: 
     39 
     401.  Get a copy of the master repository 
     41    {{{ 
     42    git clone git://github.com/rakudo/rakudo.git    # note this is different for non-committers 
     43    }}} 
     44 
     452.  Modify files in my local repository 
     46    {{{ 
     47    vi src/foo.txt 
     48    }}} 
     49 
     503.  Format the patch for RT: 
     51    {{{ 
     52    git diff >mypatch.diff 
     53    # send mail to rakudobug@perl.org with mypatch.diff as an attachment 
     54    }}} 
     55