修改readme

This commit is contained in:
xiayuqi 2024-09-30 14:24:17 +08:00
parent 801f7e69cf
commit dd61769037
1 changed files with 23 additions and 32 deletions

View File

@ -1,11 +1,9 @@
[中文](#中文描述)|[English](#englishdescription)
# 中文描述
[![Gitter](https://badges.gitter.im/Microsoft/vscode-java-debug.svg)](https://gitter.im/Microsoft/vscode-java-debug)
[![GitHub Actions](https://img.shields.io/github/workflow/status/microsoft/vscode-java-debug/CI/master)](https://github.com/microsoft/vscode-java-debug/actions?query=workflow%3ACI+branch%3Amaster)
## 概述
这是一个基于 [Java Debug Server](https://github.com/Microsoft/java-debug) 的轻量级 Java 调试器,它扩展了 [Red Hat 的 Java 语言支持](https://marketplace.visualstudio.com/items?itemName=redhat.java)。它允许用户使用 Visual Studio Code (VS Code) 调试 Java 代码。以下是其功能列表:
这是一个基于 [Java Debug Server](https://github.com/Microsoft/java-debug) 的轻量级 Java 调试器,它扩展了 [Red Hat 的 Java 语言支持](https://marketplace.visualstudio.com/items?itemName=redhat.java)。它允许用户使用 IDE调试 Java 代码。以下是其功能列表:
1. 支持 Java 8 和 11。
2. 支持远程调试。
@ -28,14 +26,14 @@
**要求**
- JDK版本 1.8.0 或更高版本)
- VS Code(版本 1.19.0 或更高版本)
- IDE(版本 1.19.0 或更高版本)
- [Java 语言支持插件KylinID 团队)](https://open-vsx.org/search=kylinideteam.java)
安装
打开VS Code,按下`F1`键或同时按下`Ctrl`和`Shift`键再按`P`键打开命令面板选择“安装扩展程序”然后输入“kylinideteam.vscode-java-debug”。
打开IDE,按下`F1`键或同时按下`Ctrl`和`Shift`键再按`P`键打开命令面板选择“安装扩展程序”然后输入“kylinideteam.vscode-java-debug”。
或者按下“Ctrl + P”启动VS Code Quick Open粘贴以下命令然后按回车键。
或者按下“Ctrl + P”启动IDE Quick Open粘贴以下命令然后按回车键。
```bash
ext install kylinideteam.vscode-java-debug
``````
@ -82,7 +80,7 @@ form.addEventListener('submit' function(event) {
5. 将 `https//api.example.com/endpoint` 替换为您的 API 的 URL。
6. 运行页面,输入一些文本,然后单击提交按钮。您的文本将被发送到您的 API并且您将在页面上收到成功或错误消息。
- 启动VS Code
- 启动IDE
- 打开Java项目Maven/Gradle/Eclipse/单个Java文件
- 打开Java文件以激活扩展程序
- 按下`F5`键
@ -121,20 +119,18 @@ form.addEventListener('submit' function(event) {
- `envFile` - 包含环境变量定义的文件的绝对路径。
- `stopOnEntry` - 程序启动后自动暂停。
- `console` - 要启动程序的指定控制台。如果不指定,则使用由`java.debug.settings.console`用户设置指定的控制台。
- `internalConsole` - VS Code调试控制台(不支持输入流)。
- `integratedTerminal` - VS Code集成终端。
- `internalConsole` - IDE调试控制台(不支持输入流)。
- `integratedTerminal` - IDE集成终端。
- `externalConsole` - 外部控制台。
# Englishdescription
# Debugger for Java
[![Gitter](https://badges.gitter.im/Microsoft/vscode-java-debug.svg)](https://gitter.im/Microsoft/vscode-java-debug)
[![GitHub Actions](https://img.shields.io/github/workflow/status/microsoft/vscode-java-debug/CI/master)](https://github.com/microsoft/vscode-java-debug/actions?query=workflow%3ACI+branch%3Amaster)
Modified based on the version 0.46 of vscode-java-debug
## Overview
A lightweight Java Debugger based on [Java Debug Server](https://github.com/Microsoft/java-debug) which extends the [Language Support for Java by Red Hat](https://marketplace.visualstudio.com/items?itemName=redhat.java). It allows users to debug Java code using Visual Studio Code (VS Code). Here's a list of features:
A lightweight Java Debugger based on [Java Debug Server](https://github.com/Microsoft/java-debug) which extends the [Language Support for Java by Red Hat](https://marketplace.visualstudio.com/items?itemName=redhat.java). It allows users to debug Java code using IDE. Here's a list of features:
- Launch/Attach
- Breakpoints/Conditional Breakpoints/Logpoints
@ -150,21 +146,21 @@ A lightweight Java Debugger based on [Java Debug Server](https://github.com/Micr
## Requirements
- JDK (version 1.8.0 or later)
- VS Code (version 1.19.0 or later)
- IDE (version 1.19.0 or later)
- [Language Support for Java](https://open-vsx.org/?search=kylinideteam.java)
## Install
Open VS Code and press `F1` or `Ctrl + Shift + P` to open command palette, select **Install Extension** and type `kylinideteam.vscode-java-debug`.
Open IDE and press `F1` or `Ctrl + Shift + P` to open command palette, select **Install Extension** and type `kylinideteam.vscode-java-debug`.
Or launch VS Code Quick Open (`Ctrl + P`), paste the following command, and press enter.
Or launch IDE Quick Open (`Ctrl + P`), paste the following command, and press enter.
```bash
ext install kylinideteam.vscode-java-debug
```
## Use
- Launch VS Code
- Launch IDE
- Open a Java project (Maven/Gradle/Eclipse/Single Java file)
- Open a Java file to activate the extensions
- Press `F5`
@ -204,8 +200,8 @@ Please also check the documentation of [Language Support for Java](https://open-
- `envFile` - Absolute path to a file containing environment variable definitions.
- `stopOnEntry` - Automatically pause the program after launching.
- `console` - The specified console to launch the program. If not specified, use the console specified by the `java.debug.settings.console` user setting.
- `internalConsole` - VS Code debug console (input stream not supported).
- `integratedTerminal` - VS Code integrated terminal.
- `internalConsole` - IDE debug console (input stream not supported).
- `integratedTerminal` - IDE integrated terminal.
- `externalTerminal` - External terminal that can be configured in user settings.
- `shortenCommandLine` - When the project has long classpath or big VM arguments, the command line to launch the program may exceed the maximum command line string limitation allowed by the OS. This configuration item provides multiple approaches to shorten the command line. Defaults to `auto`.
- `none` - Launch the program with the standard command line 'java [options] classname [args]'.
@ -246,7 +242,7 @@ Please also check the documentation of [Language Support for Java](https://open-
### User Settings
- `java.debug.logLevel`: minimum level of debugger logs that are sent to VS Code, defaults to `warn`.
- `java.debug.logLevel`: minimum level of debugger logs that are sent to IDE, defaults to `warn`.
- `java.debug.settings.showHex`: show numbers in hex format in "Variables" viewlet, defaults to `false`.
- `java.debug.settings.showStaticVariables`: show static variables in "Variables" viewlet, defaults to `false`.
- `java.debug.settings.showQualifiedNames`: show fully qualified class names in "Variables" viewlet, defaults to `false`.
@ -254,7 +250,7 @@ Please also check the documentation of [Language Support for Java](https://open-
- `java.debug.settings.showToString`: show 'toString()' value for all classes that override 'toString' method in "Variables" viewlet, defaults to `true`.
- `java.debug.settings.maxStringLength`: the maximum length of string displayed in "Variables" or "Debug Console" viewlet, the string longer than this length will be trimmed, defaults to `0` which means no trim is performed.
- `java.debug.settings.numericPrecision`: the precision when formatting doubles in "Variables" or "Debug Console" viewlet.
- `java.debug.settings.hotCodeReplace`: Reload the changed Java classes during debugging, defaults to `manual`. Make sure `java.autobuild.enabled` is not disabled for [VSCode Java](https://github.com/redhat-developer/vscode-java). See the [wiki page](https://github.com/Microsoft/vscode-java-debug/wiki/Hot-Code-Replace) for more information about usages and limitations.
- `java.debug.settings.hotCodeReplace`: Reload the changed Java classes during debugging, defaults to `manual`. Make sure `java.autobuild.enabled` is not disabled for [VSCode Java](https://github.com/redhat-developer/vscode-java).
- `manual` - Click the toolbar to apply the changes.
- `auto` - Automatically apply the changes after compilation.
- `never` - Never apply the changes.
@ -262,8 +258,8 @@ Please also check the documentation of [Language Support for Java](https://open-
- `java.debug.settings.forceBuildBeforeLaunch`: force building the workspace before launching java program, defaults to `true`.
- `java.debug.settings.onBuildFailureProceed`: Force to proceed when build fails, defaults to false.
- `java.debug.settings.console`: The specified console to launch Java program, defaults to `integratedTerminal`. If you want to customize the console for a specific debug session, please modify the 'console' config in launch.json.
- `internalConsole` - VS Code debug console (input stream not supported).
- `integratedTerminal` - VS Code integrated terminal.
- `internalConsole` - IDE debug console (input stream not supported).
- `integratedTerminal` - IDE integrated terminal.
- `externalTerminal` - External terminal that can be configured in user settings.
- `java.debug.settings.exceptionBreakpoint.skipClasses`: Skip the specified classes when breaking on exception.
- `$JDK` - Skip the JDK classes from the default system bootstrap classpath, such as rt.jar, jrt-fs.jar.
@ -280,27 +276,22 @@ Please also check the documentation of [Language Support for Java](https://open-
- `java.debug.settings.stepping.skipConstructors`: Skip constructor methods when stepping.
- `java.debug.settings.jdwp.limitOfVariablesPerJdwpRequest`: The maximum number of variables or fields that can be requested in one JDWP request. The higher the value, the less frequently debuggee will be requested when expanding the variable view. Also a large number can cause JDWP request timeout. Defaults to 100.
- `java.debug.settings.jdwp.requestTimeout`: The timeout (ms) of JDWP request when the debugger communicates with the target JVM. Defaults to 3000.
- `java.debug.settings.jdwp.async`: Experimental: Controls whether the debugger is allowed to send JDWP commands asynchronously. Async mode can improve remote debugging response speed on high-latency networks. Defaults to `auto`, and automatically enable async mode in VS Code - Insiders.
- `java.debug.settings.jdwp.async`: Experimental: Controls whether the debugger is allowed to send JDWP commands asynchronously. Async mode can improve remote debugging response speed on high-latency networks. Defaults to `auto`, and automatically enable async mode in IDE - Insiders.
- `auto` (Default)
- `on`
- `off`
- `java.debug.settings.vmArgs`: The default VM arguments to launch the Java program. Eg. Use '-Xmx1G -ea' to increase the heap size to 1GB and enable assertions. If you want to customize the VM arguments for a specific debug session, please modify the 'vmArgs' config in launch.json.
- `java.silentNotification`: Controls whether notifications can be used to report progress. If true, use status bar to report progress instead. Defaults to `false`.
> Pro Tip: The documentation [Configuration.md](https://github.com/microsoft/vscode-java-debug/blob/master/Configuration.md) provides lots of samples to demonstrate how to use these debug configurations, recommend to take a look.
> Pro Tip: The documentation [Configuration.md](https://gitee.com/openkylin/vscode-java-debug/blob/master/Configuration.md) provides lots of samples to demonstrate how to use these debug configurations, recommend to take a look.
## Troubleshooting
Reference the [Troubleshooting Guide](https://github.com/Microsoft/vscode-java-debug/blob/master/Troubleshooting.md) for common errors.
Reference the [Troubleshooting Guide for Encoding Issues](https://github.com/Microsoft/vscode-java-debug/blob/master/Troubleshooting_encoding.md) for encoding issues.
## Contributing
If you are interested in fixing issues and contributing directly to the code base, please see the document [How to Contribute](https://github.com/microsoft/vscode-java-debug/blob/main/CONTRIBUTING.md).
If you are interested in fixing issues and contributing directly to the code base, please see the document [How to Contribute](https://gitee.com/openkylin/vscode-java-debug/blob/master/CONTRIBUTING.md).
## Feedback and Questions
You can find the full list of issues at [Issue Tracker](https://github.com/Microsoft/vscode-java-debug/issues). You can submit a [bug or feature suggestion](https://github.com/Microsoft/vscode-java-debug/issues/new), and participate community driven [![Gitter](https://badges.gitter.im/Microsoft/vscode-java-debug.svg)](https://gitter.im/Microsoft/vscode-java-debug)
You can find the full list of issues at [Issue Tracker](https://gitee.com/openkylin/vscode-java-debug/issues).
## License
This extension is licensed under [MIT License](https://github.com/Microsoft/vscode-java-debug/blob/master/LICENSE.txt).
This extension is licensed under [MIT License](https://gitee.com/openkylin/vscode-java-debug/blob/master/LICENSE.txt).
## Data/Telemetry
VS Code collects usage data and sends it to Microsoft to help improve our products and services. Read our [privacy statement](https://go.microsoft.com/fwlink/?LinkID=528096&clcid=0x409) to learn more. If you don't wish to send usage data to Microsoft, you can set the `telemetry.telemetryLevel` setting to `"off"`. Learn more in our [FAQ](https://code.visualstudio.com/docs/supporting/faq#_how-to-disable-telemetry-reporting).