gitconfiglocal
parse the .git/config file into a useful data structure
Last updated 10 years ago by soldair .
BSD · Repository · Bugs · Original npm · Tarball · package.json
$ gnpm install gitconfiglocal 
SYNC missed versions from official npm registry.

Build Status

gitconfiglocal

parse the .git/config file into a useful data structure

example

  • search config in $GIT_DIR (.git by default)
var gitconfig = require('gitconfiglocal');

gitconfig('./',function(err,config){
  console.log(config);
  /* prints:
  { core:
     { repositoryformatversion: '0',
       filemode: true,
       bare: false,
       logallrefupdates: true },
    remote:
     { origin:
        { url: 'git@github.com:soldair/node-gitconfiglocal.git',
          fetch: '+refs/heads/*:refs/remotes/origin/*' } } }
  */
});

  • specify $GIT_DIR via options:
gitconfig('./', { gitDir: 'path/to/gitdir' }, cb);

Current Tags

  • 2.1.0                                ...           latest (6 years ago)

8 Versions

  • 2.1.0                                ...           6 years ago
  • 2.0.2                                ...           6 years ago
  • 2.0.1                                ...           9 years ago
  • 1.0.0                                ...           9 years ago
  • 0.0.3                                ...           10 years ago
  • 0.0.2                                ...           10 years ago
  • 0.0.1                                ...           11 years ago
  • 0.0.0                                ...           12 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 5
Last Day 0
Last Week 5
Last Month 0
Dependencies (1)
Dev Dependencies (1)
Dependents (1)

Copyright 2013 - present © cnpmjs.org | Home |