Commits on Nov 10, 2009
  1. Merge branch 'jn/maint-http-fetch-mingw' into jn/help-everywhere

    gitster committed Nov 10, 2009
    * jn/maint-http-fetch-mingw:
      http-fetch: add missing initialization of argv0_path
      merge: do not setup worktree twice
      check-ref-format: update usage string
    
    Conflicts:
    	builtin-check-ref-format.c
  2. Show usage string for 'git check-ref-format -h'

    jrn committed with gitster Nov 9, 2009
    This only changes the behavior of "git check-ref-format -h"
    without any other options and arguments.
    
    This change cannot be breaking backward compatibility, since any
    valid refname must contain a /.   Most existing scripts use
    arguments such as "heads/$foo".  If some script checks the
    refname "-h" alone, git check-ref-format will still exit with
    nonzero status, and the only detrimental side-effect will be a
    usage string sent to stderr.
    
    Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  3. check-ref-format: update usage string

    jrn committed with gitster Nov 9, 2009
    'git check-ref-format' has learned --branch and --print options
    since the usage string was last updated.
    
    Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Oct 13, 2009
  1. check-ref-format: simplify --print implementation

    jrn committed with gitster Oct 12, 2009
    normalize_path_copy() is a complicated function, but most of its
    functionality will never apply to a ref name that has been checked
    with check_ref_format().
    
    Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Oct 12, 2009
  1. git check-ref-format --print

    gitster committed Oct 12, 2009
    Tolerating empty path components in ref names means each ref does
    not have a unique name.  This creates difficulty for porcelains
    that want to see if two branches are equal.  Add a helper associating
    to each ref a canonical name.
    
    If a user asks a porcelain to create a ref "refs/heads//master",
    the porcelain can run "git check-ref-format --print refs/heads//master"
    and only deal with "refs/heads/master" from then on.
    
    Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Mar 23, 2009
  1. strbuf_check_branch_ref(): a helper to check a refname for a branch

    gitster committed Mar 21, 2009
    This allows a common calling sequence
    
    	strbuf_branchname(&ref, name);
    	strbuf_splice(&ref, 0, 0, "refs/heads/", 11);
    	if (check_ref_format(ref.buf))
    		die(...);
    
    to be refactored into
    
    	if (strbuf_check_branch_ref(&ref, name))
    		die(...);
    
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  2. check-ref-format --branch: give Porcelain a way to grok branch shorthand

    gitster committed Mar 21, 2009
    The command may not be the best place to add this new feature, but
    
        $ git check-ref-format --branch "@{-1}"
    
    allows Porcelains to figure out what branch you were on before the last
    branch switching.
    
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Aug 30, 2008
  1. Start conforming code to "git subcmd" style

    heikkiorsila committed with gitster Aug 30, 2008
    User notifications are presented as 'git cmd', and code comments
    are presented as '"cmd"' or 'git's cmd', rather than 'git-cmd'.
    
    Signed-off-by: Heikki Orsila <heikki.orsila@iki.fi>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Aug 4, 2006
  1. Further clean-up: usage() vs die()

    Junio C Hamano committed Aug 4, 2006
    This hopefully finishes the clean-up Ramsay started with recent
    commit 15e593e and commit
    8cdf336.
    
    Signed-off-by: Junio C Hamano <junkio@cox.net>
Commits on Jul 29, 2006
  1. Call setup_git_directory() much earlier

    Linus Torvalds committed with Junio C Hamano Jul 29, 2006
    This changes the calling convention of built-in commands and
    passes the "prefix" (i.e. pathname of $PWD relative to the
    project root level) down to them.
    
    Signed-off-by: Linus Torvalds <torvalds@osdl.org>
    Signed-off-by: Junio C Hamano <junkio@cox.net>
Commits on May 18, 2006
  1. Make git-check-format-ref a builtin.

    Lukas Sandström committed with Junio C Hamano May 18, 2006
    Signed-off-by: Lukas Sandström <lukass@etek.chalmers.se>
    Signed-off-by: Junio C Hamano <junkio@cox.net>