{"thread":{"id":"29241","subject":"[PATCH] fix shell command line in example","startedAt":"2011-12-23T16:41:29Z","lastAt":"2011-12-23T17:33:15Z","messageCount":3,"participants":["Joey Hess","Thomas Rast"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"181643","messageId":"20111223164128.GA21918@gnu.kitenet.net","threadId":"29241","inReplyTo":null,"subject":"[PATCH] fix shell command line in example","fromName":"Joey Hess","fromEmail":"joey@kitenet.net","sentAt":"2011-12-23T16:41:29Z","receivedAt":"2011-12-23T16:41:29Z","isPatch":true,"sender":{"key":"joey@kitenet.net","avatar":"https://avatars.githubusercontent.com/u/16392?v=4"},"body":"The comma was probably intended to be a semicolon so that the\ntwo commands can be run by cut-n-paste.\n\nSigned-off-by: Joey Hess <joey@kitenet.net>\n---\n Documentation/git-pull.txt |    2 +-\n 1 files changed, 1 insertions(+), 1 deletions(-)\n\ndiff --git a/Documentation/git-pull.txt b/Documentation/git-pull.txt\nindex 0f18ec8..628695d 100644\n--- a/Documentation/git-pull.txt\n+++ b/Documentation/git-pull.txt\n@@ -194,7 +194,7 @@ EXAMPLES\n   current branch:\n +\n ------------------------------------------------\n-$ git pull, git pull origin\n+$ git pull; git pull origin\n ------------------------------------------------\n +\n Normally the branch merged in is the HEAD of the remote repository,\n-- \n1.7.7.3\n"},{"id":"181644","messageId":"8739cbi5v3.fsf@thomas.inf.ethz.ch","threadId":"29241","inReplyTo":"20111223164128.GA21918@gnu.kitenet.net","subject":"Re: [PATCH] fix shell command line in example","fromName":"Thomas Rast","fromEmail":"trast@student.ethz.ch","sentAt":"2011-12-23T16:56:48Z","receivedAt":"2011-12-23T16:56:48Z","isPatch":true,"sender":{"key":"tr@thomasrast.ch","avatar":"https://avatars.githubusercontent.com/u/153510?v=4"},"body":"Joey Hess <joey@kitenet.net> writes:\n\n> The comma was probably intended to be a semicolon so that the\n> two commands can be run by cut-n-paste.\n[...]\n>  ------------------------------------------------\n> -$ git pull, git pull origin\n> +$ git pull; git pull origin\n>  ------------------------------------------------\n\nWould it ever make sense to run the two in sequence?\n\nBut upon closer reading, it seems to be a pretty terrible example\nanyway.  It reads:\n\n  * Update the remote-tracking branches for the repository\n    you cloned from, then merge one of them into your\n    current branch:\n  +\n  ------------------------------------------------\n  $ git pull, git pull origin\n  ------------------------------------------------\n  +\n  Normally the branch merged in is the HEAD of the remote repository,\n  but the choice is determined by the branch.<name>.remote and\n  branch.<name>.merge options; see linkgit:git-config[1] for details.\n\nBut that \"normally\" is no longer true: with default configs, the user\nwould only ever have branches with tracking already set up.  So\n*normally*, 'git pull' will merge the @{upstream}.\n\n'git pull origin' is even worse: with tracking configured, it goes out\nof its way to verify that the specified remote (origin) is actually what\nHEAD tracks[*].  So 'git pull origin' with default configs means \"please\npull, but double-check me on the choice of remote\".  Do we want to give\nthat to a user as the second example?\n\nSo I'm thinking it should just read\n\n  * Update the upstream origin of the current branch, then merge the\n    tracked branch into the current one:\n  +\n  --------------------------------------------------\n  $ git pull\n  --------------------------------------------------\n\nmodulo avoiding confusion around upstream/tracking.\n\n\n[*] a8c9bef (pull: improve advice for unconfigured error case,\n2009-10-05) has a long explanation on the subject.\n\n-- \nThomas Rast\ntrast@{inf,student}.ethz.ch\n"},{"id":"181646","messageId":"20111223173315.GB23049@gnu.kitenet.net","threadId":"29241","inReplyTo":"8739cbi5v3.fsf@thomas.inf.ethz.ch","subject":"Re: [PATCH] fix shell command line in example","fromName":"Joey Hess","fromEmail":"joey@kitenet.net","sentAt":"2011-12-23T17:33:15Z","receivedAt":"2011-12-23T17:33:15Z","isPatch":true,"sender":{"key":"joey@kitenet.net","avatar":"https://avatars.githubusercontent.com/u/16392?v=4"},"body":"Thomas Rast wrote:\n>   * Update the upstream origin of the current branch, then merge the\n>     tracked branch into the current one:\n>   +\n>   --------------------------------------------------\n>   $ git pull\n>   --------------------------------------------------\n> \n> modulo avoiding confusion around upstream/tracking.\n\nI support having a simple \"git pull\" example; I think it's the first\nthing users should be reaching for, followed perhaps by \"git pull foo bar\"\nwhen they have multiple remotes. \n\nStill, an example of pulling all tracking branches from a remote and\nmerging in the right one for the currently checked out branch would be\ngood to have, that's also a common need when using git without a\ncentralized origin. AFAICS, there's no way to do all that in a single\ngit pull command? My feeling was that this sort of scenario was what\nthe example was trying to do (rather badly).\n\n-- \nsee shy jo\n"}]}