Skip to content

Commit

Permalink
fix(ui): Windows compat
Browse files Browse the repository at this point in the history
  • Loading branch information
Akryum committed May 23, 2018
1 parent 21a3421 commit bf76950
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/@vue/cli-ui/src/graphql-api/connectors/tasks.js
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ async function run (id, context) {

const child = execa(command, args, {
cwd: cwd.get(),
stdio: ['inherit', 'pipe', 'pipe', 'ipc']
stdio: ['inherit', 'pipe', 'pipe']
})

task.child = child
Expand Down
5 changes: 4 additions & 1 deletion packages/@vue/cli-ui/src/graphql-api/utils/resolve-path.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
const path = require('path')

exports.resolveModuleRoot = function (filePath, id = null) {
{
const index = filePath.lastIndexOf('/index.js')
const index = filePath.lastIndexOf(path.sep + 'index.js')
if (index !== -1) {
filePath = filePath.substr(0, index)
}
}
if (id) {
id = id.replace(/\//g, path.sep)
const index = filePath.lastIndexOf(id)
if (index !== -1) {
filePath = filePath.substr(0, index + id.length)
Expand Down

0 comments on commit bf76950

Please sign in to comment.