docs: add a landing page and a plugin marketplace to the documentation site (#4033)

/en and /zh open a landing page: the product in the dark theme, startup and
memory numbers, the main features, featured plugins and the default keymap.
The introduction pages move to /en/introduction and /zh/introduction.

/plugins and /zh/plugins list the marketplace's plugins with search,
category filters, sorting and a details dialog. The list is a snapshot of
plugins-index.json written by `pnpm gen:plugin-catalog`.
This commit is contained in:
l0ng-ai
2026-11-18 02:03:42 +08:00
committed by GitHub
parent 9cfe667b6a
commit c1782f01eb
14 changed files with 2289 additions and 92 deletions
+1
View File
@@ -9,6 +9,7 @@
"dist",
"target",
"src/bindings.ts",
"docs/snippets/plugin-catalog.jsx",
"evals/*/golden",
"src/editor/core/cm/angular/parser*.ts",
"src/editor/core/cm/jsp/parser*.ts",
+41 -2
View File
@@ -18,6 +18,10 @@
},
"navbar": {
"links": [
{
"label": "Marketplace",
"href": "/plugins"
},
{
"label": "GitHub",
"href": "https://github.com/l0ng-ai/openidea"
@@ -40,7 +44,14 @@
"groups": [
{
"group": "Get started",
"pages": ["en/index", "en/guide/install", "en/guide/quickstart", "en/guide/migrate", "en/roadmap"]
"pages": [
"en/index",
"en/introduction",
"en/guide/install",
"en/guide/quickstart",
"en/guide/migrate",
"en/roadmap"
]
},
{
"group": "Editing",
@@ -234,13 +245,37 @@
},
{
"language": "zh",
"navbar": {
"links": [
{
"label": "插件市场",
"href": "/zh/plugins"
},
{
"label": "GitHub",
"href": "https://github.com/l0ng-ai/openidea"
}
],
"primary": {
"type": "button",
"label": "下载",
"href": "https://github.com/l0ng-ai/openidea/releases/latest"
}
},
"tabs": [
{
"tab": "指南",
"groups": [
{
"group": "开始",
"pages": ["zh/index", "zh/guide/install", "zh/guide/quickstart", "zh/guide/migrate", "zh/roadmap"]
"pages": [
"zh/index",
"zh/introduction",
"zh/guide/install",
"zh/guide/quickstart",
"zh/guide/migrate",
"zh/roadmap"
]
},
{
"group": "编辑",
@@ -434,6 +469,10 @@
}
]
},
"redirects": [
{ "source": "/en/plugins", "destination": "/plugins" },
{ "source": "/zh/home", "destination": "/zh" }
],
"footer": {
"socials": {
"github": "https://github.com/l0ng-ai/openidea",
+246 -45
View File
@@ -1,58 +1,259 @@
---
title: "Introduction"
description: "OpenIDEA is an open-source IDE with the IntelliJ IDEA way of working, built as a native app with a Rust core."
title: "OpenIDEA"
sidebarTitle: "Home"
description: "The IDE you know, rebuilt in Rust. Open source, native, and fast on macOS, Windows and Linux."
mode: "custom"
---
OpenIDEA brings the IntelliJ IDEA way of working (its keymap, its tool windows, its search-everything habits) to a native desktop app with a Rust core. It runs on macOS, Windows and Linux and is licensed under Apache 2.0.
import { pluginCatalog } from "/snippets/plugin-catalog.jsx";
import { FeaturedPlugins } from "/snippets/marketplace.jsx";
If you have used IntelliJ IDEA, PyCharm or another JetBrains IDE, most of what you know carries over: pressing <kbd>Shift</kbd> twice opens Search Everywhere, `⌥↵` / `Alt+Enter` shows context actions, and the default keymap matches IDEA's. Coming from VS Code or Eclipse? Their keymaps are built in too.
export const Kbd = ({ children }) => <span className="oi-kbd">{children}</span>;
## Highlights
<div className="oi-home">
- **One IDE for many languages.** Editor and code insight for 60+ languages, and a one-click install of the language servers a project needs. See [Languages](/en/languages/index).
- **The tools you expect.** Debugger, Git, terminal, database client, HTTP client, test runner, coverage and profiler, each in its own tool window.
- **Search everything.** Search Everywhere, Find Action, Go to Class / File / Symbol and Find in Files across the indexed project.
- **Refactorings and inspections.** Rename, extract, inline, change signature, safe delete, quick fixes and Inspect Code.
- **Remote development.** Work on a machine over SSH or in a dev container with the `openidea-server` backend.
- **AI agents.** Run coding agents in a tool window, and give them the IDE's own tools through the built-in MCP server.
- **Plugins.** Plugins add actions, completion, quick fixes, tool windows, custom editors, themes, file icons and languages. They run as sandboxed WebAssembly components; themes, icon themes and languages need no code. The plugin API is still a preview.
<section className="oi-hero">
<div className="oi-hero-glow" aria-hidden="true" />
<div className="oi-grid-bg" aria-hidden="true" />
<div className="oi-wrap oi-hero-inner">
<a className="oi-pill" href="https://github.com/l0ng-ai/openidea">
<span className="oi-pill-dot" />
Open source · Apache 2.0
<span className="oi-pill-arrow">→</span>
</a>
<h1 className="oi-title">
The IDE you know,
<br />
<span className="oi-title-accent">rebuilt in Rust.</span>
</h1>
<p className="oi-lead">
Keymap, tool windows and search-everything habits you already have, in a native desktop app that opens in
under a second and idles at a fraction of the memory.
</p>
<div className="oi-actions">
<a className="oi-btn oi-btn-primary" href="https://github.com/l0ng-ai/openidea/releases/latest">
Download
</a>
<a className="oi-btn oi-btn-ghost" href="/en/introduction">
Read the docs
</a>
</div>
<p className="oi-platforms">macOS · Windows · Linux</p>
</div>
## Benchmark
<div className="oi-wrap">
<img
className="oi-shot"
src="/images/ide-dark.webp"
alt="OpenIDEA in the dark theme: a Java project with the project tree and the editor"
width="2880"
height="1800"
noZoom
/>
</div>
</section>
Opening [freqtrade](https://github.com/freqtrade/freqtrade) (Python, about 770 files) with warm caches, median of 5 runs:
<section className="oi-section">
<div className="oi-wrap">
<div className="oi-eyebrow">Benchmark</div>
<h2 className="oi-h2">Native speed, measured from the outside.</h2>
<p className="oi-sub">
Opening freqtrade (Python, ~770 files) with warm caches, median of 5 runs, against IntelliJ IDEA 2026.2.3 with
default settings.
</p>
<div className="oi-stats">
<div className="oi-stat">
<div className="oi-stat-num">
0.9<small>s</small>
</div>
<div className="oi-stat-label">Window with the project</div>
<div className="oi-bar">
<span style={{ width: "29%" }} />
</div>
<div className="oi-stat-vs">3.1 s in IntelliJ IDEA</div>
</div>
<div className="oi-stat">
<div className="oi-stat-num">
1.1<small>s</small>
</div>
<div className="oi-stat-label">Ready, CPU settled</div>
<div className="oi-bar">
<span style={{ width: "8%" }} />
</div>
<div className="oi-stat-vs">13.2 s in IntelliJ IDEA</div>
</div>
<div className="oi-stat">
<div className="oi-stat-num">
169<small>MB</small>
</div>
<div className="oi-stat-label">Memory, all processes</div>
<div className="oi-bar">
<span style={{ width: "8%" }} />
</div>
<div className="oi-stat-vs">2011 MB in IntelliJ IDEA</div>
</div>
<div className="oi-stat">
<div className="oi-stat-num">
0.3<small>s</small>
</div>
<div className="oi-stat-label">Quit</div>
<div className="oi-bar">
<span style={{ width: "5%" }} />
</div>
<div className="oi-stat-vs">5.9 s in IntelliJ IDEA</div>
</div>
</div>
<p className="oi-footnote">
Windows 11, 32-core AMD, 62 GB RAM. IDEA analyses Python more deeply, so "ready" isn't the same work on both
sides. Reproduce it with <a href="https://github.com/l0ng-ai/openidea/blob/main/perf/compare">perf/compare</a>.
</p>
</div>
</section>
| | OpenIDEA | IntelliJ IDEA 2026.2.3 |
| --------------------------- | ----------------- | ---------------------- |
| Window with the project | **0.9 s** | 3.1 s |
| Ready (CPU settled) | **1.1 s** | 13.2 s |
| Memory (USS, all processes) | **169 MB** | 2011 MB |
| CPU time until ready | **2.4 s** | 47.9 s |
| Idle CPU | **4 %** of a core | 7 % of a core |
| Quit | **0.3 s** | 5.9 s |
<section className="oi-section">
<div className="oi-wrap">
<div className="oi-eyebrow">Everything in one window</div>
<h2 className="oi-h2">A full IDE, not an editor with extensions.</h2>
<div className="oi-features">
<a className="oi-feature" href="/en/languages/index">
<Icon icon="code" size={18} />
<h3>60+ languages</h3>
<p>
Editor and code insight for every language, with one-click install of the language servers a project needs.
</p>
</a>
<a className="oi-feature" href="/en/guide/search">
<Icon icon="magnifying-glass" size={18} />
<h3>Search everything</h3>
<p>Search Everywhere, Find Action, Go to Class / File / Symbol and Find in Files across the indexed project.</p>
</a>
<a className="oi-feature" href="/en/guide/refactoring">
<Icon icon="wand-magic-sparkles" size={18} />
<h3>Refactor with confidence</h3>
<p>Rename, extract, inline, change signature and safe delete, plus inspections with quick fixes.</p>
</a>
<a className="oi-feature" href="/en/guide/debugging">
<Icon icon="bug" size={18} />
<h3>Run, test, debug</h3>
<p>Debugger, test runner, coverage and profiler, each in its own tool window.</p>
</a>
<a className="oi-feature" href="/en/guide/vcs">
<Icon icon="code-branch" size={18} />
<h3>Git, terminal, database</h3>
<p>Commit, log and branches, a real terminal, a database client and an HTTP client built in.</p>
</a>
<a className="oi-feature" href="/en/guide/remote/ssh">
<Icon icon="server" size={18} />
<h3>Remote development</h3>
<p>
Work on a machine over SSH or in a dev container, backed by <code>openidea-server</code>.
</p>
</a>
<a className="oi-feature" href="/en/guide/agents">
<Icon icon="sparkles" size={18} />
<h3>AI agents</h3>
<p>Run coding agents in a tool window and give them the IDE's own tools through the built-in MCP server.</p>
</a>
<a className="oi-feature" href="/en/plugins/index">
<Icon icon="puzzle-piece" size={18} />
<h3>WebAssembly plugins</h3>
<p>Sandboxed plugins add actions, completion, tool windows and editors. Themes and languages need no code.</p>
</a>
</div>
</div>
</section>
Measured with a release build of OpenIDEA from `main` and IDEA with default settings and plugins, on Windows 11, 32-core AMD, 62 GB RAM. IDEA analyses Python more deeply, so "ready" doesn't mean the same work on both sides. Both are measured from the outside, the same way: see [`perf/compare`](https://github.com/l0ng-ai/openidea/blob/main/perf/compare) to run the comparison on your own machine and projects.
<section className="oi-section">
<div className="oi-wrap">
<div className="oi-plug-head">
<div>
<div className="oi-eyebrow">Plugin Marketplace</div>
<h2 className="oi-h2">{pluginCatalog.plugins.length} plugins and counting.</h2>
<p className="oi-sub">
Spring, Laravel, Symfony, Kubernetes, AI commit messages, themes and more, from {pluginCatalog.publishers}{" "}
publishers. Every package is signed and runs in a WebAssembly sandbox.
</p>
</div>
<a className="oi-btn oi-btn-ghost" href="/plugins">
Browse the marketplace →
</a>
</div>
<FeaturedPlugins catalog={pluginCatalog} href="/plugins" />
</div>
</section>
## Where to go next
<section className="oi-section">
<div className="oi-wrap oi-split">
<div>
<div className="oi-eyebrow">Muscle memory included</div>
<h2 className="oi-h2">Your shortcuts already work.</h2>
<p className="oi-sub">
The default keymap matches IntelliJ IDEA, and VS Code and Eclipse keymaps are built in. Settings import brings
the rest.
</p>
<a className="oi-link" href="/en/guide/migrate">
Coming from another IDE →
</a>
</div>
<div className="oi-keys">
<div className="oi-key-row">
<span>
<Kbd>⇧</Kbd>
<Kbd>⇧</Kbd>
</span>
Search Everywhere
</div>
<div className="oi-key-row">
<span>
<Kbd>⌥</Kbd>
<Kbd>↵</Kbd>
</span>
Show context actions
</div>
<div className="oi-key-row">
<span>
<Kbd>⌘</Kbd>
<Kbd>⇧</Kbd>
<Kbd>A</Kbd>
</span>
Find Action
</div>
<div className="oi-key-row">
<span>
<Kbd>⇧</Kbd>
<Kbd>F6</Kbd>
</span>
Rename
</div>
<div className="oi-key-row">
<span>
<Kbd>⌃</Kbd>
<Kbd>⇧</Kbd>
<Kbd>D</Kbd>
</span>
Debug
</div>
</div>
</div>
</section>
<CardGroup cols={2}>
<Card title="Install" icon="download" href="/en/guide/install">
Download OpenIDEA for macOS, Windows or Linux.
</Card>
<Card title="Quickstart" icon="rocket" href="/en/guide/quickstart">
Open a project, find your way around, run and debug.
</Card>
<Card title="Coming from another IDE" icon="right-left" href="/en/guide/migrate">
Keymaps, settings import and concepts for IntelliJ IDEA, VS Code and Eclipse users.
</Card>
<Card title="Languages" icon="code" href="/en/languages/index">
What each language supports and what it needs installed.
</Card>
<Card title="Plugins" icon="puzzle-piece" href="/en/plugins/index">
Write themes, languages and WebAssembly plugins.
</Card>
<Card title="Contribute" icon="code-branch" href="/en/contribute/setup">
Build OpenIDEA from source and send a pull request.
</Card>
</CardGroup>
<section className="oi-cta">
<div className="oi-hero-glow oi-cta-glow" aria-hidden="true" />
<div className="oi-wrap oi-cta-inner">
<h2 className="oi-h2">Open a project in under a second.</h2>
<p className="oi-sub">Free and open source, for macOS, Windows and Linux.</p>
<div className="oi-actions">
<a className="oi-btn oi-btn-primary" href="https://github.com/l0ng-ai/openidea/releases/latest">
Download
</a>
<a className="oi-btn oi-btn-ghost" href="/en/guide/quickstart">
Quickstart
</a>
</div>
<p className="oi-disclaimer">
OpenIDEA is not affiliated with JetBrains. IntelliJ IDEA is a trademark of JetBrains s.r.o.
</p>
</div>
</section>
<Note>OpenIDEA is not affiliated with JetBrains. IntelliJ IDEA is a trademark of JetBrains s.r.o.</Note>
</div>
+58
View File
@@ -0,0 +1,58 @@
---
title: "Introduction"
description: "OpenIDEA is an open-source IDE with the IntelliJ IDEA way of working, built as a native app with a Rust core."
---
OpenIDEA brings the IntelliJ IDEA way of working (its keymap, its tool windows, its search-everything habits) to a native desktop app with a Rust core. It runs on macOS, Windows and Linux and is licensed under Apache 2.0.
If you have used IntelliJ IDEA, PyCharm or another JetBrains IDE, most of what you know carries over: pressing <kbd>Shift</kbd> twice opens Search Everywhere, `⌥↵` / `Alt+Enter` shows context actions, and the default keymap matches IDEA's. Coming from VS Code or Eclipse? Their keymaps are built in too.
## Highlights
- **One IDE for many languages.** Editor and code insight for 60+ languages, and a one-click install of the language servers a project needs. See [Languages](/en/languages/index).
- **The tools you expect.** Debugger, Git, terminal, database client, HTTP client, test runner, coverage and profiler, each in its own tool window.
- **Search everything.** Search Everywhere, Find Action, Go to Class / File / Symbol and Find in Files across the indexed project.
- **Refactorings and inspections.** Rename, extract, inline, change signature, safe delete, quick fixes and Inspect Code.
- **Remote development.** Work on a machine over SSH or in a dev container with the `openidea-server` backend.
- **AI agents.** Run coding agents in a tool window, and give them the IDE's own tools through the built-in MCP server.
- **Plugins.** Plugins add actions, completion, quick fixes, tool windows, custom editors, themes, file icons and languages. They run as sandboxed WebAssembly components; themes, icon themes and languages need no code. The plugin API is still a preview.
## Benchmark
Opening [freqtrade](https://github.com/freqtrade/freqtrade) (Python, about 770 files) with warm caches, median of 5 runs:
| | OpenIDEA | IntelliJ IDEA 2026.2.3 |
| --------------------------- | ----------------- | ---------------------- |
| Window with the project | **0.9 s** | 3.1 s |
| Ready (CPU settled) | **1.1 s** | 13.2 s |
| Memory (USS, all processes) | **169 MB** | 2011 MB |
| CPU time until ready | **2.4 s** | 47.9 s |
| Idle CPU | **4 %** of a core | 7 % of a core |
| Quit | **0.3 s** | 5.9 s |
Measured with a release build of OpenIDEA from `main` and IDEA with default settings and plugins, on Windows 11, 32-core AMD, 62 GB RAM. IDEA analyses Python more deeply, so "ready" doesn't mean the same work on both sides. Both are measured from the outside, the same way: see [`perf/compare`](https://github.com/l0ng-ai/openidea/blob/main/perf/compare) to run the comparison on your own machine and projects.
## Where to go next
<CardGroup cols={2}>
<Card title="Install" icon="download" href="/en/guide/install">
Download OpenIDEA for macOS, Windows or Linux.
</Card>
<Card title="Quickstart" icon="rocket" href="/en/guide/quickstart">
Open a project, find your way around, run and debug.
</Card>
<Card title="Coming from another IDE" icon="right-left" href="/en/guide/migrate">
Keymaps, settings import and concepts for IntelliJ IDEA, VS Code and Eclipse users.
</Card>
<Card title="Languages" icon="code" href="/en/languages/index">
What each language supports and what it needs installed.
</Card>
<Card title="Plugins" icon="puzzle-piece" href="/en/plugins/index">
Write themes, languages and WebAssembly plugins.
</Card>
<Card title="Contribute" icon="code-branch" href="/en/contribute/setup">
Build OpenIDEA from source and send a pull request.
</Card>
</CardGroup>
<Note>OpenIDEA is not affiliated with JetBrains. IntelliJ IDEA is a trademark of JetBrains s.r.o.</Note>
+1119
View File
File diff suppressed because it is too large Load Diff
Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

+10
View File
@@ -0,0 +1,10 @@
---
title: "Plugin Marketplace"
description: "Browse OpenIDEA plugins: languages, frameworks, linters, themes, AI and tools from the community and the OpenIDEA team."
mode: "custom"
---
import { pluginCatalog } from "/snippets/plugin-catalog.jsx";
import { Marketplace } from "/snippets/marketplace.jsx";
<Marketplace catalog={pluginCatalog} lang="en" />
+411
View File
@@ -0,0 +1,411 @@
// Pages import the catalog (`/snippets/plugin-catalog.jsx`) and pass it in. Mintlify takes each imported
// export on its own, so every component here is self-contained: no imports, no shared top-level helpers.
export const Marketplace = ({ catalog: pluginCatalog, lang = "en" }) => {
const TEXT = {
en: {
eyebrow: "Plugin Marketplace",
title: "Make OpenIDEA yours.",
lead: "Languages, frameworks, linters, themes and tools, signed by their publishers and installed in one click from",
path: "Settings › Plugins › Marketplace",
leadEnd: ".",
plugins: "plugins",
publishers: "publishers",
downloads: "downloads",
downloadsLabel: "Downloads",
listSep: ", ",
search: "Search plugins",
sort: "Sort",
popular: "Popular",
az: "A–Z",
category: "Category",
official: "Official",
empty: (q) => `No plugins match “${q}”.`,
buildEyebrow: "Build a plugin",
buildTitle: "Ship your plugin to every OpenIDEA user.",
buildLead:
"Plugins are sandboxed WebAssembly components with a typed API. Themes, icon themes and languages need no code at all. Scaffold one in a minute, then list it through the community registry.",
quickstart: "Plugin quickstart",
publish: "Publish to the marketplace",
term1: "# attach the .oiplugin to a release, then open a",
term2: "# pull request in l0ng-ai/openidea-plugins",
note: (d) =>
`Snapshot of the marketplace index from ${d}. The IDE always shows the current list. Community plugins are built and signed by their authors.`,
close: "Close",
version: "Version",
categoriesLabel: "Categories",
pluginId: "Plugin id",
install: (name) => (
<>
<b>Install</b> In OpenIDEA, open <b>Settings › Plugins › Marketplace</b>, search for “{name}” and click{" "}
<b>Install</b>.
</>
),
source: "Source and docs",
categories: {
all: "All",
frameworks: "Frameworks",
languages: "Languages",
tools: "Tools",
linters: "Linters",
vcs: "Version control",
ai: "AI",
themes: "Themes",
"icon-themes": "Icon themes",
other: "Other",
},
},
zh: {
eyebrow: "插件市场",
title: "让 OpenIDEA 成为你的 IDE。",
lead: "语言、框架、代码检查、主题和工具,均由发布者签名,在",
path: "设置 › 插件 › 插件市场",
leadEnd: "中一键安装。",
plugins: "个插件",
publishers: "位发布者",
downloads: "次下载",
downloadsLabel: "下载量",
listSep: "、",
search: "搜索插件",
sort: "排序",
popular: "最热门",
az: "按名称",
category: "分类",
official: "官方",
empty: (q) => `没有与“${q}”匹配的插件。`,
buildEyebrow: "开发插件",
buildTitle: "把你的插件交到每一位 OpenIDEA 用户手中。",
buildLead:
"插件是运行在沙箱中的 WebAssembly 组件,API 有完整类型。主题、图标主题和语言完全不用写代码。一分钟搭好脚手架,再通过社区登记仓库上架。",
quickstart: "插件快速开始",
publish: "发布到插件市场",
term1: "# 把 .oiplugin 附加到 release,然后向",
term2: "# l0ng-ai/openidea-plugins 提交 pull request",
note: (d) => `插件市场索引快照,生成于 ${d}。IDE 中显示的始终是最新列表。社区插件由作者自行构建和签名。`,
close: "关闭",
version: "版本",
categoriesLabel: "分类",
pluginId: "插件 id",
install: (name) => (
<>
<b>安装</b> 在 OpenIDEA 中打开 <b>设置 › 插件 › 插件市场</b>,搜索“
{name}”,点击 <b>安装</b>。
</>
),
source: "源码与文档",
categories: {
all: "全部",
frameworks: "框架",
languages: "语言",
tools: "工具",
linters: "代码检查",
vcs: "版本控制",
ai: "AI",
themes: "主题",
"icon-themes": "图标主题",
other: "其他",
},
},
};
const CATEGORY_IDS = [
"all",
"frameworks",
"languages",
"tools",
"linters",
"vcs",
"ai",
"themes",
"icon-themes",
"other",
];
const formatCount = (n) => (n >= 1000 ? `${(n / 1000).toFixed(1).replace(/\.0$/, "")}k` : `${n}`);
// Called as a function: snippet components cannot use each other as JSX tags.
const pluginIcon = (plugin, size) =>
plugin.icon ? (
<span className="oi-mk-icon" style={{ width: size, height: size }}>
<img className="oi-mk-icon-light" src={plugin.icon.light} alt="" />
<img className="oi-mk-icon-dark" src={plugin.icon.dark || plugin.icon.light} alt="" />
</span>
) : (
<span className="oi-mk-icon oi-mk-icon-fallback" style={{ width: size, height: size }}>
{plugin.name
.replace(/^[^A-Za-z0-9]+/, "")
.slice(0, 1)
.toUpperCase()}
</span>
);
const t = TEXT[lang] || TEXT.en;
const categoryLabel = (id) => t.categories[id] || id;
const all = pluginCatalog.plugins;
const [query, setQuery] = useState("");
const [category, setCategory] = useState("all");
const [sort, setSort] = useState("popular");
const [open, setOpen] = useState(null);
const counts = {};
for (const p of all) for (const c of p.categories) counts[c] = (counts[c] || 0) + 1;
const totalDownloads = all.reduce((s, p) => s + p.downloads, 0);
const q = query.trim().toLowerCase();
const shown = all
.filter((p) => category === "all" || p.categories.includes(category))
.filter(
(p) =>
!q ||
p.name.toLowerCase().includes(q) ||
p.description.toLowerCase().includes(q) ||
p.publisher.toLowerCase().includes(q) ||
p.id.toLowerCase().includes(q),
)
.slice()
.sort((a, b) => (sort === "name" ? a.name.localeCompare(b.name) : b.downloads - a.downloads));
const current = open && all.find((p) => p.id === open);
useEffect(() => {
if (!current) return;
const onKey = (e) => e.key === "Escape" && setOpen(null);
window.addEventListener("keydown", onKey);
return () => window.removeEventListener("keydown", onKey);
}, [current]);
return (
<div className="oi-home oi-mk">
<section className="oi-mk-hero">
<div className="oi-hero-glow" aria-hidden="true" />
<div className="oi-grid-bg" aria-hidden="true" />
<div className="oi-wrap">
<div className="oi-eyebrow">{t.eyebrow}</div>
<h1 className="oi-mk-title">{t.title}</h1>
<p className="oi-sub">
{t.lead} <b>{t.path}</b>
{t.leadEnd}
</p>
<div className="oi-mk-metrics">
<div>
<strong>{all.length}</strong>
<span>{t.plugins}</span>
</div>
<div>
<strong>{pluginCatalog.publishers}</strong>
<span>{t.publishers}</span>
</div>
<div>
<strong>{formatCount(totalDownloads)}</strong>
<span>{t.downloads}</span>
</div>
</div>
</div>
</section>
<div className="oi-wrap">
<div className="oi-mk-toolbar">
<label className="oi-mk-search">
<svg viewBox="0 0 16 16" width="15" height="15" aria-hidden="true">
<circle cx="7" cy="7" r="4.75" fill="none" stroke="currentColor" strokeWidth="1.5" />
<path d="M10.5 10.5 14 14" stroke="currentColor" strokeWidth="1.5" strokeLinecap="round" />
</svg>
<input
type="search"
placeholder={t.search}
aria-label={t.search}
value={query}
onChange={(e) => setQuery(e.target.value)}
/>
</label>
<div className="oi-mk-sort" role="group" aria-label={t.sort}>
<button type="button" className={sort === "popular" ? "is-on" : ""} onClick={() => setSort("popular")}>
{t.popular}
</button>
<button type="button" className={sort === "name" ? "is-on" : ""} onClick={() => setSort("name")}>
{t.az}
</button>
</div>
</div>
<div className="oi-mk-chips" role="group" aria-label={t.category}>
{CATEGORY_IDS.filter((id) => id === "all" || counts[id]).map((id) => (
<button type="button" key={id} className={category === id ? "is-on" : ""} onClick={() => setCategory(id)}>
{categoryLabel(id)}
<em>{id === "all" ? all.length : counts[id]}</em>
</button>
))}
</div>
<div className="oi-mk-grid">
{shown.map((p) => (
<button type="button" key={p.id} className="oi-mk-card" onClick={() => setOpen(p.id)}>
<div className="oi-mk-card-head">
{pluginIcon(p, 44)}
<div className="oi-mk-card-title">
<h3>{p.name}</h3>
<span>
{p.publisher}
{p.official && <b className="oi-mk-badge">{t.official}</b>}
</span>
</div>
</div>
<p>{p.description}</p>
<div className="oi-mk-card-foot">
<span className="oi-mk-tag">{categoryLabel(p.categories[0])}</span>
{p.downloads > 0 && (
<span className="oi-mk-dl">
<svg viewBox="0 0 16 16" width="12" height="12" aria-hidden="true">
<path
d="M8 2v8m0 0 3-3m-3 3L5 7M3 13h10"
fill="none"
stroke="currentColor"
strokeWidth="1.5"
strokeLinecap="round"
strokeLinejoin="round"
/>
</svg>
{formatCount(p.downloads)}
</span>
)}
<span className="oi-mk-ver">v{p.version}</span>
</div>
</button>
))}
</div>
{shown.length === 0 && <p className="oi-mk-empty">{t.empty(query)}</p>}
<section className="oi-mk-build">
<div>
<div className="oi-eyebrow">{t.buildEyebrow}</div>
<h2 className="oi-h2">{t.buildTitle}</h2>
<p className="oi-sub">{t.buildLead}</p>
<div className="oi-mk-build-actions">
<a className="oi-btn oi-btn-primary" href={`/${lang}/plugins/quickstart`}>
{t.quickstart}
</a>
<a className="oi-btn oi-btn-ghost" href={`/${lang}/plugins/publishing/marketplace`}>
{t.publish}
</a>
</div>
</div>
<div className="oi-mk-term" aria-hidden="true">
<div className="oi-mk-term-bar">
<span />
<span />
<span />
</div>
<div className="oi-mk-term-body">
<div>
<b>$</b> openidea-plugin new hello --id acme.hello
</div>
<div>
<b>$</b> cd hello && cargo test
</div>
<div>
<b>$</b> openidea-plugin build
</div>
<div>
<b>$</b> openidea-plugin pack . --key acme.key --publisher acme
</div>
<div className="dim">{t.term1}</div>
<div className="dim">{t.term2}</div>
</div>
</div>
</section>
<p className="oi-mk-note">{t.note(pluginCatalog.generatedAt)}</p>
</div>
{current && (
<div className="oi-mk-overlay" onClick={() => setOpen(null)}>
<div
className="oi-mk-dialog"
role="dialog"
aria-modal="true"
aria-label={current.name}
onClick={(e) => e.stopPropagation()}
>
<button type="button" className="oi-mk-close" aria-label={t.close} onClick={() => setOpen(null)}>
<svg viewBox="0 0 16 16" width="14" height="14" aria-hidden="true">
<path d="M4 4l8 8M12 4l-8 8" stroke="currentColor" strokeWidth="1.5" strokeLinecap="round" />
</svg>
</button>
<div className="oi-mk-card-head">
{pluginIcon(current, 64)}
<div className="oi-mk-card-title">
<h3>{current.name}</h3>
<span>
{current.publisher}
{current.official && <b className="oi-mk-badge">{t.official}</b>}
</span>
</div>
</div>
<p className="oi-mk-dialog-desc">{current.description}</p>
<dl className="oi-mk-facts">
<div>
<dt>{t.version}</dt>
<dd>{current.version}</dd>
</div>
<div>
<dt>{t.downloadsLabel}</dt>
<dd>{current.downloads ? current.downloads.toLocaleString(lang === "zh" ? "zh-CN" : "en-US") : "—"}</dd>
</div>
<div>
<dt>{t.categoriesLabel}</dt>
<dd>{current.categories.map(categoryLabel).join(t.listSep)}</dd>
</div>
<div>
<dt>{t.pluginId}</dt>
<dd>
<code>{current.id}</code>
</dd>
</div>
</dl>
<div className="oi-mk-install">{t.install(current.name)}</div>
{current.homepage && (
<a className="oi-btn oi-btn-ghost oi-mk-home" href={current.homepage} target="_blank" rel="noreferrer">
{t.source} ↗
</a>
)}
</div>
</div>
)}
</div>
);
};
export const FeaturedPlugins = ({ catalog: pluginCatalog, href }) => {
const pluginIcon = (plugin, size) =>
plugin.icon ? (
<span className="oi-mk-icon" style={{ width: size, height: size }}>
<img className="oi-mk-icon-light" src={plugin.icon.light} alt="" />
<img className="oi-mk-icon-dark" src={plugin.icon.dark || plugin.icon.light} alt="" />
</span>
) : (
<span className="oi-mk-icon oi-mk-icon-fallback" style={{ width: size, height: size }}>
{plugin.name
.replace(/^[^A-Za-z0-9]+/, "")
.slice(0, 1)
.toUpperCase()}
</span>
);
return (
<div className="oi-plug-grid">
{pluginCatalog.plugins
.filter((p) => p.icon)
.slice(0, 12)
.map((p) => (
<a key={p.id} className="oi-plug" href={href}>
{pluginIcon(p, 36)}
<span className="oi-plug-text">
<b>{p.name}</b>
<em>{p.publisher}</em>
</span>
</a>
))}
</div>
);
};
File diff suppressed because one or more lines are too long
+239 -45
View File
@@ -1,58 +1,252 @@
---
title: "介绍"
description: "OpenIDEA 是一款开源 IDE,沿用 IntelliJ IDEA 的使用方式,以 Rust 为核心构建成原生应用。"
title: "OpenIDEA"
sidebarTitle: "首页"
description: "熟悉的 IDE,用 Rust 重新打造。开源、原生,在 macOS、Windows 和 Linux 上都很快。"
mode: "custom"
---
OpenIDEA 把 IntelliJ IDEA 的使用方式(快捷键、工具窗口、随处搜索的习惯)带到一个以 Rust 为核心的原生桌面应用里。支持 macOS、Windows 和 Linux,采用 Apache 2.0 许可证。
import { pluginCatalog } from "/snippets/plugin-catalog.jsx";
import { FeaturedPlugins } from "/snippets/marketplace.jsx";
用过 IntelliJ IDEA、PyCharm 或其他 JetBrains IDE 的话,大部分经验可以直接沿用:连按两下 <kbd>Shift</kbd> 打开随处搜索,`⌥↵` / `Alt+Enter` 显示上下文操作,默认快捷键方案与 IDEA 一致。从 VS Code 或 Eclipse 过来,也有对应的内置快捷键方案。
export const Kbd = ({ children }) => <span className="oi-kbd">{children}</span>;
## 亮点
<div className="oi-home">
- **一个 IDE 覆盖多种语言。** 为 60 多种语言提供编辑和代码洞察,项目需要的语言服务器可一键安装。参见[语言](/zh/languages/index)。
- **常用工具齐全。** 调试器、Git、终端、数据库客户端、HTTP 客户端、测试运行器、覆盖率和性能分析器,各有自己的工具窗口。
- **随处搜索。** 在已建立索引的项目中使用随处搜索、查找操作、转到类 / 文件 / 符号以及在文件中查找。
- **重构与检查。** 重命名、提取、内联、更改签名、安全删除、快速修复和代码检查。
- **远程开发。** 通过 SSH 或在开发容器中工作,后端是 `openidea-server`。
- **AI 智能体。** 在工具窗口中运行编码智能体,并通过内置 MCP 服务器把 IDE 自身的工具提供给它们。
- **插件。** 插件可以添加操作、补全、快速修复、工具窗口、自定义编辑器、主题、文件图标和语言。插件以沙箱化的 WebAssembly 组件运行;主题、图标主题和语言无需编写代码。插件 API 目前仍是预览版。
<section className="oi-hero">
<div className="oi-hero-glow" aria-hidden="true" />
<div className="oi-grid-bg" aria-hidden="true" />
<div className="oi-wrap oi-hero-inner">
<a className="oi-pill" href="https://github.com/l0ng-ai/openidea">
<span className="oi-pill-dot" />
开源 · Apache 2.0
<span className="oi-pill-arrow">→</span>
</a>
<h1 className="oi-title">
熟悉的 IDE,
<br />
<span className="oi-title-accent">用 Rust 重新打造。</span>
</h1>
<p className="oi-lead">
你熟悉的快捷键、工具窗口和随处搜索,装进一个原生桌面应用:不到一秒打开项目,内存只占一小部分。
</p>
<div className="oi-actions">
<a className="oi-btn oi-btn-primary" href="https://github.com/l0ng-ai/openidea/releases/latest">
下载
</a>
<a className="oi-btn oi-btn-ghost" href="/zh/introduction">
阅读文档
</a>
</div>
<p className="oi-platforms">macOS · Windows · Linux</p>
</div>
## 性能对比
<div className="oi-wrap">
<img
className="oi-shot"
src="/images/ide-dark.webp"
alt="深色主题下的 OpenIDEA:一个 Java 项目,包含项目树和编辑器"
width="2880"
height="1800"
noZoom
/>
</div>
</section>
在缓存已预热的情况下打开 [freqtrade](https://github.com/freqtrade/freqtrade)(Python,约 770 个文件),取 5 次运行的中位数:
<section className="oi-section">
<div className="oi-wrap">
<div className="oi-eyebrow">性能对比</div>
<h2 className="oi-h2">原生的速度,从外部实测。</h2>
<p className="oi-sub">
打开 freqtrade(Python,约 770 个文件),缓存已预热,取 5 次运行的中位数,对比默认设置的 IntelliJ IDEA 2026.2.3。
</p>
<div className="oi-stats">
<div className="oi-stat">
<div className="oi-stat-num">
0.9<small>s</small>
</div>
<div className="oi-stat-label">项目窗口出现</div>
<div className="oi-bar">
<span style={{ width: "29%" }} />
</div>
<div className="oi-stat-vs">IntelliJ IDEA:3.1 s</div>
</div>
<div className="oi-stat">
<div className="oi-stat-num">
1.1<small>s</small>
</div>
<div className="oi-stat-label">就绪(CPU 平稳)</div>
<div className="oi-bar">
<span style={{ width: "8%" }} />
</div>
<div className="oi-stat-vs">IntelliJ IDEA:13.2 s</div>
</div>
<div className="oi-stat">
<div className="oi-stat-num">
169<small>MB</small>
</div>
<div className="oi-stat-label">内存(全部进程)</div>
<div className="oi-bar">
<span style={{ width: "8%" }} />
</div>
<div className="oi-stat-vs">IntelliJ IDEA:2011 MB</div>
</div>
<div className="oi-stat">
<div className="oi-stat-num">
0.3<small>s</small>
</div>
<div className="oi-stat-label">退出</div>
<div className="oi-bar">
<span style={{ width: "5%" }} />
</div>
<div className="oi-stat-vs">IntelliJ IDEA:5.9 s</div>
</div>
</div>
<p className="oi-footnote">
Windows 11,32 核 AMD,62 GB 内存。IDEA 对 Python 的分析更深入,所以两边的“就绪”并不是同样的工作量。可以用{" "}
<a href="https://github.com/l0ng-ai/openidea/blob/main/perf/compare">perf/compare</a> 在自己的机器上复现。
</p>
</div>
</section>
| | OpenIDEA | IntelliJ IDEA 2026.2.3 |
| --------------------- | -------------- | ---------------------- |
| 显示项目窗口 | **0.9 s** | 3.1 s |
| 就绪(CPU 平稳) | **1.1 s** | 13.2 s |
| 内存(USS,所有进程) | **169 MB** | 2011 MB |
| 就绪前消耗的 CPU 时间 | **2.4 s** | 47.9 s |
| 空闲 CPU | 单核的 **4 %** | 单核的 7 % |
| 退出 | **0.3 s** | 5.9 s |
<section className="oi-section">
<div className="oi-wrap">
<div className="oi-eyebrow">一个窗口,应有尽有</div>
<h2 className="oi-h2">完整的 IDE,而不是装满扩展的编辑器。</h2>
<div className="oi-features">
<a className="oi-feature" href="/zh/languages/index">
<Icon icon="code" size={18} />
<h3>60 多种语言</h3>
<p>每种语言都有编辑和代码洞察,项目需要的语言服务器一键安装。</p>
</a>
<a className="oi-feature" href="/zh/guide/search">
<Icon icon="magnifying-glass" size={18} />
<h3>随处搜索</h3>
<p>随处搜索、查找操作、转到类 / 文件 / 符号,以及在整个已索引项目中查找。</p>
</a>
<a className="oi-feature" href="/zh/guide/refactoring">
<Icon icon="wand-magic-sparkles" size={18} />
<h3>放心重构</h3>
<p>重命名、提取、内联、更改签名和安全删除,还有带快速修复的代码检查。</p>
</a>
<a className="oi-feature" href="/zh/guide/debugging">
<Icon icon="bug" size={18} />
<h3>运行、测试、调试</h3>
<p>调试器、测试运行器、覆盖率和性能分析器,各有自己的工具窗口。</p>
</a>
<a className="oi-feature" href="/zh/guide/vcs">
<Icon icon="code-branch" size={18} />
<h3>Git、终端、数据库</h3>
<p>提交、日志和分支,真正的终端,内置数据库客户端和 HTTP 客户端。</p>
</a>
<a className="oi-feature" href="/zh/guide/remote/ssh">
<Icon icon="server" size={18} />
<h3>远程开发</h3>
<p>
通过 SSH 连到远程机器,或在开发容器中工作,后端是 <code>openidea-server</code>。
</p>
</a>
<a className="oi-feature" href="/zh/guide/agents">
<Icon icon="sparkles" size={18} />
<h3>AI 智能体</h3>
<p>在工具窗口中运行编码智能体,并通过内置 MCP 服务器把 IDE 自身的工具交给它们。</p>
</a>
<a className="oi-feature" href="/zh/plugins/index">
<Icon icon="puzzle-piece" size={18} />
<h3>WebAssembly 插件</h3>
<p>沙箱化的插件可以添加操作、补全、工具窗口和编辑器。主题和语言无需写代码。</p>
</a>
</div>
</div>
</section>
测试使用 `main` 分支的 OpenIDEA release 构建,以及默认设置和插件的 IDEA,环境为 Windows 11、32 核 AMD、62 GB 内存。IDEA 对 Python 的分析更深入,所以两边的“就绪”并不代表完成了同样多的工作。两者都以相同方式从外部测量:可以用 [`perf/compare`](https://github.com/l0ng-ai/openidea/blob/main/perf/compare) 在自己的机器和项目上复现。
<section className="oi-section">
<div className="oi-wrap">
<div className="oi-plug-head">
<div>
<div className="oi-eyebrow">插件市场</div>
<h2 className="oi-h2">{pluginCatalog.plugins.length} 个插件,还在增加。</h2>
<p className="oi-sub">
Spring、Laravel、Symfony、Kubernetes、AI 提交信息、主题等等,来自 {pluginCatalog.publishers}{" "}
位发布者。每个插件包都经过签名,运行在 WebAssembly 沙箱中。
</p>
</div>
<a className="oi-btn oi-btn-ghost" href="/plugins">
浏览插件市场 →
</a>
</div>
<FeaturedPlugins catalog={pluginCatalog} href="/zh/plugins" />
</div>
</section>
## 下一步
<section className="oi-section">
<div className="oi-wrap oi-split">
<div>
<div className="oi-eyebrow">肌肉记忆照样好用</div>
<h2 className="oi-h2">你的快捷键,直接就能用。</h2>
<p className="oi-sub">
默认快捷键方案与 IntelliJ IDEA 一致,也内置了 VS Code 和 Eclipse 方案。其余设置可以直接导入。
</p>
<a className="oi-link" href="/zh/guide/migrate">
从其他 IDE 迁移 →
</a>
</div>
<div className="oi-keys">
<div className="oi-key-row">
<span>
<Kbd>⇧</Kbd>
<Kbd>⇧</Kbd>
</span>
随处搜索
</div>
<div className="oi-key-row">
<span>
<Kbd>⌥</Kbd>
<Kbd>↵</Kbd>
</span>
显示上下文操作
</div>
<div className="oi-key-row">
<span>
<Kbd>⌘</Kbd>
<Kbd>⇧</Kbd>
<Kbd>A</Kbd>
</span>
查找操作
</div>
<div className="oi-key-row">
<span>
<Kbd>⇧</Kbd>
<Kbd>F6</Kbd>
</span>
重命名
</div>
<div className="oi-key-row">
<span>
<Kbd>⌃</Kbd>
<Kbd>⇧</Kbd>
<Kbd>D</Kbd>
</span>
调试
</div>
</div>
</div>
</section>
<CardGroup cols={2}>
<Card title="安装" icon="download" href="/zh/guide/install">
下载 macOS、Windows 或 Linux 版 OpenIDEA。
</Card>
<Card title="快速上手" icon="rocket" href="/zh/guide/quickstart">
打开项目、熟悉界面、运行和调试。
</Card>
<Card title="从其他 IDE 迁移" icon="right-left" href="/zh/guide/migrate">
面向 IntelliJ IDEA、VS Code 和 Eclipse 用户的快捷键、设置导入和概念对照。
</Card>
<Card title="语言" icon="code" href="/zh/languages/index">
各语言支持哪些功能、需要安装什么。
</Card>
<Card title="插件" icon="puzzle-piece" href="/zh/plugins/index">
编写主题、语言和 WebAssembly 插件。
</Card>
<Card title="参与贡献" icon="code-branch" href="/zh/contribute/setup">
从源码构建 OpenIDEA 并提交 Pull Request。
</Card>
</CardGroup>
<section className="oi-cta">
<div className="oi-hero-glow oi-cta-glow" aria-hidden="true" />
<div className="oi-wrap oi-cta-inner">
<h2 className="oi-h2">不到一秒,打开项目。</h2>
<p className="oi-sub">免费开源,支持 macOS、Windows 和 Linux。</p>
<div className="oi-actions">
<a className="oi-btn oi-btn-primary" href="https://github.com/l0ng-ai/openidea/releases/latest">
下载
</a>
<a className="oi-btn oi-btn-ghost" href="/zh/guide/quickstart">
快速开始
</a>
</div>
<p className="oi-disclaimer">OpenIDEA 与 JetBrains 无关联。IntelliJ IDEA 是 JetBrains s.r.o. 的商标。</p>
</div>
</section>
<Note>OpenIDEA 与 JetBrains 无关联。IntelliJ IDEA 是 JetBrains s.r.o. 的商标。</Note>
</div>
+58
View File
@@ -0,0 +1,58 @@
---
title: "介绍"
description: "OpenIDEA 是一款开源 IDE,沿用 IntelliJ IDEA 的使用方式,以 Rust 为核心构建成原生应用。"
---
OpenIDEA 把 IntelliJ IDEA 的使用方式(快捷键、工具窗口、随处搜索的习惯)带到一个以 Rust 为核心的原生桌面应用里。支持 macOS、Windows 和 Linux,采用 Apache 2.0 许可证。
用过 IntelliJ IDEA、PyCharm 或其他 JetBrains IDE 的话,大部分经验可以直接沿用:连按两下 <kbd>Shift</kbd> 打开随处搜索,`⌥↵` / `Alt+Enter` 显示上下文操作,默认快捷键方案与 IDEA 一致。从 VS Code 或 Eclipse 过来,也有对应的内置快捷键方案。
## 亮点
- **一个 IDE 覆盖多种语言。** 为 60 多种语言提供编辑和代码洞察,项目需要的语言服务器可一键安装。参见[语言](/zh/languages/index)。
- **常用工具齐全。** 调试器、Git、终端、数据库客户端、HTTP 客户端、测试运行器、覆盖率和性能分析器,各有自己的工具窗口。
- **随处搜索。** 在已建立索引的项目中使用随处搜索、查找操作、转到类 / 文件 / 符号以及在文件中查找。
- **重构与检查。** 重命名、提取、内联、更改签名、安全删除、快速修复和代码检查。
- **远程开发。** 通过 SSH 或在开发容器中工作,后端是 `openidea-server`。
- **AI 智能体。** 在工具窗口中运行编码智能体,并通过内置 MCP 服务器把 IDE 自身的工具提供给它们。
- **插件。** 插件可以添加操作、补全、快速修复、工具窗口、自定义编辑器、主题、文件图标和语言。插件以沙箱化的 WebAssembly 组件运行;主题、图标主题和语言无需编写代码。插件 API 目前仍是预览版。
## 性能对比
在缓存已预热的情况下打开 [freqtrade](https://github.com/freqtrade/freqtrade)(Python,约 770 个文件),取 5 次运行的中位数:
| | OpenIDEA | IntelliJ IDEA 2026.2.3 |
| --------------------- | -------------- | ---------------------- |
| 显示项目窗口 | **0.9 s** | 3.1 s |
| 就绪(CPU 平稳) | **1.1 s** | 13.2 s |
| 内存(USS,所有进程) | **169 MB** | 2011 MB |
| 就绪前消耗的 CPU 时间 | **2.4 s** | 47.9 s |
| 空闲 CPU | 单核的 **4 %** | 单核的 7 % |
| 退出 | **0.3 s** | 5.9 s |
测试使用 `main` 分支的 OpenIDEA release 构建,以及默认设置和插件的 IDEA,环境为 Windows 11、32 核 AMD、62 GB 内存。IDEA 对 Python 的分析更深入,所以两边的“就绪”并不代表完成了同样多的工作。两者都以相同方式从外部测量:可以用 [`perf/compare`](https://github.com/l0ng-ai/openidea/blob/main/perf/compare) 在自己的机器和项目上复现。
## 下一步
<CardGroup cols={2}>
<Card title="安装" icon="download" href="/zh/guide/install">
下载 macOS、Windows 或 Linux 版 OpenIDEA。
</Card>
<Card title="快速上手" icon="rocket" href="/zh/guide/quickstart">
打开项目、熟悉界面、运行和调试。
</Card>
<Card title="从其他 IDE 迁移" icon="right-left" href="/zh/guide/migrate">
面向 IntelliJ IDEA、VS Code 和 Eclipse 用户的快捷键、设置导入和概念对照。
</Card>
<Card title="语言" icon="code" href="/zh/languages/index">
各语言支持哪些功能、需要安装什么。
</Card>
<Card title="插件" icon="puzzle-piece" href="/zh/plugins/index">
编写主题、语言和 WebAssembly 插件。
</Card>
<Card title="参与贡献" icon="code-branch" href="/zh/contribute/setup">
从源码构建 OpenIDEA 并提交 Pull Request。
</Card>
</CardGroup>
<Note>OpenIDEA 与 JetBrains 无关联。IntelliJ IDEA 是 JetBrains s.r.o. 的商标。</Note>
+10
View File
@@ -0,0 +1,10 @@
---
title: "插件市场"
description: "浏览 OpenIDEA 插件:来自社区和 OpenIDEA 团队的语言、框架、代码检查、主题、AI 和工具插件。"
mode: "custom"
---
import { pluginCatalog } from "/snippets/plugin-catalog.jsx";
import { Marketplace } from "/snippets/marketplace.jsx";
<Marketplace catalog={pluginCatalog} lang="zh" />
+1
View File
@@ -25,6 +25,7 @@
"gen:django-grammar": "lezer-generator src/editor/core/cm/django/django.grammar --typeScript -o src/editor/core/cm/django/parser.ts",
"gen:astro-grammar": "lezer-generator src/editor/core/cm/astro/astro.grammar --typeScript -o src/editor/core/cm/astro/parser.ts",
"gen:theme-docs": "node scripts/theme/gen-docs.ts",
"gen:plugin-catalog": "node scripts/gen-plugin-catalog.ts",
"theme:import-intellij": "node scripts/theme/import-intellij-theme.ts",
"dev:app": "node scripts/tauri.ts dev --config src-tauri/tauri.dev.conf.json",
"dev:status": "node scripts/dev-status.ts",
+93
View File
@@ -0,0 +1,93 @@
// Writes docs/snippets/plugin-catalog.jsx, the snapshot of the plugin marketplace the
// documentation site shows, from the release's plugins-index.json (or a local file).
//
// node scripts/gen-plugin-catalog.ts [index.json | url]
import { readFileSync, writeFileSync } from "node:fs";
import { fileURLToPath } from "node:url";
const OFFICIAL_INDEX = "https://github.com/l0ng-ai/openidea/releases/latest/download/plugins-index.json";
const OUT = fileURLToPath(new URL("../docs/snippets/plugin-catalog.jsx", import.meta.url));
interface IndexPlugin {
id: string;
name: string;
version: string;
description: string;
publisher: string;
categories?: string[];
icon?: { light: string | null; dark: string | null } | null;
homepage?: string | null;
downloads?: number | null;
}
interface Index {
publishers: { id: string; name: string }[];
plugins: IndexPlugin[];
}
async function load(source: string): Promise<Index> {
if (/^https?:\/\//.test(source)) {
const res = await fetch(source);
if (!res.ok) throw new Error(`${source}: HTTP ${res.status}`);
return (await res.json()) as Index;
}
return JSON.parse(readFileSync(source, "utf8")) as Index;
}
function compareVersions(a: string, b: string): number {
const pa = a.split(/[.-]/).map(Number);
const pb = b.split(/[.-]/).map(Number);
for (let i = 0; i < Math.max(pa.length, pb.length); i++) {
const d = (pa[i] || 0) - (pb[i] || 0);
if (d) return d;
}
return 0;
}
const svgUri = (svg: string) => `data:image/svg+xml;base64,${Buffer.from(svg).toString("base64")}`;
function icon(p: IndexPlugin) {
const light = p.icon?.light ?? p.icon?.dark;
const dark = p.icon?.dark ?? p.icon?.light;
if (!light || !dark) return null;
return light === dark ? { light: svgUri(light) } : { light: svgUri(light), dark: svgUri(dark) };
}
const index = await load(process.argv[2] ?? OFFICIAL_INDEX);
const publishers = new Map(index.publishers.map((p) => [p.id, p.name]));
const latest = new Map<string, IndexPlugin>();
for (const plugin of index.plugins) {
const seen = latest.get(plugin.id);
if (!seen || compareVersions(plugin.version, seen.version) > 0) latest.set(plugin.id, plugin);
}
const plugins = [...latest.values()]
// API examples document the plugin API; they are not offered to users here.
.filter((p) => !/\(API Example\)$/.test(p.name))
.map((p) => ({
id: p.id,
name: p.name,
version: p.version,
description: p.description,
publisher: publishers.get(p.publisher) ?? p.publisher,
official: p.publisher === "openidea",
categories: p.categories?.length ? p.categories : ["other"],
downloads: p.downloads ?? 0,
homepage: p.homepage ?? null,
icon: icon(p),
}))
.sort((a, b) => b.downloads - a.downloads || a.name.localeCompare(b.name));
const catalog = {
generatedAt: new Date().toISOString().slice(0, 10),
publishers: new Set(plugins.map((p) => p.publisher)).size,
plugins,
};
writeFileSync(
OUT,
`// Generated by scripts/gen-plugin-catalog.ts. Do not edit.\nexport const pluginCatalog = ${JSON.stringify(catalog)};\n`,
);
console.log(`${OUT}: ${plugins.length} plugins from ${catalog.publishers} publishers`);