From 2ac3533dd9657f0e80ac1c2726f39df8ceef3996 Mon Sep 17 00:00:00 2001 From: Mehdi Hadeli Date: Mon, 22 Jul 2024 10:00:15 +0000 Subject: [PATCH] build: change in the devcontainer --- .devcontainer/devcontainer.json | 65 +++++++++++++--------------- .devcontainer/scripts/post-create.sh | 0 .devcontainer/scripts/update.sh | 0 .vscode/settings.json | 49 +++++++++++++-------- 4 files changed, 62 insertions(+), 52 deletions(-) mode change 100644 => 100755 .devcontainer/scripts/post-create.sh mode change 100644 => 100755 .devcontainer/scripts/update.sh diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 3a549eb7..ab68833e 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -18,7 +18,7 @@ "features": { // https://github.com/devcontainers/features/tree/main/src/go "ghcr.io/devcontainers/features/go:1": { - "version": "1.22" + "version": "1.22" }, // https://github.com/devcontainers/features/tree/main/src/github-cli "ghcr.io/devcontainers/features/github-cli:1": { @@ -58,7 +58,7 @@ "resmon.show.cpufreq": false, "omnisharp.projectLoadTimeout": 60, "workbench.colorTheme": "Visual Studio Light", - "workbench.iconTheme": "material-icon-theme", + "workbench.iconTheme": "vscode-icons", "editor.minimap.enabled": false, "editor.fontFamily": "'MesloLGM Nerd Font', 'Droid Sans Mono', 'monospace', 'Droid Sans Fallback', 'Consolas'", "editor.fontSize": 14, @@ -67,52 +67,49 @@ "terminal.integrated.defaultProfile.linux": "zsh", "powershell.cwd": "~", "terminal.external.windowsExec": "%LOCALAPPDATA%\\Microsoft\\WindowsApps\\pwsh.exe", - "go.buildTags": "", - "go.toolsEnvVars": { - "CGO_ENABLED": "0" - }, - "go.useLanguageServer": true, - "go.testEnvVars": { - "CGO_ENABLED": "1" - }, - "go.testFlags": [ - "-v", - "-race" - ], - "go.testTimeout": "10s", - "go.coverOnSingleTest": true, - "go.coverOnSingleTestFile": true, - "go.coverOnTestPackage": true, - "go.lintOnSave": "package", - "[go]": { - "editor.codeActionsOnSave": { - "source.organizeImports": "always" - } - }, - "gopls": { - "usePlaceholders": false, - "staticcheck": true - }, + "go.buildTags": "", + "go.toolsEnvVars": { + "CGO_ENABLED": "0" + }, + "go.testEnvVars": { + "CGO_ENABLED": "1" + }, + "go.testTimeout": "10s", + "go.coverOnSingleTest": true, + "go.coverOnSingleTestFile": true, + "go.coverOnTestPackage": true, + "[go]": { + "editor.codeActionsOnSave": { + "source.organizeImports": "always" + } + }, + "gopls": { + "usePlaceholders": false, + "staticcheck": true + }, "go.lintTool": "golangci-lint", "go.lintFlags": ["--fast"], "go.lintOnSave": "package", "go.testFlags": ["-failfast", "-v"], "go.toolsManagement.autoUpdate": true, "go.useLanguageServer": true, - "go.formatTool": "gofumpt" + "go.formatTool": "gofumpt", + "[jsonc]": { + "editor.defaultFormatter": "esbenp.prettier-vscode" + } }, "extensions": [ - "golang.Go", - "esbenp.prettier-vscode", + "golang.Go", + "esbenp.prettier-vscode", "streetsidesoftware.code-spell-checker", - "vscode-icons-team.vscode-icons", - "redhat.vscode-yaml", // Kubernetes, + "vscode-icons-team.vscode-icons", + "redhat.vscode-yaml", // Kubernetes, "mutantdino.resourcemonitor", "humao.rest-client", "dzhavat.bracket-pair-toggler", "ms-azuretools.vscode-docker", "vivaxy.vscode-conventional-commits", - "IBM.output-colorizer", // Colorize your output/test logs + "IBM.output-colorizer", // Colorize your output/test logs "emmanuelbeziat.vscode-great-icons", "ms-vscode.vs-keybindings", "GitHub.vscode-github-actions", diff --git a/.devcontainer/scripts/post-create.sh b/.devcontainer/scripts/post-create.sh old mode 100644 new mode 100755 diff --git a/.devcontainer/scripts/update.sh b/.devcontainer/scripts/update.sh old mode 100644 new mode 100755 diff --git a/.vscode/settings.json b/.vscode/settings.json index 09ed86c1..cd21ecb8 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -5,10 +5,36 @@ "editor.suggest.snippetsPreventQuickSuggestions": false, "explorer.autoReveal": true, "resmon.show.cpufreq": false, - "dotnet.server.startTimeout": 60000, "omnisharp.projectLoadTimeout": 60, + "workbench.colorTheme": "Visual Studio Light", + "workbench.iconTheme": "vscode-icons", + "editor.minimap.enabled": false, + "editor.fontFamily": "'MesloLGM Nerd Font', 'Droid Sans Mono', 'monospace', 'Droid Sans Fallback', 'Consolas'", + "editor.fontSize": 14, + "explorer.confirmDelete": false, + "terminal.integrated.defaultProfile.windows": "PowerShell", + "terminal.integrated.defaultProfile.linux": "zsh", + "powershell.cwd": "~", + "terminal.external.windowsExec": "%LOCALAPPDATA%\\Microsoft\\WindowsApps\\pwsh.exe", + "go.buildTags": "", + "go.toolsEnvVars": { + "CGO_ENABLED": "0" + }, + "go.testEnvVars": { + "CGO_ENABLED": "1" + }, + "go.testTimeout": "10s", + "go.coverOnSingleTest": true, + "go.coverOnSingleTestFile": true, + "go.coverOnTestPackage": true, + "[go]": { + "editor.codeActionsOnSave": { + "source.organizeImports": "always" + } + }, "gopls": { - "ui.semanticTokens": true + "usePlaceholders": false, + "staticcheck": true }, "go.lintTool": "golangci-lint", "go.lintFlags": ["--fast"], @@ -17,20 +43,7 @@ "go.toolsManagement.autoUpdate": true, "go.useLanguageServer": true, "go.formatTool": "gofumpt", - "workbench.colorTheme": "Visual Studio Light", - "workbench.iconTheme": "material-icon-theme", - "editor.minimap.enabled": false, - "terminal.integrated.fontFamily": "MesloLGM Nerd Font", - "terminal.integrated.defaultProfile.windows": "PowerShell", - "terminal.integrated.defaultProfile.linux": "zsh", - "powershell.cwd": "~", - "terminal.external.windowsExec": "%LOCALAPPDATA%\\Microsoft\\WindowsApps\\pwsh.exe", - "explorer.confirmDelete": false, - "remote.autoForwardPortsSource": "hybrid", - "go.inlayHints.assignVariableTypes": true, - "go.inlayHints.compositeLiteralFields": true, - "go.inlayHints.compositeLiteralTypes": true, - "go.inlayHints.constantValues": true, - "go.inlayHints.functionTypeParameters": true, - "go.inlayHints.rangeVariableTypes": true + "[jsonc]": { + "editor.defaultFormatter": "esbenp.prettier-vscode" + } }