git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [RFC PATCH 00/12] Sparse checkout
@ 2008-07-23 14:55 Nguyễn Thái Ngọc Duy
  2008-07-23 15:38 ` Nguyen Thai Ngoc Duy
                   ` (3 more replies)
  0 siblings, 4 replies; 27+ messages in thread
From: Nguyễn Thái Ngọc Duy @ 2008-07-23 14:55 UTC (permalink / raw)
  To: git

I have not looked at non-builtin commands yet, but I think it's not
a big deal. We have several rounds before this series is good enough ;)
So in short, sparse prefix will be stored in config, core.sparsecheckout.
you have three new commands to enter/update/leave sparse checkout:

git clone --path=prefix       # clone with sparse checkout
git checkout --path=prefix    # limit/update checkout paths
git checkout --full           # stop sparse checkout

Other operations should be normal. User attempts to do anything outside
sparse checkout will get flagged. Git itself should not touch anything
outside sparse checkout.

One more thing. As files outside sparse checkout will not be checking
out, .gitignore and .gitattributes from parent directories (outside
sparse checkout) will be gone too. This may lead to surprise.

Comments are welcome.

Nguyễn Thái Ngọc Duy (12):
  git-grep: read config
  git-grep: support --no-external-grep
  Introduce sparse prefix
  Protect index with sparse prefix
  tests for sparse checkout, index protection
  Avoid accessing working directory outside sparse prefix
  tests for sparse checkout, worktree protection
  git-clone: support --path to do sparse clone
  tests for sparse clone
  git-checkout: support --full and --path to manipulate sparse checkout
  tests for checkout [--full|--path]
  git-status: print sparse checkout status

 builtin-add.c                              |    4 +-
 builtin-apply.c                            |    5 +
 builtin-checkout-index.c                   |    2 +
 builtin-checkout.c                         |   46 ++++++-
 builtin-clean.c                            |    3 +
 builtin-clone.c                            |   13 ++
 builtin-commit.c                           |   13 ++-
 builtin-grep.c                             |   36 +++--
 builtin-ls-files.c                         |    6 +-
 builtin-ls-tree.c                          |    2 +-
 builtin-merge-recursive.c                  |    6 +-
 builtin-mv.c                               |    2 +-
 builtin-read-tree.c                        |    5 +
 builtin-rev-parse.c                        |    4 +
 builtin-rm.c                               |    7 +-
 builtin-update-index.c                     |   37 ++++-
 cache.h                                    |   19 +++
 config.c                                   |    7 +
 diff-lib.c                                 |    5 +-
 diff.c                                     |    3 +-
 entry.c                                    |    3 +
 environment.c                              |  221 ++++++++++++++++++++++++++
 read-cache.c                               |  112 +++++++++++++-
 setup.c                                    |   90 +++++++++++-
 sha1_file.c                                |    3 +
 t/t2010-checkout-sparse.sh                 |   71 +++++++++
 t/t2300-sparse-index.sh                    |  156 +++++++++++++++++++
 t/t2300/diff-index-sub.expected            |    3 +
 t/t2300/log.expected                       |   64 ++++++++
 t/t2301-sparse-index-merge-recursive.sh    |  226 +++++++++++++++++++++++++++
 t/t2302-sparse-worktree.sh                 |  113 ++++++++++++++
 t/t2302/add-u.expected                     |    1 +
 t/t2302/add.expected                       |    2 +
 t/t2302/commit.expected                    |   14 ++
 t/t2302/diff-1.expected                    |    7 +
 t/t2302/diff-cc.expected                   |    9 +
 t/t2302/grep-work.expected                 |    2 +
 t/t2302/grep.expected                      |    2 +
 t/t2302/ls-files.expected                  |    2 +
 t/t2303-sparse-worktree-apply.sh           |   62 ++++++++
 t/t2303/apply-initial.patch                |   14 ++
 t/t2303/apply-inside.patch                 |    7 +
 t/t2303/apply-leading-dirs.patch           |    3 +
 t/t2303/apply-outside.patch                |    7 +
 t/t2303/apply-remove.patch                 |    7 +
 t/t2303/apply-rename.expected              |   13 ++
 t/t2303/apply-rename.patch                 |    4 +
 t/t2304-sparse-worktree-merge-recursive.sh |  233 ++++++++++++++++++++++++++++
 t/t5703-clone-sparse.sh                    |   40 +++++
 unpack-trees.c                             |  152 +++++++++++++++++--
 unpack-trees.h                             |    4 +-
 wt-status.c                                |   12 +-
 52 files changed, 1831 insertions(+), 53 deletions(-)
 create mode 100755 t/t2010-checkout-sparse.sh
 create mode 100755 t/t2300-sparse-index.sh
 create mode 100644 t/t2300/diff-index-sub.expected
 create mode 100644 t/t2300/log.expected
 create mode 100755 t/t2301-sparse-index-merge-recursive.sh
 create mode 100755 t/t2302-sparse-worktree.sh
 create mode 100644 t/t2302/add-u.expected
 create mode 100644 t/t2302/add.expected
 create mode 100644 t/t2302/commit.expected
 create mode 100644 t/t2302/diff-1.expected
 create mode 100644 t/t2302/diff-cc.expected
 create mode 100644 t/t2302/grep-work.expected
 create mode 100644 t/t2302/grep.expected
 create mode 100644 t/t2302/ls-files.expected
 create mode 100755 t/t2303-sparse-worktree-apply.sh
 create mode 100644 t/t2303/apply-initial.patch
 create mode 100644 t/t2303/apply-inside.patch
 create mode 100644 t/t2303/apply-leading-dirs.patch
 create mode 100644 t/t2303/apply-outside.patch
 create mode 100644 t/t2303/apply-remove.patch
 create mode 100644 t/t2303/apply-rename.expected
 create mode 100644 t/t2303/apply-rename.patch
 create mode 100755 t/t2304-sparse-worktree-merge-recursive.sh
 create mode 100755 t/t5703-clone-sparse.sh

