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

[PATCH v2 0/2] Teach read-tree the -n|--dry-run option

From
Jens Lehmann <jens.lehmann@web.de>
Date
May 25, 2011, 20:06 UTC
Message-ID
<4DDD615E.7020809@web.de>
In-Reply-To
<7v39k37kmo.fsf@alter.siamese.dyndns.org>
Am 25.05.2011 01:18, schrieb Junio C Hamano:
Show 10 quoted lines
> Jens Lehmann <Jens.Lehmann@web.de> writes:
>> My "Teach read-tree the -n|--dry-run option" adapted to this new flag
>> runs all tests successfully ...
>>
>>
>>  unpack-trees.c |    4 ++--
>>  unpack-trees.h |    3 ++-
>>  2 files changed, 4 insertions(+), 3 deletions(-)
> 
> But on which change does this come?

As a preparing step for "read-tree the -n|--dry-run" (and adding a dry-run option to other users of unpack_trees() should be pretty straightforward now too).

The first patch in this series enables unpack_trees() to do a dry-run. That enables users of unpack_trees() to see if running this function with the update flag set would succeed.

The second patch uses this new dry_run flag to teach read-tree the -n|--dry-run option.

Jens Lehmann (2):
  unpack-trees: add the dry_run flag to unpack_trees_options
  Teach read-tree the -n|--dry-run option
 Documentation/git-read-tree.txt      |    5 ++
 builtin/read-tree.c                  |    3 +-
 t/lib-read-tree.sh                   |   43 ++++++++++++++++++
 t/t1000-read-tree-m-3way.sh          |   81 +++++++++++++++++-----------------
 t/t1001-read-tree-m-2way.sh          |   45 ++++++++++---------
 t/t1002-read-tree-m-u-2way.sh        |   81 +++++++++++++++++-----------------
 t/t1004-read-tree-m-u-wf.sh          |   23 +++++-----
 t/t1005-read-tree-reset.sh           |   13 +++---
 t/t1008-read-tree-overlay.sh         |    3 +-
 t/t1011-read-tree-sparse-checkout.sh |   27 ++++++-----
 t/t1012-read-tree-df.sh              |    9 ++--
 t/t1020-subdirectory.sh              |    5 +-
 unpack-trees.c                       |    4 +-
 unpack-trees.h                       |    3 +-
 14 files changed, 202 insertions(+), 143 deletions(-)
 create mode 100644 t/lib-read-tree.sh
-- 
1.7.5.2.355.gdceb0
Previous: Junio C HamanoNext: Jens Lehmann
Message 3 of 7 in “unpack-trees: add the dry_run flag to unpack_trees_options”
  1. unpack-trees: add the dry_run flag to unpack_trees_optionsJens Lehmann, May 24, 2011
  2. Junio C HamanoMay 24, 2011
  3. 0/2 Teach read-tree the -n|--dry-run optionJens Lehmann, May 25, 2011
  4. 1/2 unpack-trees: add the dry_run flag to unpack_trees_optionsJens Lehmann, May 25, 2011
  5. Junio C HamanoMay 25, 2011
  6. 2/2 Teach read-tree the -n|--dry-run optionJens Lehmann, May 25, 2011
  7. Junio C HamanoMay 25, 2011

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.