1// *** Autogenerated file - created by configure.ac *** 2// you should save the auto-generated vs-code-templates.code-workspace to a separate file 3// to prevent your changes from being overwritten 4{ 5 "extensions": { 6 "recommendations": [ 7 "ms-vscode.cpptools" 8 ] 9 }, 10 "folders": [ 11 { 12 "name": "srcdir", 13 "path": "@SRC_ROOT@" 14 }, 15 { 16 "name": "builddir", 17 "path": "@BUILDDIR@" 18 } 19 ], 20 "settings": { 21 "search.exclude": { 22 "/compile_commands.json": true, 23 "/dictionaries/": true, 24 "/helpcontent2/": true, 25 "/icon-themes/": true, 26 "/translations/": true 27 }, 28 "files.watcherExclude": { 29 "/dictionaries/": true, 30 "/helpcontent2/": true, 31 "/icon-themes/": true, 32 "/translations/": true 33 }, 34 "files.associations": { 35 "*.patch.[0-9]": "diff" 36 }, 37 // FIXME: arguably the generator should place it in the builddir, not srcdir 38 "C_Cpp.default.compileCommands": "${workspaceFolder:srcdir}/compile_commands.json", 39 // only used if the file doesn't match anything in the compile_commands.json - aka externals 40 // libxml includes just added as example/for reference 41 "C_Cpp.default.includePath": [ 42 "@WORKDIR@/UnpackedTarball/**", 43 "/usr/include/libxml2/" 44 ], 45 "C_Cpp.default.browse.limitSymbolsToIncludedHeaders": true, 46 "C_Cpp.default.cppStandard": "c++17", 47 // point this to LibreOffice's version of clang-format 5.0.0, 48 // otherwise clang-format from the plugin is used, and that 49 // gives slightly different results 50 "C_Cpp.clang_format_path": "/opt/lo/bin/clang-format", 51 "editor.rulers": [ 52 100 53 ], 54 "gitlens.autolinks": [ 55 { 56 "prefix": "tdf#", 57 "url": "https://bugs.documentfoundation.org/show_bug.cgi?id=<num>" 58 } 59 ] 60 }, 61 "tasks": { 62 "version": "2.0.0", 63 "tasks": [ 64 { 65 "label": "full make", 66 "detail": "runs make in builddir to update everything", 67 "type": "shell", 68 "command": "make", 69 "group": { 70 "kind": "build", 71 "isDefault": true 72 }, 73 "options": { 74 "cwd": "@BUILDDIR@" 75 } 76 }, 77 { 78 "label": "create compile-commands.json", 79 "detail": "runs make vim-ide-integration to create the compile-commands.json file", 80 "type": "shell", 81 "command": "make", 82 "args": [ 83 "vim-ide-integration" 84 ], 85 "group": "build", 86 // doesn't really depend on full make, but doesn't hurt 87 // updating the compile-commands is not needed all the time and also demonstrate 88 // how to use dependencies in tasks… 89 "dependsOn": [ 90 "full make" 91 ], 92 "options": { 93 "cwd": "@BUILDDIR@" 94 }, 95 "problemMatcher": [] // don't ask when manually running the task 96 }, 97 { 98 "label": "remove profile-dir", 99 "detail": "removes the temporary user-profile directory", 100 "type": "shell", 101 "command": "rm", 102 "args": [ 103 "-rf", 104 "@WORKDIR@/vs-code-temporary-user-profile" 105 ], 106 "group": "none", 107 "dependsOn": [ 108 "full make" 109 ], 110 "options": { 111 "cwd": "@BUILDDIR@" 112 }, 113 "problemMatcher": [] 114 } 115 ] 116 }, 117 "launch": { 118 "configurations": [ 119 { 120 "name": "run in debugger after make", 121 "type": "cppdbg", 122 "request": "launch", 123 "program": "@INSTROOT@/program/soffice.bin", 124 "args": [], 125 "stopAtEntry": false, 126 "cwd": "@BUILDDIR@", 127 "environment": [ 128 { 129 // added in disabled form for convenience/as an example 130 // (proper name is just SAL_LOG), 131 // see https://docs.libreoffice.org/sal/html/sal_log.html 132 "name": "SAL_LOG_DISABLED", 133 "value": "+INFO.ucb+WARN" 134 } 135 ], 136 "externalConsole": false, 137 "MIMode": "gdb", 138 "setupCommands": [ 139 { 140 "description": "Enable prett-printing for gdb", 141 "text": "-enable-pretty-printing", 142 "ignoreFailures": true 143 } 144 ], 145 "linux": { 146 "miDebuggerPath": "/usr/libexec/gdb" 147 }, 148 "osx": { 149 "program": "@INSTROOT@/MacOS/soffice", 150 "MIMode": "lldb", 151 "setupCommands": [ 152 { 153 "description": "load helpers for for lldb", 154 "text": "command script import ${workspaceFolder:srcdir}/solenv/lldb/libreoffice/LO.py", 155 "ignoreFailures": false 156 } 157 ] 158 }, 159 "preLaunchTask": "full make" 160 }, 161 { 162 // FIXME: not happy here when creating the profile while running in debugger 163 // no problem passing the profile dir once it was launched outside debugger once, 164 // but clearing out the user-profile dir needs to be triggered manually 165 "name": "run in gdb with clear userprofile", 166 // "preLaunchTask": "remove profile-dir", 167 "type": "cppdbg", 168 "request": "launch", 169 "program": "@INSTROOT@/program/soffice.bin", 170 "args": [ 171 "-env:UserInstallation=file:///@WORKDIR@/vs-code-temporary-user-profile" 172 ], 173 "stopAtEntry": false, 174 "cwd": "@BUILDDIR@", 175 "environment": [ 176 { 177 "name": "SAL_LOG_DISABLED", 178 "value": "+INFO.ucb+WARN" 179 } 180 ], 181 "externalConsole": false, 182 "MIMode": "gdb", 183 "setupCommands": [ 184 { 185 "description": "Enable pretty-printing for gdb", 186 "text": "-enable-pretty-printing", 187 "ignoreFailures": true 188 } 189 ], 190 "linux": { 191 "miDebuggerPath": "/usr/libexec/gdb" 192 }, 193 "osx": { 194 "program": "@INSTROOT@/MacOS/soffice", 195 "MIMode": "lldb", 196 "setupCommands": [ 197 { 198 "description": "load helpers for for lldb", 199 "text": "command script import ${workspaceFolder:srcdir}/solenv/lldb/libreoffice/LO.py", 200 "ignoreFailures": false 201 } 202 ] 203 } 204 } 205 ], 206 "compounds": [] 207 } 208}