Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
53 changes: 53 additions & 0 deletions docs/releases/v0.0.1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# Tomcat 0.0.1

## 中文

第一个版本:在 Lithe 里把 Java Web 项目放到你自己安装的 Tomcat 上运行和调试。

### 新功能

- **识别 Web 模块**:Maven `war` 模块、应用了 `war` 插件的 Gradle 模块、Eclipse Dynamic Web Project,以及带 `WEB-INF/web.xml` 的普通 Web 目录,每个模块在运行配置里有一项“Run on Tomcat”。
- **一键运行**:Maven 和 Gradle 模块先构建再部署,构建输出和 Tomcat 日志都显示在运行窗口;页面地址是 `http://localhost:<端口><上下文路径>/`。
- **原地运行**:Eclipse 项目和普通 Web 目录不打包,直接运行源目录,修改 JSP、HTML 后刷新页面即可看到。
- **调试**:选“调试”运行时,Lithe 用 Java Support 插件的 Java 调试器连接 Tomcat,可以在项目代码里下断点。
- **设置**:Tomcat 安装目录(留空时用环境变量 `CATALINA_HOME`)和 HTTP 端口(默认 8080,可按项目覆盖)。
- **不改动你的文件**:每个模块使用 Lithe 工作区状态目录里自己的 Tomcat 配置,Tomcat 安装目录、项目和插件包都只读。

### 使用前准备

- 自己安装 Tomcat 9 或 10.1,并在 设置 → 插件 → Tomcat 中选择安装目录。
- 调试需要另装 Java Support 插件;Java Support 用到的 Eclipse JDT 语言服务器按它的说明安装。

### 兼容性与已知问题

- 需要支持 `buildSystems` 0、`buildProviders` 0 和 `settings` 0 的 Lithe 桌面端;调试需要 0.8.4 及以后的桌面端。
- 0.8.5 及更早的桌面端:打开构建窗口后再修改 Tomcat 设置,要重新打开项目才生效;运行失败时只显示通用错误,看不到插件给出的原因。下一个桌面端版本修复([1lck/Lithe-IDEA#2145](https://github.com/1lck/Lithe-IDEA/pull/2145))。
- 插件给出的错误提示暂时只有英文,Lithe 还不能把界面语言告诉插件([1lck/Lithe-IDEA#2144](https://github.com/1lck/Lithe-IDEA/issues/2144))。
- 运行项名称“Run on Tomcat”暂时无法翻译([1lck/Lithe-IDEA#2139](https://github.com/1lck/Lithe-IDEA/issues/2139))。

---

## English

The first version: run and debug Java Web projects in Lithe on the Tomcat you installed.

### New features

- **Finds Web modules**: Maven `war` modules, Gradle modules that apply the `war` plugin, Eclipse Dynamic Web Projects, and plain Web folders with `WEB-INF/web.xml`; each gets a "Run on Tomcat" run configuration.
- **One-click run**: Maven and Gradle modules are built, then deployed; the build output and Tomcat's log appear in the Run window, and the page is at `http://localhost:<port><context path>/`.
- **Run in place**: Eclipse projects and plain Web folders run from their source folders without packaging, so a changed JSP or HTML file shows after a page refresh.
- **Debugging**: Debug connects the Java debugger of the Java Support plugin to Tomcat, so breakpoints in the project's code stop.
- **Settings**: the Tomcat installation (the `CATALINA_HOME` environment variable when empty) and the HTTP port (8080 by default, can be set per project).
- **Leaves your files alone**: each module runs with its own Tomcat configuration in Lithe's workspace state; the Tomcat installation, the project and the plugin package are only read.

### Before you start

- Install Tomcat 9 or 10.1 yourself and choose it in Settings → Plugins → Tomcat.
- Debugging needs the Java Support plugin; install the Eclipse JDT Language Server it uses as its instructions describe.

### Compatibility and known issues

- Needs a Lithe desktop that supports `buildSystems` 0, `buildProviders` 0 and `settings` 0; debugging needs desktop 0.8.4 or later.
- Desktop 0.8.5 and earlier: a Tomcat setting changed after the Build window opened applies only after reopening the project, and a failed run shows a generic error instead of the plugin's reason. Fixed for the next desktop release ([1lck/Lithe-IDEA#2145](https://github.com/1lck/Lithe-IDEA/pull/2145)).
- The plugin's error messages are in English for now, because Lithe cannot tell plugins the interface language yet ([1lck/Lithe-IDEA#2144](https://github.com/1lck/Lithe-IDEA/issues/2144)).
- The run configuration name "Run on Tomcat" cannot be translated yet ([1lck/Lithe-IDEA#2139](https://github.com/1lck/Lithe-IDEA/issues/2139)).
2 changes: 1 addition & 1 deletion e2e/host/lithe-host.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"./internal/workbench": "^TestTomcatPlugin(RunsAWebModule|DebugsAWebModule)$"
},
"requiredEnvironment": {
"LITHE_TEST_TOMCAT_PLUGIN_ARCHIVE": "tomcat-<version>-darwin.zip to install, for example dist/tomcat-0.1.0-darwin.zip",
"LITHE_TEST_TOMCAT_PLUGIN_ARCHIVE": "tomcat-<version>-darwin.zip to install, for example dist/tomcat-0.0.1-darwin.zip",
"LITHE_TEST_JAVA_PLUGIN_ARCHIVE": "Lithe-Java-Support-<version>-darwin-<arch>.zip from Lithe-IDEA/lithe-plugin-java releases; its java tool launches Tomcat and its java adapter debugs it",
"LITHE_TEST_TOMCAT_HOME": "an unpacked Tomcat, for example .artifacts/tomcat/apache-tomcat-10.1.62 from scripts/test/fetch-tomcat.mjs",
"JAVA_HOME": "a JDK 21 or later: the Java plugin's JDT language server, which runs its java debug adapter, refuses older JDKs; Tomcat also runs on it"
Expand Down
2 changes: 1 addition & 1 deletion io.github.lithe-idea.tomcat/plugin.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"schemaVersion": 0,
"id": "io.github.lithe-idea.tomcat",
"displayName": "Tomcat",
"version": "0.1.0",
"version": "0.0.1",
"pluginAPIVersion": 0,
"requires": {
"buildSystems": 0,
Expand Down
Loading