• Jeff King's avatar
    clone: accept config options on the command line · 84054f79
    Jeff King authored
    Clone does all of init, "remote add", fetch, and checkout
    without giving the user a chance to intervene and set any
    configuration. This patch allows you to set config options
    in the newly created repository after the clone, but before
    we do any other operations.
    In many cases, this is a minor convenience over something
      git clone git://...
      git config core.whatever true
    But in some cases, it can bring extra efficiency by changing
    how the fetch or checkout work. For example, setting
    line-ending config before the checkout avoids having to
    re-checkout all of the contents with the correct line
    It also provides a mechanism for passing information to remote
    helpers during a clone; the helpers may read the git config
    to influence how they operate.
    Signed-off-by: default avatarJeff King <peff@peff.net>
    Signed-off-by: default avatarJunio C Hamano <gitster@pobox.com>
t5708-clone-config.sh 1.01 KB