DISQUS

Adam @ Heroku: http://adam.blog.heroku.com/past/2008/5/15/more_git_techniques/

  • Alissa · 1 year ago
    Completely besides the point I know, but.

    > Restore a file to repository version
    > svn: rm file; svn up file
    > git: rm file; git checkout file

    Wouldn't "svn revert file" be more efficient?


    > Grab one commit without any of the commits around it:
    > svn: svn diff -rN1:N2 > my.patch; scp my.patch other.server; ssh other.server "patch < my.patch"
    > git: git fetch; git cherry-pick [commit-hash]

    Am I missing something? Wouldn't "svn merge -rN1:N2" work?
  • adamheroku · 1 year ago
    @Alissa - You're totally messing up my attempt to strawman Subversion. :)
  • bartman · 1 year ago
    Restore a file to repository version

    git: git checkout -f file

    Set some changes aside to work on something else:

    svn: svn diff > /tmp/path ; svn revert -R .