threads / patch / 787

patchOne Git To Rule Them All

Subject: [PATCH] One Git To Rule Them All

## tl;dr

6 messages between Jun 1, 2005 and Jun 1, 2005. Diffs are folded; open one to read it.

replies: 5people: 3as markdown or json

Jason McMullan· Jun 1, 2005, 05:58 UTC · lore

The following three patches (two prep and one 'real') fold all the git-* commands into one 'git' command. This is useful for:

	* Setting up git on a new machine - just one file to send
	* Porcelain that customizes git (ie cogito) can have a
	  'cg-git' instead of trouncing on the default Plumbing git.
	* Quick-ref help on all the Plumbing commands for free!
	* git-<mumble> symlinks to git work as expected
	* Documentation is now enforced for building
          (bug? feature? you decide)

$ git help GIT Commands:

	local-pull              Duplicates another GIT repository on a local system
	http-pull               Downloads a remote GIT repository via HTTP
	rpull                   Pulls from a remote repository over ssh connection
	rpush                   Helper "server-side" program used by git-rpull
	rev-tree                Provides the revision tree for one or more commits
	rev-list                Lists commit objects in reverse chronological order
	export                  Exports each commit and a diff against each of its parents
	read-tree               Reads tree information into the directory cache
	checkout-cache          Copy files from the cache to the working directory
	update-cache            Modifies the index or directory cache
	ls-tree                 Lists the contents of a tree object.
	ls-files                Information about files in the cache/working directory
	cat-file                Provide content or type information for repository objects
	unpack-file             Creates a temporary file with a blob's contents
	diff-files              Compares files in the working tree and the cache
	diff-cache              Compares content and mode of blobs between the cache and repository
	diff-tree               Compares the content and mode of blobs found via two tree objects
	merge-base              Finds as good a common ancestor as possible for a merge
	merge-cache             Runs a merge for files needing merging
	apply                   Apply a patch against the current index cache/working directory
	check-files             Verify a list of files are up-to-date
	write-tree              Creates a tree from the current cache
	commit-tree             Creates a new commit object
	mktag                   Creates a tag object
	init-db                 Creates an empty git object database
	fsck-cache              Verifies the connectivity and validity of the objects in the database
	convert-cache           Converts old-style GIT repository
	mkdelta                 Creates a delta object
	tar-tree                Creates a tar archive of the files in the named tree
	get-tar-commit-id       Show the commit ID embedded in a git-tar-tree file.
	write-blob              Creates a blob from a file
	diff-helper             Generates patch format output for git-diff-*
	stripspace              Strip space from stdin
-- 
Jason McMullan, Embedded Systems Engineer
412.481.5021 tel, 412.656.3519 cell, 208.694.9206 fax
jason@evillabs.net
Junio C Hamano· Jun 1, 2005, 06:21 UTC · re: Jason McMullan · lore

Re: [PATCH] One Git To Rule Them All

In my opinion, this is going backwards.

I think we had this discussion long time ago on the list, and instead of using cvs/svn style of "cmd subcmd" syntax, the consensus back then was that using "cmd-" prefix without spaces is easier for making TAB completion to work (you do not have to muck with command specific rules in the readline configuration), and this is especially helpful for people who ends up using the bare Plumbing. IIUC, the same reason is behind cg-* command set.

Having said that, for many people who do not wish to use the bare Plumbing interactively, installing git-* commands in, say, $(libexec)/git/ might be a more appropriate option. But we have to remember there are people who uses the bare Plumbing interatively. I think Jeff Garzik said he does not use Cogito, and I suspect Linus does not either.

Sebastian Kuzminsky· Jun 1, 2005, 06:35 UTC · re: Junio C Hamano · lore

Re: [PATCH] One Git To Rule Them All

Calling it 'git' would conflict with the git binary from GNU Interactive Tools. That other git seems to not be maintained, the last release was on 2000-03-12. But still...

I think it should have been called 'lit' from the start, for Linus' Information Tracker.

-- 
Sebastian Kuzminsky
McMullan, Jason· Jun 1, 2005, 12:07 UTC · re: Junio C Hamano · lore

Re: [PATCH] One Git To Rule Them All

On Tue, 2005-05-31 at 23:21 -0700, Junio C Hamano wrote:
Show 7 quoted lines
> I think we had this discussion long time ago on the list, and
> instead of using cvs/svn style of "cmd subcmd" syntax, the
> consensus back then was that using "cmd-" prefix without spaces
> is easier for making TAB completion to work (you do not have to
> muck with command specific rules in the readline configuration),
> and this is especially helpful for people who ends up using the
> bare Plumbing. IIUC, the same reason is behind cg-* command set.

But all the git-<mumble> commands are still there, as symlinks to git. ie 'git-update-cache' and 'git update-cache' both work.

git-<TAB> still works.
Am I missing something here?
-- 
Jason McMullan <jason.mcmullan@timesys.com>
TimeSys Corporation
Junio C Hamano· Jun 1, 2005, 16:12 UTC · re: McMullan, Jason · lore

Re: [PATCH] One Git To Rule Them All

>>>>> "JM" == McMullan, Jason <jason.mcmullan@timesys.com> writes:
JM> Am I missing something here?

No, but one thing I failed to mention was that I am not a big fan of busybox. It is a cute hack to save "disk" space in an embedded environment, but I find the way many commands are bundled together a bit too hacky for my taste to use on my regular work box. I also suspect the change makes the maintenance of the result harder than having them separate.

You said with this change there is only one file to install, but you are not bundling the git-* scripts in the "single git", so that claim is not true either. If your patch handled the git-* script parts as well, then I would have admired that part of the change ;-).

Personally I find the mandatory documentation requirements this patch brings us is a good thing ;-).

McMullan, Jason· Jun 1, 2005, 16:22 UTC · re: Junio C Hamano · lore

Re: [PATCH] One Git To Rule Them All

On Wed, 2005-06-01 at 09:12 -0700, Junio C Hamano wrote:
Show 5 quoted lines
> You said with this change there is only one file to install, but
> you are not bundling the git-* scripts in the "single git", so
> that claim is not true either.  If your patch handled the git-*
> script parts as well, then I would have admired that part of the
> change ;-).
	You want git-* scripts? You sure? I can supply that patch
in about an hour... ;^)
> Personally I find the mandatory documentation requirements this
> patch brings us is a good thing ;-).
	So do I. Also, I really like the 'ordered by workflow'
help of 'git help'.
-- 
Jason McMullan <jason.mcmullan@timesys.com>
TimeSys Corporation

← back to recent threads