Browse Source

Add debug task, add sensible defaults for Visual Studio Code.

pull/3202/head
TheGoddessInari 6 years ago
parent
commit
8438f465d4
No known key found for this signature in database
GPG Key ID: 1209B1B7632D69A
  1. 37
      .vscode/launch.json
  2. 20
      .vscode/settings.json
  3. 16
      .vscode/tasks.json
  4. 2
      package.json

37
.vscode/launch.json vendored

@ -0,0 +1,37 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "Rambox-OS: Main",
"type": "node",
"request": "launch",
"protocol": "inspector",
"runtimeExecutable": "${workspaceFolder}/node_modules/.bin/electron",
"args": [
"--remote-debugging-port=9223",
"build/production/Rambox"
],
"outFiles": [ "${workspaceFolder}/build/production/**/*.js" ]
},
{
"name": "Rambox-OS: Renderer",
"type": "chrome",
"request": "attach",
"port": 9223,
"webRoot": "${workspaceFolder}",
"timeout": 30000,
},
],
"compounds": [
{
"name": "Rambox-OS: All",
"configurations": [
"Rambox-OS: Main",
"Rambox-OS: Renderer"
]
}
]
}

20
.vscode/settings.json vendored

@ -0,0 +1,20 @@
{
"eslint.enable": true,
"search.exclude": {
"**/node_modules": true,
"**/bower_components": true,
"ext": true,
"**/.sencha": true,
"**/*.jsonp": true,
"**/sencha-error-*.log": true
},
"es6-css-minify.css": {
"level": 2
},
"es6-css-minify.js": {
"output": {
"ecma": 6
}
},
"es6-css-minify.minifyOnSave": "exists",
}

16
.vscode/tasks.json vendored

@ -0,0 +1,16 @@
{
// See https://go.microsoft.com/fwlink/?LinkId=733558
// for the documentation about the tasks.json format
"version": "2.0.0",
"tasks": [
{
"type": "npm",
"script": "compile",
"problemMatcher": [],
"group": {
"kind": "build",
"isDefault": true
}
}
]
}

2
package.json

@ -2,7 +2,7 @@
"private": true,
"scripts": {
"start": "npm run compile && electron-builder install-app-deps && electron build/production/Rambox",
"start:debug": "npm run compile && electron build/production/Rambox --enable-logging",
"debug": "electron --inspect build/production/Rambox",
"test": "mocha test/tests/**/*.spec.js",
"buildversion": "git show --pretty=\"%h %d %cD\" -s > build/production/Rambox/BUILDVERSION || node -p -e \"require('./build/production/Rambox/package.json').version\" > build/production/Rambox/BUILDVERSION",
"clean": "shx rm -rf ./build/production",

Loading…
Cancel
Save