From 7777dee9f38988f9fabd004b4f61f4c269c01a3e Mon Sep 17 00:00:00 2001 From: Manuel Thalmann Date: Mon, 7 Oct 2019 21:33:33 +0000 Subject: [PATCH] Add debug-configurations --- .devcontainer/devcontainer.json | 5 ++++- .devcontainer/docker-compose.yml | 1 + .vscode/extensions.json | 5 ++++- .vscode/launch.json | 38 ++++++++++++++++++++++++++++++++ 4 files changed, 47 insertions(+), 2 deletions(-) create mode 100644 .vscode/launch.json diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 59c118a..0160cc7 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -4,6 +4,9 @@ "service": "silverstripe", "workspaceFolder": "/vscode/src/mantra", "extensions": [ - "ms-vscode.vscode-typescript-tslint-plugin" + "felixfbecker.php-pack", + "ms-vscode.vscode-typescript-tslint-plugin", + "msjsdiag.debugger-for-chrome", + "neilbrayfield.php-docblocker" ] } \ No newline at end of file diff --git a/.devcontainer/docker-compose.yml b/.devcontainer/docker-compose.yml index a1456d4..7cb5262 100644 --- a/.devcontainer/docker-compose.yml +++ b/.devcontainer/docker-compose.yml @@ -8,6 +8,7 @@ services: - 8080:80 - 3000:3000 - 3001:3001 + - 9000:9000 volumes: - ..:/vscode/src/mantra - ../test/website:/var/www/html diff --git a/.vscode/extensions.json b/.vscode/extensions.json index bd441a3..c235dea 100644 --- a/.vscode/extensions.json +++ b/.vscode/extensions.json @@ -5,8 +5,11 @@ // List of extensions which should be recommended for users of this workspace. "recommendations": [ "adrianhumphreys.silverstripe", + "felixfbecker.php-pack", "ms-vscode.vscode-typescript-tslint-plugin", - "ms-vscode-remote.remote-containers" + "ms-vscode-remote.remote-containers", + "msjsdiag.debugger-for-chrome", + "neilbrayfield.php-docblocker" ], // List of extensions recommended by VS Code that should not be recommended for users of this workspace. "unwantedRecommendations": [ diff --git a/.vscode/launch.json b/.vscode/launch.json new file mode 100644 index 0000000..9be4217 --- /dev/null +++ b/.vscode/launch.json @@ -0,0 +1,38 @@ +{ + // 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": [ + { + "type": "chrome", + "request": "launch", + "name": "Launch Chrome", + "url": "http://localhost:3000", + "webRoot": "${workspaceFolder}/test/website/public", + "pathMapping": { + "/_resources/themes/mantra": "${workspaceFolder}" + }, + "preLaunchTask": "Watch Debug", + "postDebugTask": "Stop Debug" + }, + { + "name": "Listen for XDebug", + "type": "php", + "request": "launch", + "port": 9000, + "pathMappings": { + "/var/www/html": "${workspaceFolder}/test/website" + } + } + ], + "compounds": [ + { + "name": "Debug Theme", + "configurations": [ + "Launch Chrome", + "Listen for XDebug" + ] + } + ] +} \ No newline at end of file