On Thu, Apr 15, 2010 at 10:49 AM, Jonathan Nieder <jrnieder@xxxxxxxxx> wrote: > FWIW, my latest is at > > git://repo.or.cz/git/jrn nd/setup/chapter-one > > Changes since the last series I sent to the list: > > - test cleanups, after Junio’s feedback > - clarified commit messages, I hope > > If you’ve already started cleaning up or if something in the diff looks > iffy, feel free to carry on with what you have. I don’t want the test > changes to interfere with more productive work. > > Looking forward to watching this evolve, OK. Here is the topic breakdown into 11 sub-topics, after rebasing on setup/chapter-one. Patches 1, 2-3, 4-5, 8-9, 10-12, 13-18 can go as separate independent sub-topics, given that chapter-one is accepted. The rest must go in sequence because they will need some of previous groups. Commit messages aren't cleaned up yet, just the idea of grouping. Patches available at git://repo.or.cz/git/pclouds.git tp/setup 1 rev-parse --git-dir: print relative gitdir correctly This will become a problem when patches 37-43 (let's name it "unset_git_directory") is merged. Other than that, it's can go alone. 2 worktree setup: calculate prefix even if no worktree is found 3 index-pack: trust the prefix returned by setup_git_directory_gently() This is debatable, as you pointed out, because it changes "git rev-parse --show-prefix" behavior. This is a prerequisite for 19-36 (run-setup-gently) 4 Move enter_repo() to setup.c 5 enter_repo(): initialize other variables as setup_git_directory_gently() does Good thing. Quite simple. Prerequisite for 6-7 (have_run_setup) 6 builtin: remember whether repository has been searched for 7 builtins: setup repository before print unknown command error Introduce startup_info->have_run_setup_gitdir, and a guard in command error printing. 8 setup: save prefix (original cwd relative to toplevel) in startup_info 9 builtin: remove prefix variable from run_builtin() Introduce startup_info->prefix. Will be needed for 47-48 (alias fix) because setup_git_dir may be called in one place, and unset_git_dir is called in another place. 10 run_builtin(): save "-h" detection result for later use 11 builtins: utilize startup_info->help where possible 12 builtins: check for startup_info->help, print and exit early Fix "git cmd -h" shortcut. There will be warnings from git_config() once the old "guard unallowed access" patch is in. It will be fixed in patch 45. 13 init/clone: turn on startup->have_repository properly 14 t7002: test git grep --no-index from a bare repository 15 Do not read .git/info/exclude if there is no repository 16 Do not read .git/info/attributes if there is no repository 17 apply: do not check sha1 if there is no repository 18 config: do not read .git/config if there is no repository Assorted fixes wrt unconditional access to .git/. All these patches simple add "if (have_repository)" or so. 19 t0001: test git init when run via an alias 20 t5512: test that ls-remote does not require a git repository 21 t7006: expose test_terminal() for use by other tests 22 help: note why it is appropriate for this command not to use RUN_SETUP_GENTLY 23 hash-object: use RUN_SETUP_GENTLY 24 shortlog: use RUN_SETUP_GENTLY 25 grep: use RUN_SETUP_GENTLY 26 archive: use RUN_SETUP_GENTLY 27 mailinfo: use RUN_SETUP_GENTLY 28 check-ref-format: use RUN_SETUP_GENTLY 29 verify-pack: use RUN_SETUP_GENTLY 30 apply: use RUN_SETUP_GENTLY 31 bundle: use RUN_SETUP_GENTLY 32 diff: use RUN_SETUP_GENTLY 33 ls-remote: use RUN_SETUP_GENTLY 34 var: use RUN_SETUP_GENTLY 35 merge-file: use RUN_SETUP_GENTLY 36 index-pack: use RUN_SETUP_GENTLY The RUN_SETUP_GENTLY series. Of course these will need to be reviewed, some commands might need finer-grain setup. 37 Add git_config_early() 38 t1300: test that scripted commands do not respect stray .git/config 39 git_config(): do not read .git/config if there is no repository 40 Use git_config_early() instead of git_config() during repo setup 41 worktree setup: call set_git_dir explicitly 42 worktree setup: restore original state when things go wrong 43 Allow to undo setup_git_directory_gently() gracefully (and fix alias code) The unset_git_directory series. Make setup_git_directory() work right. 44 Guard unallowed access to repository when it's not set up 45 run_builtin: do now raise alarms 46 setup_work_tree: do not raise alarm Put unallowed access warnings in place. Also fixes false alarms. 47 alias: keep repository found while collecting aliases as long as possible 48 run_builtin: respect have_run_setup_gitdir Fix alias related setup problem. Insane? -- Duy -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html