Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## 2.1.16

- [feat] support process.env.DISABLE_COLLECT to disable pv collect

## 2.1.15

- [feat] cli option --skip-compile for skip webpack compile
Expand Down
7 changes: 1 addition & 6 deletions packages/ice-scripts/lib/commands/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ const webpack = require('webpack');
const { collectDetail } = require('@alifd/fusion-collector');

const iceScriptsPkgData = require('../../package.json');
const goldlog = require('../utils/goldlog');
const log = require('../utils/log');
const checkDepsInstalled = require('../utils/checkDepsInstalled');

Expand All @@ -16,10 +15,6 @@ const checkDepsInstalled = require('../utils/checkDepsInstalled');
*/
module.exports = async function (context) {
const { applyHook, commandArgs, rootDir, webpackConfig, pkg } = context;
goldlog('version', {
version: iceScriptsPkgData.version,
});
goldlog('build', commandArgs);
log.verbose('build cliOptions', commandArgs);

await applyHook('beforeBuild');
Expand All @@ -29,7 +24,7 @@ module.exports = async function (context) {
return Promise.reject(new Error('项目依赖未安装,请先安装依赖。'));
}

if (!pkg.componentConfig && !pkg.blockConfig) {
if (!pkg.componentConfig && !pkg.blockConfig && !process.env.DISABLE_COLLECT) {
// only collect project
try {
collectDetail({
Expand Down
8 changes: 1 addition & 7 deletions packages/ice-scripts/lib/commands/dev.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,18 +14,12 @@ const WebpackDevServer = require('webpack-dev-server');
const openBrowser = require('react-dev-utils/openBrowser');
const iceworksClient = require('../utils/iceworksClient');
const prepareUrLs = require('../utils/prepareURLs');
const goldlog = require('../utils/goldlog');
const pkgData = require('../../package.json');
const log = require('../utils/log');
const checkDepsInstalled = require('../utils/checkDepsInstalled');

module.exports = async function(context, subprocess) {
const { applyHook, commandArgs, rootDir, webpackConfig, pkg } = context;

goldlog('version', {
version: pkgData.version,
});
goldlog('dev', commandArgs);
log.verbose('dev cliOptions', commandArgs);

await applyHook('beforeDev');
Expand All @@ -43,7 +37,7 @@ module.exports = async function(context, subprocess) {
return Promise.reject(new Error('项目依赖未安装,请先安装依赖。'));
}

if (!pkg.componentConfig && !pkg.blockConfig) {
if (!pkg.componentConfig && !pkg.blockConfig && !process.env.DISABLE_COLLECT) {
// only collect project
try {
collectDetail({
Expand Down
44 changes: 0 additions & 44 deletions packages/ice-scripts/lib/utils/goldlog.js

This file was deleted.

2 changes: 1 addition & 1 deletion packages/ice-scripts/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ice-scripts",
"version": "2.1.15",
"version": "2.1.16",
"description": "ICE SDK",
"main": "index.js",
"bin": {
Expand Down