Skip to content

Commit

Permalink
Update devcontainer settings
Browse files Browse the repository at this point in the history
  • Loading branch information
sualeh committed Aug 11, 2024
1 parent 3a3b82b commit c0b4867
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 41 deletions.
8 changes: 1 addition & 7 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
FROM mcr.microsoft.com/devcontainers/java:8

ARG MAVEN_VERSION=""
RUN \
su vscode -c "umask 0002 && \
. /usr/local/sdkman/bin/sdkman-init.sh && \
sdk install maven \"${MAVEN_VERSION}\""
FROM mcr.microsoft.com/devcontainers/java:21

RUN \
apt-get update && \
Expand Down
49 changes: 16 additions & 33 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,37 +8,20 @@
"NODE_VERSION": "none"
}
},
"settings": {
"workbench.startupEditor": "none",
"java.home": "/docker-java-home",
"java.import.gradle.java.home": "/usr/local/sdkman/candidates/java/current",
"java.configuration.runtimes": [
{
"default": true,
"name": "JavaSE-1.8",
"path": "/usr/local/sdkman/candidates/java/current"
}
],
"files.exclude": {
"workspace": true
},
"java.configuration.updateBuildConfiguration": "automatic",
"java.format.settings.profile": "GoogleStyle",
"java.format.settings.url": "https://raw.githubusercontent.com/google/styleguide/gh-pages/eclipse-java-google-style.xml",
"editor.tabSize": 2,
"editor.foldingImportsByDefault": true,
"files.trimTrailingWhitespace": true,
"git.enableCommitSigning": true
"features": {
"ghcr.io/devcontainers/features/java:1": {
"version": "21"
}
},
"customizations": {
"vscode": {
"extensions": [
"vscjava.vscode-java-pack",
"vscjava.vscode-maven",
"vscjava.vscode-java-test",
"editorconfig.editorconfig"
]
}
},
"extensions": [
"vscjava.vscode-java-pack",
"shengchen.vscode-checkstyle",
"editorconfig.editorconfig",
"pivotal.vscode-boot-dev-pack",
"pivotal.vscode-spring-boot",
"redhat.vscode-xml",
"jebbs.markdown-extended",
"davidanson.vscode-markdownlint"
],
"remoteUser": "vscode"
}
"postCreateCommand": "mvn clean install"
}
5 changes: 4 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
{
"github.codespaces.defaultExtensions": [
"vscjava.vscode-java-pack",
"vscjava.vscode-maven",
"vscjava.vscode-java-test",
"editorconfig.editorconfig",
"GitHub.codespaces",
"GitHub.vscode-pull-request-github"
],
"editor.tabSize": 2,
"scm.showActionButton": false,
"java.compile.nullAnalysis.mode": "automatic",
"java.jdt.ls.vmargs": "-XX:+UseParallelGC -XX:GCTimeRatio=4 -XX:AdaptiveSizePolicyWeight=90 -Dsun.zip.disableMemoryMapping=true -Xmx2G -Xms100m -Xlog:disable"
}
}

0 comments on commit c0b4867

Please sign in to comment.