Socket
Socket
Sign inDemoInstall

fetch-git-config

Package Overview
Dependencies
1
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    fetch-git-config

fetch user's local or global .gitconfig


Version published
Weekly downloads
6
Maintainers
1
Install size
11.6 kB
Created
Weekly downloads
 

Readme

Source

#fetch-git-config

fetch user's local or global .gitconfig

Install

Node.js 4 or higher

$ npm install fetch-git-config --save

Usage

fetch current working directory

var fetch = require('fetch-git-config');

// async
fetch().then(function(data) {
  // do something
});

// sync
var data = fetch.sync();
// do something

fetch global

// async
fetch('global').then(function(data) {
  // do something
});

// sync
var data = fetch.sync('global');

fetch custom path and cwd

// async
fetch({cwd: 'foo', path: '.git/config'}).then(function(data) {
 // do something
});

// sync
var data = fetch.sync({cwd: 'foo', path: '.git/config'});

Keywords

FAQs

Last updated on 29 Sep 2016

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc