From fe0d2dbb88d453c5e450033a73405ccaded3abc1 Mon Sep 17 00:00:00 2001 From: Mattt Date: Sat, 24 Feb 2024 02:23:05 -0800 Subject: [PATCH] Update VSCode workspace settings (#1545) * Update code actions on save Signed-off-by: Mattt Zmuda * Update setting key to ruff.lint.args Signed-off-by: Mattt Zmuda * Remove python.linting settings All settings starting with "python.linting." are deprecated and can be removed from settings. Signed-off-by: Mattt Zmuda * Use vscode.json-language-features to format JSON Signed-off-by: Mattt Zmuda * Remove prettier and black from recommended extensions Signed-off-by: Mattt Zmuda --------- Signed-off-by: Mattt Zmuda --- .vscode/extensions.json | 2 -- .vscode/settings.json | 24 ++++++++++++++---------- 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/.vscode/extensions.json b/.vscode/extensions.json index 4256f9a5b..6cb2787d6 100644 --- a/.vscode/extensions.json +++ b/.vscode/extensions.json @@ -1,9 +1,7 @@ { "recommendations": [ "charliermarsh.ruff", - "esbenp.prettier-vscode", "golang.go", - "ms-python.black-formatter", "ms-python.python", "ms-python.vscode-pylance" ] diff --git a/.vscode/settings.json b/.vscode/settings.json index a8853f26e..f78872832 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -13,27 +13,31 @@ "go.lintTool": "golangci-lint", "go.formatTool": "goimports", "go.testOnSave": true, - "gopls": { "formatting.local": "github.com/replicate/cog" }, + "gopls": { + "formatting.local": "github.com/replicate/cog" + }, "[json]": { - "editor.defaultFormatter": "esbenp.prettier-vscode" + "editor.defaultFormatter": "vscode.json-language-features" }, "[jsonc]": { - "editor.defaultFormatter": "esbenp.prettier-vscode" + "editor.defaultFormatter": "vscode.json-language-features" }, "[python]": { "editor.formatOnSave": true, "editor.codeActionsOnSave": { - "source.fixAll": true, - "source.organizeImports": true + "source.fixAll": "explicit", + "source.organizeImports": "explicit" }, "editor.defaultFormatter": "charliermarsh.ruff" }, "python.languageServer": "Pylance", - "python.testing.pytestArgs": ["-vvv", "python"], + "python.testing.pytestArgs": [ + "-vvv", + "python" + ], "python.testing.unittestEnabled": false, "python.testing.pytestEnabled": true, - "python.formatting.provider": "black", - "python.linting.mypyEnabled": true, - "python.linting.mypyArgs": ["--show-column-numbers", "--no-pretty"], - "ruff.args": ["--config=pyproject.toml"] + "ruff.lint.args": [ + "--config=pyproject.toml" + ] }