diff --git a/package.json b/package.json index 745f3447..b29d7733 100644 --- a/package.json +++ b/package.json @@ -8,23 +8,23 @@ "debug": "^3.1.0" }, "devDependencies": { - "@oclif/errors": "^1.0.2", - "@oclif/parser": "^3.2.9", - "@oclif/tslint": "^1.0.2", + "@oclif/errors": "^1.0.3", + "@oclif/parser": "^3.2.11", + "@oclif/tslint": "^1.1.0", "@types/chai": "^4.1.2", "@types/globby": "^6.1.0", "@types/indent-string": "^3.0.0", "@types/mocha": "^5.0.0", - "@types/node": "^9.6.0", + "@types/node": "^9.6.2", "@types/wrap-ansi": "^3.0.0", "chai": "^4.1.2", "concurrently": "^3.5.1", - "fancy-test": "^1.0.1", + "fancy-test": "^1.0.4", "globby": "^8.0.1", "mocha": "^5.0.5", "ts-node": "^5.0.1", "tslint": "^5.9.1", - "typescript": "^2.7.2" + "typescript": "^2.8.1" }, "engines": { "node": ">=8.0.0" diff --git a/src/config.ts b/src/config.ts index 741e4533..c81c23d5 100644 --- a/src/config.ts +++ b/src/config.ts @@ -153,6 +153,7 @@ export class Config implements IConfig { this.windows = this.platform === 'win32' this.bin = this.pjson.oclif.bin || this.name this.dirname = this.pjson.oclif.dirname || this.name + if (this.platform === 'win32') this.dirname = this.dirname.replace('/', '\\') this.userAgent = `${this.name}/${this.version} ${this.platform}-${this.arch} node-${process.version}` this.shell = this._shell() this.debug = this._debug() diff --git a/test/config.test.ts b/test/config.test.ts index 4f607fa7..a92fc92c 100644 --- a/test/config.test.ts +++ b/test/config.test.ts @@ -46,10 +46,10 @@ describe('PluginConfig', () => { .add('config', () => Config.load()) .end('win32', ({config}) => { expect(config).to.include({ - cacheDir: path.join('/my/home/localappdata/@oclif/config'), - configDir: path.join('/my/home/localappdata/@oclif/config'), - errlog: path.join('/my/home/localappdata/@oclif/config/error.log'), - dataDir: path.join('/my/home/localappdata/@oclif/config'), + cacheDir: path.join('/my/home/localappdata/@oclif\\config'), + configDir: path.join('/my/home/localappdata/@oclif\\config'), + errlog: path.join('/my/home/localappdata/@oclif\\config/error.log'), + dataDir: path.join('/my/home/localappdata/@oclif\\config'), home: path.join('/my/home'), }) }) diff --git a/yarn.lock b/yarn.lock index 80bb1e25..e1431f30 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6,9 +6,9 @@ version "1.0.0" resolved "https://registry.yarnpkg.com/@heroku/linewrap/-/linewrap-1.0.0.tgz#a9d4e99f0a3e423a899b775f5f3d6747a1ff15c6" -"@oclif/errors@^1.0.2": - version "1.0.2" - resolved "https://registry.yarnpkg.com/@oclif/errors/-/errors-1.0.2.tgz#0a3f773d673a3ccd8dc26bf2e3c49580afcbe30e" +"@oclif/errors@^1.0.3": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@oclif/errors/-/errors-1.0.3.tgz#f23c024075855c7d116d041ee158f99bd51175af" dependencies: clean-stack "^1.3.0" fs-extra "^5.0.0" @@ -16,17 +16,18 @@ strip-ansi "^4.0.0" wrap-ansi "^3.0.1" -"@oclif/parser@^3.2.9": - version "3.2.9" - resolved "https://registry.yarnpkg.com/@oclif/parser/-/parser-3.2.9.tgz#76d01106971e20dfcfec5be276c4e6e9edfee9ec" +"@oclif/parser@^3.2.11": + version "3.2.11" + resolved "https://registry.yarnpkg.com/@oclif/parser/-/parser-3.2.11.tgz#03a5fef0c45dd1badd0375ae05b476e0c27faf40" dependencies: "@heroku/linewrap" "^1.0.0" + chalk "^2.3.2" -"@oclif/tslint@^1.0.2": - version "1.0.2" - resolved "https://registry.yarnpkg.com/@oclif/tslint/-/tslint-1.0.2.tgz#793d39758082f359469dba8ce5cfba041d7a7847" +"@oclif/tslint@^1.1.0": + version "1.1.0" + resolved "https://registry.yarnpkg.com/@oclif/tslint/-/tslint-1.1.0.tgz#a2d494a61afa882a685fe5f4d866dafd18990728" dependencies: - tslint-xo "^0.6.0" + tslint-xo "^0.7.0" "@types/chai@^4.1.2": version "4.1.2" @@ -66,9 +67,9 @@ version "9.4.5" resolved "https://registry.yarnpkg.com/@types/node/-/node-9.4.5.tgz#d2a90c634208173d1b1a0a6ba9f1df3de62edcf5" -"@types/node@^9.6.0": - version "9.6.0" - resolved "https://registry.yarnpkg.com/@types/node/-/node-9.6.0.tgz#d3480ee666df9784b1001a1872a2f6ccefb6c2d7" +"@types/node@^9.6.2": + version "9.6.2" + resolved "https://registry.yarnpkg.com/@types/node/-/node-9.6.2.tgz#e49ac1adb458835e95ca6487bc20f916b37aff23" "@types/wrap-ansi@^3.0.0": version "3.0.0" @@ -100,6 +101,12 @@ ansi-styles@^3.2.0: dependencies: color-convert "^1.9.0" +ansi-styles@^3.2.1: + version "3.2.1" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d" + dependencies: + color-convert "^1.9.0" + argparse@^1.0.7: version "1.0.9" resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.9.tgz#73d83bc263f86e97f8cc4f6bae1b0e90a7d22c86" @@ -260,6 +267,14 @@ chalk@^2.3.0: escape-string-regexp "^1.0.5" supports-color "^5.2.0" +chalk@^2.3.2: + version "2.3.2" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.3.2.tgz#250dc96b07491bfd601e648d66ddf5f60c7a5c65" + dependencies: + ansi-styles "^3.2.1" + escape-string-regexp "^1.0.5" + supports-color "^5.3.0" + check-error@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/check-error/-/check-error-1.0.2.tgz#574d312edd88bb5dd8912e9286dd6c0aed4aac82" @@ -384,7 +399,7 @@ dir-glob@^2.0.0: arrify "^1.0.1" path-type "^3.0.0" -doctrine@^0.7.2: +doctrine@0.7.2: version "0.7.2" resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-0.7.2.tgz#7cb860359ba3be90e040b26b729ce4bfa654c523" dependencies: @@ -445,12 +460,12 @@ extglob@^2.0.2: snapdragon "^0.8.1" to-regex "^3.0.1" -fancy-test@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/fancy-test/-/fancy-test-1.0.1.tgz#28eb801dffc341d7202ed90b6944019922b08b5b" +fancy-test@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/fancy-test/-/fancy-test-1.0.4.tgz#fa689cfc98abec74a0b2f4386d92c58f1ef20f11" dependencies: - lodash "^4.17.4" - stdout-stderr "^0.1.6" + lodash "^4.17.5" + stdout-stderr "^0.1.8" fast-glob@^2.0.2: version "2.0.3" @@ -763,7 +778,7 @@ lazy-cache@^2.0.2: dependencies: set-getter "^0.1.0" -lodash@^4.17.4, lodash@^4.5.1: +lodash@^4.17.5, lodash@^4.5.1: version "4.17.5" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.5.tgz#99a92d65c0272debe8c96b6057bc8fbfa3bed511" @@ -1068,10 +1083,11 @@ static-extend@^0.1.1: define-property "^0.2.5" object-copy "^0.1.0" -stdout-stderr@^0.1.6: - version "0.1.7" - resolved "https://registry.yarnpkg.com/stdout-stderr/-/stdout-stderr-0.1.7.tgz#f3f69391f3e721c2c52aa92fbfa18b8a6e9ce3df" +stdout-stderr@^0.1.8: + version "0.1.9" + resolved "https://registry.yarnpkg.com/stdout-stderr/-/stdout-stderr-0.1.9.tgz#9b48ee04eff955ee07776e27125d5524d9d02f57" dependencies: + debug "^3.1.0" strip-ansi "^4.0.0" string-width@^2.1.1: @@ -1125,6 +1141,12 @@ supports-color@^5.2.0: dependencies: has-flag "^3.0.0" +supports-color@^5.3.0: + version "5.3.0" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.3.0.tgz#5b24ac15db80fa927cf5227a4a33fd3c4c7676c0" + dependencies: + has-flag "^3.0.0" + to-object-path@^0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/to-object-path/-/to-object-path-0.3.0.tgz#297588b7b0e7e0ac08e04e672f85c1f4999e17af" @@ -1163,7 +1185,7 @@ ts-node@^5.0.1: source-map-support "^0.5.3" yn "^2.0.0" -tslib@^1.0.0, tslib@^1.7.1, tslib@^1.8.0, tslib@^1.8.1: +tslib@1.9.0, tslib@^1.7.1, tslib@^1.8.0, tslib@^1.8.1: version "1.9.0" resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.9.0.tgz#e37a86fda8cbbaf23a057f473c9f4dc64e5fc2e8" @@ -1174,13 +1196,13 @@ tslint-consistent-codestyle@^1.11.0: tslib "^1.7.1" tsutils "^2.21.0" -tslint-eslint-rules@^4.1.1: - version "4.1.1" - resolved "https://registry.yarnpkg.com/tslint-eslint-rules/-/tslint-eslint-rules-4.1.1.tgz#7c30e7882f26bc276bff91d2384975c69daf88ba" +tslint-eslint-rules@^5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/tslint-eslint-rules/-/tslint-eslint-rules-5.1.0.tgz#3232b318da55dbb5a83e3f5d657c1ddbb27b9ff2" dependencies: - doctrine "^0.7.2" - tslib "^1.0.0" - tsutils "^1.4.0" + doctrine "0.7.2" + tslib "1.9.0" + tsutils "2.8.0" tslint-microsoft-contrib@^5.0.2: version "5.0.2" @@ -1188,12 +1210,12 @@ tslint-microsoft-contrib@^5.0.2: dependencies: tsutils "^2.12.1" -tslint-xo@^0.6.0: - version "0.6.0" - resolved "https://registry.yarnpkg.com/tslint-xo/-/tslint-xo-0.6.0.tgz#95a05b8dcac7aaa1f4d6ca1397a3c4c45a8b848e" +tslint-xo@^0.7.0: + version "0.7.0" + resolved "https://registry.yarnpkg.com/tslint-xo/-/tslint-xo-0.7.0.tgz#be5a1d67f8ade5d92aa8c0a21d9cfdcbaf06f3e0" dependencies: tslint-consistent-codestyle "^1.11.0" - tslint-eslint-rules "^4.1.1" + tslint-eslint-rules "^5.1.0" tslint-microsoft-contrib "^5.0.2" tslint@^5.9.1: @@ -1213,9 +1235,11 @@ tslint@^5.9.1: tslib "^1.8.0" tsutils "^2.12.1" -tsutils@^1.4.0: - version "1.9.1" - resolved "https://registry.yarnpkg.com/tsutils/-/tsutils-1.9.1.tgz#b9f9ab44e55af9681831d5f28d0aeeaf5c750cb0" +tsutils@2.8.0: + version "2.8.0" + resolved "https://registry.yarnpkg.com/tsutils/-/tsutils-2.8.0.tgz#0160173729b3bf138628dd14a1537e00851d814a" + dependencies: + tslib "^1.7.1" tsutils@^2.12.1, tsutils@^2.21.0: version "2.21.1" @@ -1227,9 +1251,9 @@ type-detect@^4.0.0: version "4.0.8" resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-4.0.8.tgz#7646fb5f18871cfbb7749e69bd39a6388eb7450c" -typescript@^2.7.2: - version "2.7.2" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-2.7.2.tgz#2d615a1ef4aee4f574425cdff7026edf81919836" +typescript@^2.8.1: + version "2.8.1" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-2.8.1.tgz#6160e4f8f195d5ba81d4876f9c0cc1fbc0820624" union-value@^1.0.0: version "1.0.0"