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
21 changes: 21 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,27 @@

All notable changes to the Git Integration plugin are documented in this file. The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/) and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## 0.1.5

### Added

- Vector icons across the panel. The stage, unstage, stage-all, and refresh controls are now Lucide icons instead of the `+`, `-`, and `⟳` characters, and every file row leads with an icon for its kind of change.
- Coloured file status. The Git status code of each file is now drawn in the colour of that change — added is green, modified is yellow, deleted is red, untracked is cyan, renamed is blue, and a conflict is orange.
- Tooltips on the icon controls and on the status code, naming the action and the kind of change.
- A **License** page in the plugin information, which carries the plugin's own MIT licence and the notices for the bundled icon artwork.
- `package/plugin_pages/LICENSE` ships the plugin's licence inside the archive, and `package/plugin_pages/license.md` reproduces that licence together with the third-party notices as the plugin's License page. ISC and MIT both require their notice to travel with every copy, so a notice that only lived in the repository would not satisfy them.

### Changed

- The icon artwork is embedded in the plugin and rasterized at runtime through the Engine's LunaSVG backend. The package stays a single deterministic archive, and one vector asset can be drawn in any colour.
- The status code keeps its Git spelling, so a dual state such as `AM` stays readable next to its icon.

### Dependencies

- **The panel now depends on an undocumented Engine capability.** The icons are rasterized at runtime through the Engine's LunaSVG-backed texture loader, which is not part of the documented plugin API. Vector artwork could not previously be shipped inside a plugin at all, because ImGui only draws raster textures.
- If that capability is removed or changed in a future Engine release, the icons stop rendering and the panel falls back to text-only controls. Everything else in the panel keeps working, and the status codes stay readable.
- The plugin needs no build-time conversion step and no pre-rendered PNG per colour, but it does need an Engine release that still ships the SVG rasterizer.

## 0.1.4

### Fixed
Expand Down
21 changes: 21 additions & 0 deletions CHANGELOG.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,27 @@

