質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.50%
Java

Javaは、1995年にサン・マイクロシステムズが開発したプログラミング言語です。表記法はC言語に似ていますが、既存のプログラミング言語の短所を踏まえていちから設計されており、最初からオブジェクト指向性を備えてデザインされています。セキュリティ面が強力であることや、ネットワーク環境での利用に向いていることが特徴です。Javaで作られたソフトウェアは基本的にいかなるプラットフォームでも作動します。

Q&A

0回答

1722閲覧

vscodeからjavaが削除できない

tetsuya7724

総合スコア67

Java

Javaは、1995年にサン・マイクロシステムズが開発したプログラミング言語です。表記法はC言語に似ていますが、既存のプログラミング言語の短所を踏まえていちから設計されており、最初からオブジェクト指向性を備えてデザインされています。セキュリティ面が強力であることや、ネットワーク環境での利用に向いていることが特徴です。Javaで作られたソフトウェアは基本的にいかなるプラットフォームでも作動します。

0グッド

0クリップ

投稿2021/04/14 14:20

編集2022/01/12 10:55

前提・実現したいこと

vscodeからjavaを削除したいです。

以下のサイトを参考にjavaをインストールしました。
https://qiita.com/yaona_666/items/ef44ab886aab2c78ca51

javaをインストールしてvscodeを起動、しばらく放置して、コンソールを確認すると問題が28個も発生しました。おそらくインストールしたjavaに原因があると思うのでアンインストールをしたいです。
インストールしたJDKはjdk-15.0.2_osx-x64_bin.dmgです。

macに入っているjavaを確認すると以下のような結果が出ました。

(base) Apple-no-MacBook-Air:~ apple$ /usr/libexec/java_home -V Matching Java Virtual Machines (3): 15.0.2 (x86_64) "Oracle Corporation" - "Java SE 15.0.2" /Library/Java/JavaVirtualMachines/jdk-15.0.2.jdk/Contents/Home 1.8.261.12 (x86_64) "Oracle Corporation" - "Java" /Library/Internet Plug-Ins/JavaAppletPlugin.plugin/Contents/Home 1.8.0_261 (x86_64) "Oracle Corporation" - "Java SE 8" /Library/Java/JavaVirtualMachines/jdk1.8.0_261.jdk/Contents/Home /Library/Java/JavaVirtualMachines/jdk-15.0.2.jdk/Contents/Home

アンインストールをするために以下のように記入しました。

$ sudo rm -rf /Library/Java/JavaVirtualMachines/jdk-15.0.2.jpk

もう一度javaを確認すると全く同じ結果が表示されjavaがアンインストールができませんでした。

(base) Apple-no-MacBook-Air:~ apple$ /usr/libexec/java_home -V Matching Java Virtual Machines (3): 15.0.2 (x86_64) "Oracle Corporation" - "Java SE 15.0.2" /Library/Java/JavaVirtualMachines/jdk-15.0.2.jdk/Contents/Home 1.8.261.12 (x86_64) "Oracle Corporation" - "Java" /Library/Internet Plug-Ins/JavaAppletPlugin.plugin/Contents/Home 1.8.0_261 (x86_64) "Oracle Corporation" - "Java SE 8" /Library/Java/JavaVirtualMachines/jdk1.8.0_261.jdk/Contents/Home /Library/Java/JavaVirtualMachines/jdk-15.0.2.jdk/Contents/Home

vscodeを再起動をして再度同じ操作をしたのですが、結果は変わりませんでした。

試したこと

必要ないかもしれませんが、発生したエラーを載せて起きます。

イメージ説明
イメージ説明

defaultsettings.jsonに問題が表示されていましたので、対象のコードを記載します。

defaultsetting.json

