Add VSCode configuration for debugging purposes (#886)

This commit is contained in:
Yuya Ochiai 2019-03-12 05:45:32 +09:00 committed by William Gathoye
parent c4cf9d5e0c
commit 427403aa47
3 changed files with 82 additions and 0 deletions

8
.vscode/extensions.json vendored Normal file
View file

@ -0,0 +1,8 @@
{
// See https://go.microsoft.com/fwlink/?LinkId=827846
// for the documentation about the extensions.json format
"recommendations": [
"dbaeumer.vscode-eslint",
"msjsdiag.debugger-for-chrome"
]
}

61
.vscode/launch.json vendored Normal file
View file

@ -0,0 +1,61 @@
{
"version": "0.2.0",
"configurations": [
{
"type": "node",
"request": "launch",
"name": "Debug Main Process",
"cwd": "${workspaceRoot}",
"runtimeExecutable": "${workspaceRoot}/node_modules/.bin/electron",
"runtimeArgs": [
"src",
"--disable-dev-mode"
],
"windows": {
"runtimeExecutable": "${workspaceRoot}/node_modules/.bin/electron.cmd"
},
"program": "${workspaceRoot}/src/main.js",
"outFiles": [
"${workspaceRoot}/src/main_bundle.js"
],
"sourceMaps": true,
"preLaunchTask": "Build sources"
},
/*
{
"name": "Debug Renderer Process",
"type": "chrome",
"request": "launch",
"runtimeExecutable": "${workspaceRoot}/node_modules/.bin/electron",
"windows": {
"runtimeExecutable": "${workspaceRoot}/node_modules/.bin/electron.cmd"
},
"runtimeArgs": [
"${workspaceRoot}/src",
"--disable-dev-mode",
"--remote-debugging-port=9222"
],
"webRoot": "${workspaceRoot}/src/browser",
"sourceMaps": true,
"preLaunchTask": "Build sources"
},
*/
{
"type": "node",
"request": "launch",
"name": "Mocha Tests",
"program": "${workspaceRoot}/node_modules/mocha/bin/_mocha",
"args": [
"-r",
"babel-register",
"--recursive",
"--timeout",
"999999",
"--colors",
"${workspaceRoot}/test/specs"
],
"internalConsoleOptions": "openOnSessionStart",
"preLaunchTask": "Build sources"
}
]
}

13
.vscode/tasks.json vendored Normal file
View file

@ -0,0 +1,13 @@
{
// See https://go.microsoft.com/fwlink/?LinkId=733558
// for the documentation about the tasks.json format
"version": "2.0.0",
"tasks": [
{
"label": "Build sources",
"type": "npm",
"script": "build",
"problemMatcher": []
}
]
}