git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: --squash has no effect in git subtree push?

From
Danny Lin <danny0838@gmail.com>
Date
May 7, 2015, 07:52 UTC
Message-ID
<CAMbsUu4v9w6+wiAUm2hpiNrDaoL3U9Z_suXR3NPVGo-JhH3E+Q@mail.gmail.com>
In-Reply-To
<CAMbsUu5g=r867_WOhLCySG3caKj1jhmQgfzBxK4TYV27+nUpsg@mail.gmail.com>
Subject: [PATCH] contrib/subtree: there's no push --squash

The documentation says that --squash is for 'add', 'merge', 'pull' and 'push', while --squash actually doesn't change the behavior of 'push'. Correct the documentation.

Signed-off-by: Danny Lin <danny0838@gmail.com>
---
 contrib/subtree/git-subtree.sh  | 2 +-
 contrib/subtree/git-subtree.txt | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/contrib/subtree/git-subtree.sh b/contrib/subtree/git-subtree.sh
index fa1a583..6328c87 100755
--- a/contrib/subtree/git-subtree.sh
+++ b/contrib/subtree/git-subtree.sh
@@ -26,7 +26,7 @@ b,branch=     create a new branch from the split subtree
 ignore-joins  ignore prior --rejoin commits
 onto=         try connecting new tree to an existing one
 rejoin        merge the new branch back into HEAD
- options for 'add', 'merge', 'pull' and 'push'
+ options for 'add', 'merge', and 'pull'
 squash        merge subtree changes as a single commit
 "
 eval "$(echo "$OPTS_SPEC" | git rev-parse --parseopt -- "$@" || echo exit $?)"
diff --git a/contrib/subtree/git-subtree.txt b/contrib/subtree/git-subtree.txt
index 54e4b4a..60d76cd 100644
--- a/contrib/subtree/git-subtree.txt
+++ b/contrib/subtree/git-subtree.txt
@@ -146,7 +146,7 @@ OPTIONS
 OPTIONS FOR add, merge, push, pull
 ----------------------------------
 --squash::
-    This option is only valid for add, merge, push and pull
+    This option is only valid for add, merge, and pull
     commands.
 +
 Instead of merging the entire history from the subtree project, produce
-- 
2.3.7.windows.1
Previous: Danny LinNext: Junio C Hamano
Message 2 of 3 in “--squash has no effect in git subtree push?”
  1. Danny LinMay 4, 2015
  2. Danny LinMay 7, 2015
  3. Junio C HamanoMay 7, 2015

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.