1 // Optional working directory for tests. 2 "python.testing.cwd": null, 3 4 // Determines the type of connection for talking to jupyter. Local will start kernels locally. Remote allows for connections to remote servers 5 "jupyter.jupyterServerType": "", 6 7 // A series of Python instructions or iPython magic commands. Can be either an array of strings or a single string with commands separated by '\n'. Commands will be silently executed whenever the interactive window loads. For instance, set this to '%load_ext autoreload\n%autoreload 2' to automatically reload changes made to imported files without having to restart the interactive session. 8 "jupyter.runStartupCommands": "", 9 10 // Path to Maven's global settings.xml 11"java.configuration.maven.globalSettings": null, 12 13 // Path to Maven's user settings.xml "java.configuration.maven.userSettings": null, 14 15 // Preferred content provider (a 3rd party decompiler id, usually) 16 "java.contentProvider.preferred": null, 17 18 // Optional formatter profile name from the Eclipse formatter settings. 19 "java.format.settings.profile": null, 20 21 // Specifies the url or file path to the [Eclipse formatter xml settings](https://github.com/redhat-developer/vscode-java/wiki/Formatter-settings). 22 "java.format.settings.url": null, 23 24 // Arguments to pass to Gradle. 25 "java.import.gradle.arguments": null, 26 27 // Use Gradle from the specified local installation directory or GRADLE_HOME if the Gradle wrapper is missing or disabled and no 'java.import.gradle.version' is specified. 28 "java.import.gradle.home": null, 29 30 // The location to the JVM used to run the Gradle daemon. 31 "java.import.gradle.java.home": null, 32 33 // JVM arguments to pass to Gradle. 34 "java.import.gradle.jvmArguments": null, 35 36 // Setting for GRADLE_USER_HOME. 37 "java.import.gradle.user.home": null, 38 39 // Use Gradle from the specific version if the Gradle wrapper is missing or disabled. 40 "java.import.gradle.version": null, 41 42 // This the entry point of server when you're in multiroot workspace 43 "liveServer.settings.multiRootWorkspaceName": null, 44 45 // Specify the `connectionId` if you have defined multiple connections. 46 "sonarlint.connectedMode.project": {}, 47 48 // Custom empty elements in addition to the default HTML empty elements 49 "highlight-matching-tag.customEmptyElements": null, 50 51 // Decorations for opening and closing tags 52 "highlight-matching-tag.styles": null, 53 54 // Specifies whether you prefer to use Maven wrapper. If true, it tries using 'mvnw' by walking up the parent folders. If false, or 'mvnw' is not found, it tries 'mvn' in PATH instead. 55 "maven.executable.preferMavenWrapper": "true", 56 57 // If this value is true, add a command to create Maven Projects in the Explorer context menu for folders. 58 "maven.showInExplorerContextMenu": "true", 59 60 // Darkテーマ向けのデフォルトのファイルアイコンを指定します。 61 "vsicons.associations.fileDefault.file": null, 62 63 // Lightテーマ向けのデフォルトのファイルアイコンを指定します。 64 "vsicons.associations.fileDefault.file_light": null, 65 66 // Darkテーマ向けのデフォルトのフォルダアイコンを指定します。 67 "vsicons.associations.folderDefault.folder": null, 68 69 // Lightテーマ向けのデフォルトのフォルダアイコンを指定します。 70 "vsicons.associations.folderDefault.folder_light": null, 71 72 // Darkテーマ向けのデフォルトのルートフォルダアイコンを指定します。 73 "vsicons.associations.folderDefault.root_folder": null, 74 75 // Lightテーマ向けのデフォルトのルートフォルダアイコンを指定します。 76 "vsicons.associations.folderDefault.root_folder_light": null, 77

macOS Big Sur 11.2.3

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

mather

2021/04/14 16:25

質問者はパニックになっています。まずは落ち着いて手を止めて、しっかりと現在の状況を確認してください。 > コンソールを確認すると問題が28個も発生したので これは具体的には何のエラーですか? 画像を見る限り「コンソール」のエラーではなく、エディタが表示しているエラーのようです。 なんらかのファイルの行数のように見えますが、何をしているときに表示されたものなのかを質問に追記してください。 場合によっては、 Java 15 が原因ではないかもしれませんので。
tetsuya7724

2021/04/15 10:54

javaをインストールをしたあとに、vscodeを起動。そのまま放置をしているとエラーが表示されます。javaをインストールする前はエラーは発生していませんでした。
guest

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

まだ回答がついていません

会員登録して回答してみよう

アカウントをお持ちの方は

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.50%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問