diff --git a/.gitignore b/.gitignore index 17c0d2d..25db4df 100644 --- a/.gitignore +++ b/.gitignore @@ -229,6 +229,5 @@ pyrightconfig.json # Custom rules (everything added below won't be overriden by 'Generate .gitignore File' if you use 'Update' option) -.vscode .idea bundles diff --git a/.vscode/launch.json b/.vscode/launch.json new file mode 100644 index 0000000..285ffec --- /dev/null +++ b/.vscode/launch.json @@ -0,0 +1,25 @@ +{ + "version": "0.2.0", + "configurations": [ + { + "name": "Python (Poetry): Current File", + "type": "python", + "request": "launch", + "module": "${input:PythonModuleName}", + "console": "integratedTerminal", + "justMyCode": true + } + ], + "inputs": [ + { + "id": "PythonModuleName", + "type": "command", + "command": "extension.commandvariable.transform", + "args": { + "text": "${command:extension.commandvariable.file.relativeFileDotsNoExtension}", + "find": "src\\.(.*)", + "replace": "$1", + } + } + ] +} \ No newline at end of file diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..900a654 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,16 @@ +{ + "statusbar_command.commands": [ + { + "id": "poetry_run_file", + "name": "Python (Poetry): Run file", + "text": "$(run-all) Run file (Poetry)", + "tooltip": "workspace settings", + "alignment": "left", + "command": "workbench.action.tasks.runTask", + "arguments": [ + "PythonPoetryCurrentFile" + ], + "color": "#AFD5FB", + }, + ], +} \ No newline at end of file diff --git a/.vscode/tasks.json b/.vscode/tasks.json new file mode 100644 index 0000000..e022a97 --- /dev/null +++ b/.vscode/tasks.json @@ -0,0 +1,36 @@ +{ + "version": "2.0.0", + "tasks": [ + { + "label": "PythonPoetryCurrentFile", + "type": "process", + "presentation": { + "echo": true, + "reveal": "always", + "focus": false, + "panel": "shared", + "showReuseMessage": true, + "clear": true + }, + "command": "poetry", + "args": [ + "run", + "python", + "-m", + "${input:PythonModuleName}" + ] + } + ], + "inputs": [ + { + "id": "PythonModuleName", + "type": "command", + "command": "extension.commandvariable.transform", + "args": { + "text": "${command:extension.commandvariable.file.relativeFileDotsNoExtension}", + "find": "src\\.(.*)", + "replace": "$1", + } + } + ] +} \ No newline at end of file