Changes between Version 5 and Version 6 of GitForDarcsUsers


Ignore:
Timestamp:
Aug 12, 2008 2:46:21 PM (7 years ago)
Author:
nominolo
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • GitForDarcsUsers

    v5 v6  
    2727git clone <repo-url> [<local-name>]
    2828}}}
     29Possible repo URLs look like this:
     30{{{
     31git clone http://darcs.haskell.org/ghc.git  # via HTTP (slowest)
     32git clone git://darcs.haskell.org/ghc.git   # git's protocol (fast, read-only)
     33git clone [username@]darcs.haskell.org:ghc.git  # via SSH
     34}}}
    2935
    3036== darcs add ==
     
    95101(the {{{=}}}-sign is important)
    96102
    97 === other ===
     103=== Other useful variants ===
    98104{{{
    99105git log -p
     
    101107Shows the patch for each commit.
    102108
     109{{{
     110git grep <text>
     111}}}
     112Look for something anywhere in the repository's history (tag names, commit messages, file contents).
     113
     114{{{
     115git show <commit-id>
     116}}}
     117Show the changes by the given patch
     118
     119More examples.
     120{{{
     121git log v2.5..v2.6            # commits between v2.5 and v2.6
     122git log v2.5..                # commits since v2.5
     123git log --since="2 weeks ago" # commits from the last 2 weeks
     124git log v2.5.. Makefile       # commits since v2.5 which modify
     125                              # Makefile
     126}}}
     127
    103128See {{{git log --help}}} for a lot of extra options, to refine the output.
    104129
     130== darcs tag ==
     131{{{
     132git tag <tagname>
     133}}}
     134This will fail if the tag already exists.  If you want to move an existing tag use {{{git tag -f <tagname>}}}, but '''never move a tag in a public repo/branch'''.  Use this only on local branches, and only if the tag exists nowhere else.  {{{git tag --help}}} contains a discussion of this.
     135
    105136== darcs whatsnew ==
    106137
     
    115146}}}
    116147
    117 TODO: describe diff commands for index
     148{{{
     149git diff <commit1>..<commit2>  # show diff between two commits
     150}}}
    118151
    119152== darcs revert ==
     
    127160== darcs unrecord ==
    128161
    129 ...
     162???
     163{{{
     164git reset --soft HEAD^
     165}}}
     166
     167== darcs amend-record ==
     168
     169If the change to be amended is the latest commit
     170{{{
     171git commit --amend
     172}}}
     173
     174TODO: describe workflow if amended patch is not the current HEAD.
     175
     176TODO: add note for merge commits
     177
     178== darcs rollback ==
     179
     180{{{
     181git revert <commit-id>
     182}}}
     183Working directory must be clean.  (You can use {{{git stash}}} to save local changes).
    130184
    131185== darcs annotate ==