From f4130f940f4e7683e2bf7d37a6050d3c6171547b Mon Sep 17 00:00:00 2001 From: Jia Hao Date: Tue, 26 Jan 2016 14:44:19 +0800 Subject: [PATCH] Convert app name capitalized camel case if building for linux to prevent dock problems --- src/options.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/options.js b/src/options.js index 5aca928..3a15c06 100644 --- a/src/options.js +++ b/src/options.js @@ -6,6 +6,7 @@ import request from 'request'; import cheerio from 'cheerio'; import validator from 'validator'; import sanitize from 'sanitize-filename'; +import _ from 'lodash'; const TEMPLATE_APP_DIR = path.join(__dirname, '../', 'app'); const ELECTRON_VERSION = '0.36.4'; @@ -88,6 +89,10 @@ function optionsFactory(name, function sanitizeOptions(options) { options.name = sanitize(options.name); + + if (options.platform === 'linux') { + options.name = _.upperFirst(_.camelCase(options.name)); + } return options; }