You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by Apache Wiki <wi...@apache.org> on 2016/02/08 00:21:49 UTC

[Solr Wiki] Trivial Update of "Git commit process" by ErickErickson

Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Solr Wiki" for change notification.

The "Git commit process" page has been changed by ErickErickson:
https://wiki.apache.org/solr/Git%20commit%20process?action=diff&rev1=2&rev2=3

Comment:
Updating as I'm actually running through a small commit

  === method 1 ===
  update your repo (perhaps with .gitconfig making this use rebasing)
   * git checkout origin/master
+  * Make changes, get through {{{ant precommit}}} and {{{ant test}}} targets
+  * git add
+  * git commit -m "SOLR-#### additional comments, often the title of the JIRA" (commits locally, nothing in ASF yet)
   * git pull
-  * Make changes
-  * git add (for any new files)
-  * git commit -m "SOLR-#### additional comments" (commits locally, nothing in ASF yet)
   * git push
+ 
+ Notes:
+  * at any time {{{git status}}} tells you whether you have anything local that isn't in sync with the branch you're on. This includes changes not committed locally, new files not added to the local repo, changes committed locally but not pushed to the Apache repo.
+  * If you omit the {{{-m}}} flag you'll find yourself in a vi-like editor where you can enter long commit messages.
  
  === method 2 ===
  
@@ -58, +62 @@

  The usual recommendation is to "cherry pick".
   * git checkout branch-5x
   * git cherry-pick hash (You should have seen the hash echoed when you committed to origin/master, if not and you included the SOLR-####, the JIRA will have it)
+  * Check patch, perhaps run  {{{ant precommit}}} and {{{ant test}}} targets again
   * git commit (note this _may_ already preserve the comments from the hash you're cherry-picking from)
   * git push
  
@@ -74, +79 @@

   * [[https://github.com/dweiss/lucene-git-guides/blob/master/04-working-directly-on-a-remote-tracking-branch.sh|Dawid's Git Page]] Lots of options here, a fine way to get more sophisticated in your use of Git.
  
  == IntelliJ notes ==
-  * At least one problem with IntelliJ (Community edition, version 15) is that it seems to get confused if you have both the SVN and Git plugins active at once. My (Erick Erickson) issues cleared up when I disabled the svn plugin. 
+  * At least one problem with IntelliJ (Community edition, version 15) is that it seems to get confused if you have both the SVN and Git plugins active at once. My (Erick Erickson) issues cleared up when I disabled the svn plugin.