is-git-repository
Advanced tools
Comparing version 1.0.0 to 1.0.1
@@ -7,2 +7,4 @@ 'use strict'; | ||
var _os = require('os'); | ||
var _execa = require('execa'); | ||
@@ -20,3 +22,7 @@ | ||
try { | ||
_execa2.default.shellSync('(cd ' + altPath + ' ; ([ -d .git ] && echo .git) || git rev-parse --git-dir 2> /dev/null)'); | ||
if ((0, _os.platform)() === 'win32') { | ||
_execa2.default.shellSync('pushd ' + altPath + ' & git status'); | ||
} else { | ||
_execa2.default.shellSync('(cd ' + altPath + ' ; ([ -d .git ] && echo .git) || git rev-parse --git-dir 2> /dev/null)'); | ||
} | ||
@@ -23,0 +29,0 @@ return true; |
{ | ||
"name": "is-git-repository", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"description": "A tool to check if a specific path is a git repository", | ||
@@ -8,3 +8,3 @@ "main": "build.js", | ||
"pretest": "npm run lint", | ||
"test": "ava", | ||
"test": "nyc ava", | ||
"lint": "eslint index.js", | ||
@@ -37,7 +37,2 @@ "coveralls": "nyc report --reporter=text-lcov | coveralls", | ||
}, | ||
"nyc": { | ||
"exclude": [ | ||
"build.js" | ||
] | ||
}, | ||
"homepage": "https://github.com/JPeer264/node-is-git-repository#readme", | ||
@@ -44,0 +39,0 @@ "dependencies": { |
import { homedir } from 'os'; | ||
import test from 'ava'; | ||
import isGit from './'; | ||
import isGit from './index'; | ||
@@ -6,0 +6,0 @@ test('check if process.cwd() is a git repo', (t) => { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
143049
11
37