Skip to content

Commit

Permalink
Merge pull request #302 from QGIS-Contribution/tooling/update-vs-code…
Browse files Browse the repository at this point in the history
…-config

tooling: update VS Code configuration
  • Loading branch information
Guts authored Jan 10, 2024
2 parents dfc0501 + b7fcc48 commit 4564127
Show file tree
Hide file tree
Showing 3 changed files with 71 additions and 23 deletions.
11 changes: 11 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"recommendations": [
"ms-python.python",
"ms-python.black-formatter",
"ms-python.flake8",
"ms-python.isort",
"njpwerner.autodocstring",
"redhat.vscode-yaml",
"zhoufeng.pyqt-integration"
]
}
46 changes: 23 additions & 23 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,41 +1,41 @@
{
// Editor
"editor.bracketPairColorization.enabled": true,
"editor.codeActionsOnSave": {
"source.organizeImports": true
},
"editor.guides.bracketPairs": "active",
"editor.formatOnSave": true,
"editor.rulers": [
88
],
"editor.wordWrapColumn": 88,
"files.associations": {
"./requirements/*.txt": "pip-requirements",
"metadata.txt": "ini"
"metadata.txt": "ini",
"**/*.ts": "xml",
"**/*.ui": "xml"
},
// Python
"python.analysis.autoFormatStrings": true,
"python.analysis.typeCheckingMode": "basic",
"python.terminal.activateEnvInCurrentTerminal": true,
"python.terminal.activateEnvironment": true,
"[python]": {
"editor.defaultFormatter": "ms-python.black-formatter",
"editor.formatOnSave": true,
"editor.codeActionsOnSave": {
"source.organizeImports": "explicit"
},
"editor.rulers": [
88
],
"editor.wordWrapColumn": 88,
},
// Formatter
"python.formatting.provider": "black",
"python.formatting.blackArgs": [
"--target-version=py39"
],
// Linter
"python.linting.enabled": true,
"python.linting.flake8Enabled": true,
"python.linting.flake8Args": [
"--config=setup.cfg",
"--verbose"
],
"python.linting.pylintEnabled": false,
// Tests
"python.testing.pytestArgs": [],
"python.testing.unittestEnabled": false,
"python.testing.pytestEnabled": true,
// Git
"git.enableCommitSigning": true,
// Extensions
"autoDocstring.docstringFormat": "sphinx",
"autoDocstring.guessTypes": true,
"flake8.args": [
"--config=setup.cfg",
"--verbose"
],
"yaml.schemas": {
"https://json.schemastore.org/github-workflow.json": ".github/workflows/*.yml"
}
Expand Down
37 changes: 37 additions & 0 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
{
// See https://go.microsoft.com/fwlink/?LinkId=733558
// for the documentation about the tasks.json format
"version": "2.0.0",
"tasks": [
{
"label": "Upgrade dependencies - Development",
"type": "shell",
"osx": {
"command": "${config:python.pythonPath} -m pip install -U -r requirements/development.txt"
},
"windows": {
"command": "${config:python.pythonPath} -m pip install -U -r requirements/development.txt"
},
"linux": {
"command": "${config:python.pythonPath} -m pip install -U -r requirements/development.txt"
},
"problemMatcher": []
},
{
"label": "Translation Update",
"type": "shell",
"linux": {
"command": "pylupdate5 -verbose qgis_resource_sharing/resources/i18n/plugin_translation.pro"
},
"problemMatcher": []
},
{
"label": "Translation Compile",
"type": "shell",
"linux": {
"command": "lrelease qgis_resource_sharing/resources/i18n/*.ts "
},
"problemMatcher": []
}
]
}

0 comments on commit 4564127

Please sign in to comment.