^ permalink raw reply	[flat|nested] 27+ messages in thread

end of thread, other threads:[~2008-08-04 12:30 UTC | newest]

Thread overview: 27+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-07-23 14:55 [RFC PATCH 00/12] Sparse checkout Nguyễn Thái Ngọc Duy
2008-07-23 15:38 ` Nguyen Thai Ngoc Duy
2008-07-23 16:15 ` Johannes Schindelin
2008-07-23 16:21   ` Nguyen Thai Ngoc Duy
2008-07-23 16:55     ` Johannes Schindelin
2008-07-24  8:27       ` Nguyen Thai Ngoc Duy
2008-07-24 12:42         ` Johannes Schindelin
2008-07-24 13:29           ` Nguyen Thai Ngoc Duy
2008-07-24 13:44             ` Johannes Schindelin
2008-07-24 13:50               ` Nguyen Thai Ngoc Duy
2008-07-24 16:22                 ` Avery Pennarun
2008-07-24 16:38                   ` Johannes Schindelin
2008-07-24 18:59                   ` Nguyen Thai Ngoc Duy
2008-08-03 18:37       ` Jan Hudec
2008-08-03 20:48         ` Johannes Schindelin
2008-08-04 12:29         ` Nguyen Thai Ngoc Duy
2008-07-24  8:24 ` James Pickens
2008-07-24  9:00   ` Nguyen Thai Ngoc Duy
2008-07-24 17:59     ` James Pickens
2008-07-24 23:23       ` Nguyen Thai Ngoc Duy
2008-07-24 23:38         ` James Pickens
2008-07-24  9:35 ` Jakub Narebski
2008-07-24 10:58   ` Nguyen Thai Ngoc Duy
2008-07-24 20:01     ` Jakub Narebski
2008-07-24 23:21       ` Nguyen Thai Ngoc Duy
2008-07-25 14:53         ` Avery Pennarun
2008-07-25  0:07       ` Johannes Schindelin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).