Git 集成插件的所有重要变更都记录在本文件中。格式遵循 [Keep a Changelog](https://keepachangelog.com/zh-CN/1.1.0/),版本号遵循[语义化版本](https://semver.org/lang/zh-CN/)。

## 0.1.5

### 新增

- 面板全面使用矢量图标。暂存、取消暂存、暂存全部和刷新按钮改用 Lucide 图标,不再是 `+`、`-`、`⟳` 这几个字符;每个文件行前也会显示一个表示变更类型的图标。
- 文件状态着色。每个文件的 Git 状态码现在按变更类型着色——新增为绿色,修改为黄色,删除为红色,未跟踪为青色,重命名为蓝色,冲突为橙色。
- 图标按钮和状态码上增加了悬浮提示,说明该操作和该变更类型。
- 插件信息里新增**许可证**页面,承载插件自身的 MIT 许可证和内置图标素材的第三方声明。
- `package/plugin_pages/LICENSE` 让插件的许可证随归档分发,`package/plugin_pages/license.md` 则在同一页里复现该许可证和第三方声明。ISC 与 MIT 都要求声明必须跟在素材的每一份副本里,只放在仓库里的声明无法满足这一条。

### 变更

- 图标素材内嵌在插件中,并在运行时通过引擎的 LunaSVG 后端光栅化。插件包仍然是一个确定性的归档,同一份矢量素材可以以任意颜色绘制。
- 状态码保留 Git 原本的写法,因此像 `AM` 这样的双状态在图标旁边依然可读。

### 依赖

- **面板现在依赖一项未公开的引擎能力。** 图标在运行时通过引擎基于 LunaSVG 的纹理加载器光栅化,这项能力并不属于已公开的插件 API。在此之前,插件根本无法内嵌矢量素材——ImGui 只能绘制光栅纹理。
- 如果未来的引擎版本移除或改动了这项能力,图标将无法渲染,面板会退回到纯文字控件。面板的其余功能不受影响,状态码依然可读。
- 插件不需要任何构建期转换步骤,也不需要为每种颜色预渲染 PNG,但需要引擎仍随附 SVG 光栅化器。

## 0.1.4

### 修复
Expand Down
7 changes: 7 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,3 +53,10 @@ python package.py build dist/plugin.inxpkg && python package.py verify dist/plug
- Every `git` call must pass `cwd=` explicitly so the panel always operates on the folder open in the Editor.
- Use `subprocess.run` with a timeout. The render thread must never block indefinitely.
- Panel state that survives a render lives on the instance; it is never stored in a module-level global.

## Icons and artwork

- Icons come from [Lucide](https://lucide.dev), which is free for commercial use under the ISC License. The geometry lives in `package/editor/wokrlie/git_integration/icons.py`.
- Icons are embedded in the module rather than shipped as files, so the plugin never depends on where its package is unpacked and the build stays byte-for-byte deterministic.
- Any new artwork must come from a permissive licence and be recorded in `package/plugin_pages/license.md` before it ships. That page is the plugin's License page in the editor, so the notice travels with every installed copy.
- The icons are rasterized at runtime through the Engine's LunaSVG backend. ImGui itself cannot draw SVG, so do not expect the vector source to reach the renderer.
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@ A source control panel for the [Infernux Engine](https://github.com/ChenlizheMe/
- Commit flow with a persistent message buffer and empty-message validation.
- Automatic refresh of the file lists, plus a manual refresh button.
- Files with a dual status (for example `AM`) appear in both lists, matching `git status`.
- Vector icons for the stage, unstage, stage-all, and refresh controls, plus a status icon and a coloured status code on every file row.
- Localized panel UI in English and Simplified Chinese.
- The plugin's own licence and the notices for the bundled icon artwork ship with the plugin and are shown on the **License** page of the plugin information.

## Requirements

Expand All @@ -26,6 +28,8 @@ A source control panel for the [Infernux Engine](https://github.com/ChenlizheMe/

Git is a **runtime requirement**. The panel shells out to the `git` executable; when it is missing, the panel shows a short notice instead of the file lists.

The icons are vector artwork that the Editor rasterizes at runtime. That relies on the Engine's LunaSVG-backed texture loader, which is not part of the documented plugin API — if a future Engine release drops it, the panel falls back to text-only controls and everything else keeps working.

## Installation

### From a release
Expand Down Expand Up @@ -84,7 +88,10 @@ The Editor-only code lives in `package/editor/`, and the runtime surface in `pac
| [ROADMAP.md](ROADMAP.md) | Planned features |
| [CONTRIBUTING.md](CONTRIBUTING.md) | Contribution and commit conventions |
| [RELEASING.md](RELEASING.md) | Release procedure |
| [package/plugin_pages/license.md](package/plugin_pages/license.md) | Plugin licence and third-party notices for the bundled artwork |

## License

[MIT](LICENSE).

The same licence text and the notices for the bundled icon artwork ship inside the plugin archive, on the **License** page of the plugin information.
5 changes: 5 additions & 0 deletions README.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@
- 提交流程:消息缓冲区持久保留,空消息会被拦截。
- 文件列表自动刷新,并提供手动刷新按钮。
- 双状态文件(例如 `AM`)会同时出现在两个列表中,与 `git status` 的行为一致。
- 暂存、取消暂存、暂存全部和刷新按钮使用矢量图标;每个文件行还带有状态图标和带颜色的状态码。
- 面板界面支持英文与简体中文。
- 插件自身的许可证和内置图标素材的第三方声明随插件一起分发,可在插件信息的**许可证**页面查看。

## 环境要求

Expand Down Expand Up @@ -84,7 +86,10 @@ python package.py verify dist/plugin.inxpkg # 校验构建产物
| [ROADMAP.md](ROADMAP.md) | 后续计划 |
| [CONTRIBUTING.md](CONTRIBUTING.md) | 贡献与提交规范 |
| [RELEASING.md](RELEASING.md) | 发布流程 |
| [package/plugin_pages/license.md](package/plugin_pages/license.md) | 插件许可证与内置素材的第三方声明 |

## 许可证

[MIT](LICENSE)。

同一份许可证文本和内置图标素材的第三方声明也随插件归档一起分发,可在插件信息的**许可证**页面查看。
8 changes: 4 additions & 4 deletions RELEASING.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Releases are produced by GitHub Actions. No artifact is uploaded by hand.
| Engine compatibility | `package/inx_package.json` → `engine` |
| Release notes | `CHANGELOG.md` and `CHANGELOG.zh-CN.md` |

The release tag must match the manifest version exactly — `v0.1.4` for version `0.1.4`. `package.py release-manifest` fails on any mismatch, so a mistyped tag stops the release instead of publishing a mislabelled archive.
The release tag must match the manifest version exactly — `v0.1.5` for version `0.1.5`. `package.py release-manifest` fails on any mismatch, so a mistyped tag stops the release instead of publishing a mislabelled archive.

## Procedure

Expand All @@ -19,8 +19,8 @@ The release tag must match the manifest version exactly — `v0.1.4` for version
3. Tag the merge commit and push the tag:

```bash
git tag v0.1.4
git push origin v0.1.4
git tag v0.1.5
git push origin v0.1.5
```

4. The `release` job runs on the tag. It builds the archive, verifies it, checks that two independent builds are byte-identical, generates `infernux-plugin-release.json`, and publishes both files as GitHub Release assets.
Expand All @@ -44,7 +44,7 @@ Because of this, a fix for a published version needs a **new** version number. N
python package.py build dist/wokrlie.git_integration.inxpkg
python package.py verify dist/wokrlie.git_integration.inxpkg
python package.py release-manifest dist/wokrlie.git_integration.inxpkg \
--tag v0.1.4 --output dist/infernux-plugin-release.json
--tag v0.1.5 --output dist/infernux-plugin-release.json
```

The build is deterministic: running it twice over the same source must produce byte-identical archives, which is what CI asserts before it publishes anything.
1 change: 0 additions & 1 deletion ROADMAP.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ Planned work for the Git Integration plugin. Delivered changes are recorded in [
## Next

- **Branch display and switching** — show the current branch, and let the user switch or create branches from the panel.
- **File status coloring** — distinguish Modified / Added / Deleted / Untracked entries in both file lists.
- **Discard changes** — revert the unstaged modifications of a single file.
- **Push / Pull controls** — fetch, pull, and push without leaving the Editor.
- **Diff preview** — show the content diff of a tracked file.
Expand Down
26 changes: 24 additions & 2 deletions package/editor/translations.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,18 @@
"wokrlie.git_integration.create_repository": "Create Git Repository",
"wokrlie.git_integration.not_a_repository": "This folder is not a Git repository yet.",
"wokrlie.git_integration.repository_folder": "Repository folder",
"wokrlie.git_integration.git_unavailable": "Git is not usable in the current environment."
"wokrlie.git_integration.git_unavailable": "Git is not usable in the current environment.",
"wokrlie.git_integration.refresh": "Refresh now",
"wokrlie.git_integration.stage_file": "Stage this file",
"wokrlie.git_integration.unstage_file": "Unstage this file",
"wokrlie.git_integration.status_added": "Added",
"wokrlie.git_integration.status_modified": "Modified",
"wokrlie.git_integration.status_deleted": "Deleted",
"wokrlie.git_integration.status_renamed": "Renamed",
"wokrlie.git_integration.status_copied": "Copied",
"wokrlie.git_integration.status_conflicted": "Conflicted",
"wokrlie.git_integration.status_untracked": "Untracked",
"wokrlie.git_integration.status_ignored": "Ignored"
},
"zh": {
"wokrlie.git_integration.menu_root": "Git 集成",
Expand All @@ -29,7 +40,18 @@
"wokrlie.git_integration.create_repository": "创建 Git 仓库",
"wokrlie.git_integration.not_a_repository": "当前文件夹还不是 Git 仓库。",
"wokrlie.git_integration.repository_folder": "仓库目录",
"wokrlie.git_integration.git_unavailable": "当前环境无法使用 Git。"
"wokrlie.git_integration.git_unavailable": "当前环境无法使用 Git。",
"wokrlie.git_integration.refresh": "立即刷新",
"wokrlie.git_integration.stage_file": "暂存此文件",
"wokrlie.git_integration.unstage_file": "取消暂存此文件",
"wokrlie.git_integration.status_added": "已添加",
"wokrlie.git_integration.status_modified": "已修改",
"wokrlie.git_integration.status_deleted": "已删除",
"wokrlie.git_integration.status_renamed": "已重命名",
"wokrlie.git_integration.status_copied": "已复制",
"wokrlie.git_integration.status_conflicted": "存在冲突",
"wokrlie.git_integration.status_untracked": "未跟踪",
"wokrlie.git_integration.status_ignored": "已忽略"
}
}
}
Loading
Loading