зеркало из https://github.com/docker/kitematic.git
Restoring old supportDir method
This commit is contained in:
Родитель
b41fddeb7c
Коммит
a2d1b478e3
|
@ -38,7 +38,6 @@ var _steps = [{
|
|||
seconds: 5,
|
||||
run: Promise.coroutine(function* (progressCallback) {
|
||||
var cmd = setupUtil.copyBinariesCmd() + ' && ' + setupUtil.fixBinariesCmd();
|
||||
|
||||
if (!virtualBox.installed()) {
|
||||
yield virtualBox.killall();
|
||||
cmd += ' && ' + setupUtil.installVirtualBoxCmd();
|
||||
|
@ -241,8 +240,6 @@ var SetupStore = assign(Object.create(EventEmitter.prototype), {
|
|||
metrics.track('Setup Failed', {
|
||||
step: _currentStep,
|
||||
});
|
||||
console.log(err);
|
||||
console.log(err.message);
|
||||
bugsnag.notify('SetupError', err.message, {
|
||||
error: err,
|
||||
output: err.message
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
var exec = require('exec');
|
||||
var Promise = require('bluebird');
|
||||
var fs = require('fs-promise');
|
||||
var fs = require('fs');
|
||||
var path = require('path');
|
||||
|
||||
module.exports = {
|
||||
|
@ -39,9 +39,14 @@ module.exports = {
|
|||
return process.env[this.isWindows() ? 'USERPROFILE' : 'HOME'];
|
||||
},
|
||||
supportDir: function () {
|
||||
var acc = path.join(this.home(), 'Library', 'Application\ Support', 'Kitematic');
|
||||
fs.mkdirsSync(acc);
|
||||
return acc;
|
||||
var dirs = ['Library', 'Application\ Support', 'Kitematic'];
|
||||
var acc = process.env.HOME;
|
||||
dirs.forEach(function (d) {
|
||||
acc = path.join(acc, d);
|
||||
if (!fs.existsSync(acc)) {
|
||||
fs.mkdirSync(acc);
|
||||
}
|
||||
});
|
||||
},
|
||||
CommandOrCtrl: function () {
|
||||
return this.isWindows() ? 'Ctrl' : 'Command';
|
||||
|
|
Загрузка…
Ссылка в новой задаче