@ionic/cli-plugin-gulp
Advanced tools
Comparing version 1.1.0-alpha.b9b49059 to 1.1.0-alpha.bfa36021
@@ -6,8 +6,2 @@ # Change Log | ||
<a name="1.1.0-alpha.b9b49059"></a> | ||
# [1.1.0-alpha.b9b49059](https://github.com/ionic-team/ionic-cli/compare/@ionic/cli-plugin-gulp@1.0.2...@ionic/cli-plugin-gulp@1.1.0-alpha.b9b49059) (2017-07-14) | ||
<a name="1.0.2"></a> | ||
@@ -14,0 +8,0 @@ ## [1.0.2](https://github.com/ionic-team/ionic-cli/compare/@ionic/cli-plugin-gulp@1.0.1...@ionic/cli-plugin-gulp@1.0.2) (2017-07-11) |
"use strict"; | ||
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { | ||
return new (P || (P = Promise))(function (resolve, reject) { | ||
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } | ||
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } | ||
function step(result) { result.done ? resolve(result.value) : new P(function (resolve) { resolve(result.value); }).then(fulfilled, rejected); } | ||
step((generator = generator.apply(thisArg, _arguments || [])).next()); | ||
}); | ||
}; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
const tslib_1 = require("tslib"); | ||
const path = require("path"); | ||
@@ -15,3 +8,3 @@ const chalk = require("chalk"); | ||
exports.name = '@ionic/cli-plugin-gulp'; | ||
exports.version = '1.1.0-alpha.b9b49059'; | ||
exports.version = '1.1.0-alpha.bfa36021'; | ||
const BUILD_BEFORE_HOOK = 'build:before'; | ||
@@ -26,3 +19,3 @@ const BUILD_BEFORE_TASK = `ionic:${BUILD_BEFORE_HOOK}`; | ||
function loadGulp(env) { | ||
return __awaiter(this, void 0, void 0, function* () { | ||
return tslib_1.__awaiter(this, void 0, void 0, function* () { | ||
if (_gulpInst || !env.project.directory) { | ||
@@ -49,3 +42,3 @@ return _gulpInst; | ||
try { | ||
const gulpFile = require(gulpFilePath); | ||
require(gulpFilePath); // requiring the gulp file sets up the gulp instance with local gulp task definitions | ||
} | ||
@@ -67,3 +60,3 @@ catch (e) { | ||
function registerHooks(hooks) { | ||
hooks.register(exports.name, 'plugins:init', ({ env }) => __awaiter(this, void 0, void 0, function* () { | ||
hooks.register(exports.name, 'plugins:init', ({ env }) => tslib_1.__awaiter(this, void 0, void 0, function* () { | ||
if (!env.project.directory) { | ||
@@ -79,3 +72,3 @@ return; | ||
} | ||
env.events.on('watch:init', () => __awaiter(this, void 0, void 0, function* () { | ||
env.events.on('watch:init', () => tslib_1.__awaiter(this, void 0, void 0, function* () { | ||
const gulp = yield loadGulp(env); | ||
@@ -87,13 +80,13 @@ if (gulp) { | ||
if (!gulp.hasTask(BUILD_BEFORE_TASK)) { | ||
env.log.debug(`No ${chalk.cyan(BUILD_BEFORE_TASK)} task found in Gulpfile.`); | ||
env.log.debug(() => `No ${chalk.cyan(BUILD_BEFORE_TASK)} task found in Gulpfile.`); | ||
} | ||
if (!gulp.hasTask(BUILD_AFTER_TASK)) { | ||
env.log.debug(`No ${chalk.cyan(BUILD_AFTER_TASK)} task found in Gulpfile.`); | ||
env.log.debug(() => `No ${chalk.cyan(BUILD_AFTER_TASK)} task found in Gulpfile.`); | ||
} | ||
if (!gulp.hasTask(WATCH_BEFORE_TASK)) { | ||
env.log.debug(`No ${chalk.cyan(WATCH_BEFORE_TASK)} task found in Gulpfile.`); | ||
env.log.debug(() => `No ${chalk.cyan(WATCH_BEFORE_TASK)} task found in Gulpfile.`); | ||
} | ||
} | ||
})); | ||
env.events.on('watch:change', (filePath) => __awaiter(this, void 0, void 0, function* () { | ||
env.events.on('watch:change', (filePath) => tslib_1.__awaiter(this, void 0, void 0, function* () { | ||
const gulp = yield loadGulp(env); | ||
@@ -104,3 +97,3 @@ if (gulp) { | ||
if (path.extname(filePath) === '.scss') { | ||
env.log.debug(`Invoking ${chalk.cyan(SASS_TASK)} gulp task.`); | ||
env.log.debug(() => `Invoking ${chalk.cyan(SASS_TASK)} gulp task.`); | ||
try { | ||
@@ -117,3 +110,3 @@ yield gulpStart(SASS_TASK); | ||
})); | ||
hooks.register(exports.name, BUILD_BEFORE_HOOK, ({ env }) => __awaiter(this, void 0, void 0, function* () { | ||
hooks.register(exports.name, BUILD_BEFORE_HOOK, ({ env }) => tslib_1.__awaiter(this, void 0, void 0, function* () { | ||
const gulp = yield loadGulp(env); | ||
@@ -123,3 +116,3 @@ if (gulp) { | ||
if (gulp.hasTask(BUILD_BEFORE_TASK)) { | ||
env.log.debug(`Invoking ${chalk.cyan(BUILD_BEFORE_TASK)} gulp task.`); | ||
env.log.debug(() => `Invoking ${chalk.cyan(BUILD_BEFORE_TASK)} gulp task.`); | ||
try { | ||
@@ -135,3 +128,3 @@ yield gulpStart(BUILD_BEFORE_TASK); | ||
})); | ||
hooks.register(exports.name, BUILD_AFTER_HOOK, ({ env }) => __awaiter(this, void 0, void 0, function* () { | ||
hooks.register(exports.name, BUILD_AFTER_HOOK, ({ env }) => tslib_1.__awaiter(this, void 0, void 0, function* () { | ||
const gulp = yield loadGulp(env); | ||
@@ -141,3 +134,3 @@ if (gulp) { | ||
if (gulp.hasTask(BUILD_AFTER_TASK)) { | ||
env.log.debug(`Invoking ${chalk.cyan(BUILD_AFTER_TASK)} gulp task.`); | ||
env.log.debug(() => `Invoking ${chalk.cyan(BUILD_AFTER_TASK)} gulp task.`); | ||
try { | ||
@@ -153,3 +146,3 @@ yield gulpStart(BUILD_AFTER_TASK); | ||
})); | ||
hooks.register(exports.name, WATCH_BEFORE_HOOK, ({ env }) => __awaiter(this, void 0, void 0, function* () { | ||
hooks.register(exports.name, WATCH_BEFORE_HOOK, ({ env }) => tslib_1.__awaiter(this, void 0, void 0, function* () { | ||
const gulp = yield loadGulp(env); | ||
@@ -159,3 +152,3 @@ if (gulp) { | ||
if (gulp.hasTask(WATCH_BEFORE_TASK)) { | ||
env.log.debug(`Invoking ${chalk.cyan(WATCH_BEFORE_TASK)} gulp task.`); | ||
env.log.debug(() => `Invoking ${chalk.cyan(WATCH_BEFORE_TASK)} gulp task.`); | ||
try { | ||
@@ -171,3 +164,3 @@ yield gulpStart(WATCH_BEFORE_TASK); | ||
})); | ||
hooks.register(exports.name, 'command:info', ({ env }) => __awaiter(this, void 0, void 0, function* () { | ||
hooks.register(exports.name, 'command:info', ({ env }) => tslib_1.__awaiter(this, void 0, void 0, function* () { | ||
let gulpVersion = yield cli_utils_1.getCommandInfo('gulp', ['--version']); | ||
@@ -180,3 +173,3 @@ if (gulpVersion) { | ||
{ type: 'global-packages', name: 'Gulp CLI', version: gulpVersion || 'not installed globally' }, | ||
{ type: 'local-packages', name: exports.name, version: exports.version }, | ||
{ type: 'cli-packages', name: exports.name, version: exports.version, path: path.dirname(path.dirname(__filename)) }, | ||
]; | ||
@@ -183,0 +176,0 @@ })); |
{ | ||
"name": "@ionic/cli-plugin-gulp", | ||
"version": "1.1.0-alpha.b9b49059", | ||
"version": "1.1.0-alpha.bfa36021", | ||
"description": "Ionic CLI plugin for subscribing to CLI hooks with gulp", | ||
@@ -10,3 +10,3 @@ "homepage": "https://ionic.io/", | ||
"clean": "rm -rf ./dist", | ||
"lint": "tslint -c ../../tslint.json \"src/**/*.ts\"", | ||
"lint": "tslint --config ../../tslint.js --project tsconfig.json --type-check", | ||
"build": "npm run clean && npm run build-ts && npm run build-js", | ||
@@ -47,7 +47,8 @@ "build-ts": "tsc", | ||
"dependencies": { | ||
"@ionic/cli-utils": "1.6.0-alpha.b9b49059", | ||
"chalk": "^2.0.0" | ||
"@ionic/cli-utils": "1.6.0-alpha.bfa36021", | ||
"chalk": "^2.0.0", | ||
"tslib": "^1.7.1" | ||
}, | ||
"devDependencies": { | ||
"@ionic/cli-scripts": "0.3.0-alpha.b9b49059", | ||
"@ionic/cli-scripts": "0.3.0-alpha.bfa36021", | ||
"@types/chalk": "^0.4.31", | ||
@@ -54,0 +55,0 @@ "@types/gulp": "4.0.3" |
12378
3
168
+ Addedtslib@^1.7.1
+ Added@ionic/cli-utils@1.6.0-alpha.bfa36021(transitive)
+ Addeddev-null@0.1.1(transitive)
+ Addedtslib@1.14.1(transitive)
- Removed@ionic/cli-utils@1.6.0-alpha.b9b49059(transitive)
- Removedrimraf@2.7.1(transitive)