writeProjectConfigFile () { var configJson = { 'projectName': this.options.projectName, 'qtyScreens': this.options.qtyScreens, 'markupLanguage': this.options.markupLanguage, 'frontEndFramework': this.options.frontEndFramework, 'jQuery': this.options.jQuery || this.options.frontEndFramework, 'generatedBy': 'Pixel2HTML', 'generatorVersion': pkg.version, 'generatedAt': new Date(), } this.fs.writeJSON('./.project.conf', configJson) }
writeHtmlFiles () { if (this.options.markupLanguage === 'html') { for (var i = 1; i < this.options.qtyScreens + 1; i++) { const filePath = i === 1 ? '/index.html' : '/screen-' + i + '.' + this.options.markupLanguage this.fs.copyTpl( this.templatePath('markup/_screen.' + this.options.markupLanguage + '.ejs'), this.destinationPath(this.paths.src.markup + filePath), { screenNumber: i, projectName: this.options.projectName, frontEndFramework: this.options.frontEndFramework, jQuery: this.options.jQuery } ) } } }
jQuery: this.options.jQuery, qtyScreens: this.options.qtyScreens, markupLanguage: this.options.markupLanguage, now: new Date(), version: pkg.version
frontEndFramework: this.options.frontEndFramework, jQuery: this.options.jQuery, markupLanguage: this.options.markupLanguage this.destinationPath(this.paths.src.gulp + '/config.js'), { paths: this.paths, markupLanguage: this.options.markupLanguage, frontEndFramework: this.options.frontEndFramework, jQuery: this.options.jQuery this.destinationPath(`gulp/${file}.js`), { paths: this.paths, markupLanguage: this.options.markupLanguage, clientId: this.options.clientId, projectId: this.options.projectId,
writePugFiles () { if (this.options.markupLanguage === 'pug') { for (var i = 1; i < this.options.qtyScreens + 1; i++) { const filePath = i === 1 ? 'index.pug' : ('screen-' + i + '.' + this.options.markupLanguage) this.fs.copyTpl( this.templatePath('markup/pug/_screen.' + this.options.markupLanguage), this.destinationPath(this.paths.src.markup + '/pug/' + filePath),