refactor vscode config and add some more configuration options and extensions
This commit is contained in:
parent
47d084f852
commit
e78602199d
1 changed files with 23 additions and 16 deletions
|
@ -38,21 +38,21 @@ rec {
|
|||
];
|
||||
|
||||
programs.vscode =
|
||||
let
|
||||
vscode = inputs.nix-vscode-extensions.extensions.${system}.vscode-marketplace;
|
||||
vscode-release = inputs.nix-vscode-extensions.extensions.${system}.vscode-marketplace-release;
|
||||
in
|
||||
# vsx = inputs.nix-vscode-extensions.extensions.${system}.open-vsx;
|
||||
# vsx-release = inputs.nix-vscode-extensions.extensions.${system}.open-vsx-release;
|
||||
{
|
||||
enable = true;
|
||||
enableUpdateCheck = false;
|
||||
enableExtensionUpdateCheck = false;
|
||||
package = pkgs.vscode;
|
||||
# package = pkgs.vscode.fhsWithPackages (
|
||||
# ps: with pkgs; [
|
||||
# dotnetCorePackages.sdk_8_0
|
||||
# jdk21
|
||||
# go
|
||||
# ]
|
||||
# );
|
||||
extensions =
|
||||
with inputs.nix-vscode-extensions.extensions.${system}.vscode-marketplace;
|
||||
with inputs.nix-vscode-extensions.extensions.${system}.vscode-marketplace-release;
|
||||
# In `with A; with B;`, the attributes of `B` shadow the attributes of `A`
|
||||
with vscode;
|
||||
with vscode-release;
|
||||
[
|
||||
# Themes
|
||||
(pkgs.catppuccin-vsc.override {
|
||||
|
@ -92,10 +92,9 @@ rec {
|
|||
|
||||
# Python
|
||||
ms-python.python
|
||||
ms-python.vscode-pylance
|
||||
detachhead.basedpyright # Pylance replacement
|
||||
ms-python.debugpy
|
||||
ms-python.black-formatter
|
||||
ms-python.mypy-type-checker
|
||||
charliermarsh.ruff
|
||||
|
||||
# JavaScript / TypeScript
|
||||
|
@ -168,6 +167,7 @@ rec {
|
|||
tboby.paradox-syntax
|
||||
xteal.mcmeta
|
||||
footerman.heracles-support
|
||||
nico-castell.linux-desktop-file
|
||||
|
||||
# Misc - Debuggers
|
||||
firefox-devtools.vscode-firefox-debug
|
||||
|
@ -190,8 +190,6 @@ rec {
|
|||
vasubasraj.flashpost
|
||||
adpyke.codesnap
|
||||
elypia.magick-image-reader
|
||||
adpyke.vscode-sql-formatter
|
||||
qwtel.sqlite-viewer
|
||||
yy0931.vscode-sqlite3-editor
|
||||
leonardssh.vscord
|
||||
alefragnani.project-manager
|
||||
|
@ -204,6 +202,7 @@ rec {
|
|||
ms-vscode.remote-explorer
|
||||
pkgs.vscode-extensions.ms-vscode-remote.remote-containers
|
||||
ms-vscode.remote-repositories
|
||||
tailscale.vscode-tailscale
|
||||
formulahendry.auto-rename-tag
|
||||
prunoideae.probejs
|
||||
d-koppenhagen.file-tree-to-text-generator
|
||||
|
@ -284,7 +283,6 @@ rec {
|
|||
};
|
||||
"[python]" = {
|
||||
"editor.formatOnType" = true;
|
||||
"editor.formatOnSave" = true;
|
||||
"editor.defaultFormatter" = "charliermarsh.ruff";
|
||||
"editor.codeActionsOnSave" = {
|
||||
"source.fixAll" = "explicit";
|
||||
|
@ -299,14 +297,12 @@ rec {
|
|||
"python.terminal.activateEnvInCurrentTerminal" = false;
|
||||
"[csharp]" = {
|
||||
"editor.defaultFormatter" = "csharpier.csharpier-vscode";
|
||||
"editor.formatOnSave" = true;
|
||||
"editor.formatOnSaveMode" = "file";
|
||||
};
|
||||
"[typescript]" = {
|
||||
"editor.defaultFormatter" = "esbenp.prettier-vscode";
|
||||
"editor.formatOnType" = false;
|
||||
"editor.formatOnPaste" = true;
|
||||
"editor.formatOnSave" = true;
|
||||
"editor.formatOnSaveMode" = "file";
|
||||
"files.autoSave" = "onFocusChange";
|
||||
};
|
||||
|
@ -466,6 +462,17 @@ rec {
|
|||
"github.copilot.enable" = {
|
||||
"markdown" = true;
|
||||
};
|
||||
"extensions.autoUpdate" = false;
|
||||
"python.analysis.generateWithTypeAnnotation" = true;
|
||||
"python.analysis.autoFormatStrings" = true;
|
||||
"python.analysis.autoImportCompletions" = true;
|
||||
"python.analysis.completeFunctionParens" = true;
|
||||
"python.analysis.diagnosticMode" = "workspace";
|
||||
"python.analysis.supportDocstringTemplate" = true;
|
||||
"python.analysis.typeEvaluation.enableReachabilityAnalysis" = true;
|
||||
"python.analysis.typeEvaluation.strictDictionaryInference" = true;
|
||||
"python.analysis.typeEvaluation.strictListInference" = true;
|
||||
"python.analysis.typeEvaluation.strictSetInference" = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue