Commit f5dfdeca by 刘旭阳

Merge branch '0.1.1' into 'master'

0.1.1 See merge request !12
parents d560d0e2 765a5437
{
"name": "babel-plugin-ry-istanbul-web",
"version": "0.1.0",
"version": "0.1.2",
"author": "Thai Pangsakulyanont @dtinth",
"license": "BSD-3-Clause",
"description": "A babel plugin that adds istanbul instrumentation to ES6 code",
......
......@@ -119,7 +119,7 @@ export default declare(api => {
const realPath = getRealpath(this.file.opts.filename)
const { instrmenttation = {} } = this.nycConfig // npm引入参数
let IS_PITCHING_PILE_DATA = false
let INCREMENT_DATA = 'false'
let INCREMENT_DATA = false
let BRANCH_DATA = 'origin/master'
let processData = {}
Object.keys(process.env).forEach(item => {
......@@ -158,7 +158,7 @@ export default declare(api => {
// })
// 后面解开
if ((INCREMENT_DATA || INCREMENT_DATA === 'true') && BRANCH_DATA) {
const gitDiffCode = execSync(`git add . && git diff ${BRANCH_DATA}`)
const gitDiffCode = execSync(`git add . && git diff --cached ${BRANCH_DATA}`)
const diffData = parseDiffData(gitDiffCode.toString())
diffScreen = diffData.find(item => {
return realPath.indexOf(item.to) > -1
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment