дзеркало
https://github.com/l0ng-ai/openidea.git
синхронізовано 2026-12-05 17:47:08 +02:00
feat(build): add Build › Recompile for a single Java file (#5587)
Build › Recompile '<file>.java' (Shift+Cmd+F9 / Ctrl+Shift+F9, moved from Build Module, which keeps no default shortcut) compiles only the active Java file with javac and streams its output and diagnostics to the Build tool window. The menu, editor, tab and Project view entries name the file and are enabled only for local .java files. - Maven modules resolve the classpath of the file's scope (compile for main sources, test for test sources) through dependency:build-classpath; the probe is now cancellable. - Gradle projects get the source set's output, compile classpath, source folders and release from an init script. - Projects without a build tool compile against their Project Structure roots, outputs and libraries. - In a workspace the file's member project is used. - javac gets -g, omits an empty -cp, and uses -source/-target on JDK 8; localized javac error and warning prefixes are parsed. Co-authored-by: RuyimgByCN <[email protected]>
Цей коміт міститься в:
1 джерело
d729ae8122
коміт
748e5cee89
25 files changed
+1038
-150
No files matched your search
@@ -9,12 +9,13 @@ OpenIDEA does not have its own build system. It reads your build files, runs the
|
||||
|
||||
The **Build** menu works with every supported build system. OpenIDEA picks the build system of the project, or of the module that holds the current file.
|
||||
|
||||
| Action | macOS | Windows / Linux |
|
||||
| --------------------------------------------------- | ------ | --------------- |
|
||||
| **Build Project**: compile sources and tests | `⌘F9` | `Ctrl+F9` |
|
||||
| **Build Module**: compile the current file's module | `⌘⇧F9` | `Ctrl+Shift+F9` |
|
||||
| **Rebuild Project**: clean, then build | — | — |
|
||||
| **Build Artifacts**: package the outputs | — | — |
|
||||
| Action | macOS | Windows / Linux |
|
||||
| ------------------------------------------------------------ | ------ | --------------- |
|
||||
| **Build Project**: compile sources and tests | `⌘F9` | `Ctrl+F9` |
|
||||
| **Build Module**: compile the current file's module | — | — |
|
||||
| **Recompile '\<file\>.java'**: compile the current Java file | `⌘⇧F9` | `Ctrl+Shift+F9` |
|
||||
| **Rebuild Project**: clean, then build | — | — |
|
||||
| **Build Artifacts**: package the outputs | — | — |
|
||||
|
||||
What each action runs:
|
||||
|
||||
|
||||
@@ -9,12 +9,13 @@ OpenIDEA 没有自己的构建系统:它读取项目的构建文件,调用
|
||||
|
||||
**构建** 菜单适用于所有支持的构建系统。OpenIDEA 会根据项目(或当前文件所在模块)自动选择构建系统。
|
||||
|
||||
| 操作 | macOS | Windows / Linux |
|
||||
| ---------------------------------- | ------ | --------------- |
|
||||
| **构建项目**:编译源码和测试 | `⌘F9` | `Ctrl+F9` |
|
||||
| **构建模块**:编译当前文件所在模块 | `⌘⇧F9` | `Ctrl+Shift+F9` |
|
||||
| **重新构建项目**:先清理再构建 | — | — |
|
||||
| **构建工件**:打包产物 | — | — |
|
||||
| 操作 | macOS | Windows / Linux |
|
||||
| -------------------------------------------------- | ------ | --------------- |
|
||||
| **构建项目**:编译源码和测试 | `⌘F9` | `Ctrl+F9` |
|
||||
| **构建模块**:编译当前文件所在模块 | — | — |
|
||||
| **重新编译 '\<file\>.java'**:仅编译当前 Java 文件 | `⌘⇧F9` | `Ctrl+Shift+F9` |
|
||||
| **重新构建项目**:先清理再构建 | — | — |
|
||||
| **构建工件**:打包产物 | — | — |
|
||||
|
||||
各操作实际执行的命令:
|
||||
|
||||
|
||||
Reference in new issue
Заблокувати користувача