From f2cf1d4e038143c637de681c27b95b7d12cd7a02 Mon Sep 17 00:00:00 2001 From: Ibrahim Hadeed Date: Sat, 27 Aug 2016 13:03:39 -0400 Subject: [PATCH] chore(): add minimal template --- TEMPLATE-MIN | 19 +++++++++++++++++++ gulpfile.js | 3 ++- 2 files changed, 21 insertions(+), 1 deletion(-) create mode 100644 TEMPLATE-MIN diff --git a/TEMPLATE-MIN b/TEMPLATE-MIN new file mode 100644 index 000000000..052eac55b --- /dev/null +++ b/TEMPLATE-MIN @@ -0,0 +1,19 @@ +import {Plugin} from './plugin'; +/** + * @name PluginName + * @description + * + * @usage + * ``` + * import {PluginName} from 'ionic-native'; + * + * + * ``` + */ +@Plugin({ + plugin: '', + pluginRef: '', + repo: '' +}) +export class PluginName { +} diff --git a/gulpfile.js b/gulpfile.js index eaaf8e872..03ed13d27 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -33,7 +33,8 @@ gulp.task('lint', function() { gulp.task('plugin:create', function(){ if(flags.n && flags.n !== ''){ - return gulp.src('./TEMPLATE') + var src = flags.m?'./TEMPLATE-MIN':'./TEMPLATE'; + return gulp.src() .pipe(replace('PluginName', flags.n)) .pipe(rename(decamelize(flags.n, '-') + '.ts')) .pipe(gulp.dest('./src/plugins/'));