🎄 Sync 2026-11-14 17:29:54

This commit is contained in:
github-actions[bot] committed 2026-11-14 17:29:54 +08:00
1 parent 00efd4e7cf
commit 4e24fe7535
123 files changed
+26051

No files matched your search

+70
View File
@@ -0,0 +1,70 @@
# APK 安装 / APK installation
## 中文
从 **v1.0.1** 开始,Release 中的 APK 使用 Carbon 固定公钥对应的私钥签名。每台设备只需导入一次公钥,后续可以直接通过 LuCI 上传安装或升级,无需每次 SSH。v1.0.0 的旧 APK 未签名,导入公钥后也不能直接上传安装,请重新下载新版。
> **最简单的方式:** 使用 Release 中的 `carbon-install.sh`。它内置签名 APK 和公钥,在独立的密钥目录中验签后通过 apk 安装,无需导入公钥,在线升级也可用。加 `--trust-key` 参数时会同时把公钥加入 `/etc/apk/keys`。下面的步骤用于在 LuCI 中手动上传 APK。
### 首次配置:优先通过网页导入公钥
1. 从 [Release](https://github.com/mrjoechen/luci-theme-carbon/releases/latest) 下载 `carbon-apk.pem` 和 `luci-theme-carbon-*.apk`。公钥也保存在仓库的 `keys/carbon-apk.pem`。
2. 切到 Carbon「专业」模式,在 **系统 → 管理权(Administration)→ 软件源公钥(Repo Public Keys)** 中,粘贴公钥文件的完整内容并点击「添加密钥」。有些版本也支持拖入公钥文件。此页面与 SSH 公钥页面不同。
3. 在 **系统 → 软件包 → 上传软件包** 中上传新版 `.apk` 并安装。重复安装相同版本时,如界面提供「重新安装」选项,可勾选它。
4. 刷新页面。首次安装更新器时,退出并重新登录 LuCI,使新增 RPC 权限生效;已有 v1.1.x 升级到 v1.1.2 或更新版本,只需刷新,无需退出。
菜单名称取决于固件翻译;较旧的 LuCI 可能没有公钥管理页。这种情况使用下面的一次性 SSH 配置,之后仍通过网页上传 APK。
### 旧版 LuCI:一次性 SSH 配置
下面命令先下载到临时目录,核对公钥文件的 SHA-256,再加入信任目录;不修改固件自带密钥,也不关闭签名校验。
```sh
(
set -eu
key=/tmp/carbon-apk.pem
wget -O "$key" https://github.com/mrjoechen/luci-theme-carbon/releases/download/v1.0.1/carbon-apk.pem
printf '%s %s\n' c5187568040b024559e6dddbd752c4661455b0ccfb94a66b013f05eb28ef9a0b "$key" | sha256sum -c -
mkdir -p /etc/apk/keys
cp "$key" /etc/apk/keys/carbon-apk.pem
chmod 644 /etc/apk/keys/carbon-apk.pem
)
```
路由器无法下载时,在电脑下载公钥后,用 SCP(例如 `scp -O carbon-apk.pem root@192.168.1.1:/tmp/`)传到 `/tmp`,跳过上面的 `wget`,继续校验和复制。公钥文件 SHA-256:
```text
c5187568040b024559e6dddbd752c4661455b0ccfb94a66b013f05eb28ef9a0b
```
固件升级时需要保留此公钥。可在 **系统 → 备份/升级 → 配置** 的保留文件列表加入 `/etc/apk/keys/carbon-apk.pem`;恢复出厂设置或不保留配置刷机后重新导入。卸载主题不会移除手动导入的公钥。不再信任本项目时,删除这一个公钥文件即可;不要删除官方密钥。APK 的信任是按密钥而不是按包名授权,请仅从本项目获取公钥和发布包。
### 排错
- **`UNTRUSTED signature`**:确认上传的是 v1.0.1 或更新 Release 的 APK,且已导入匹配的公钥。SDK 原始构建产物、Actions 的 `sdk-*` 临时产物以及旧 v1.0.0 APK 不带正式发布签名。必要时用 `apk verify /tmp/upload.apk` 检查(LuCI 安装结束可能已清理上传文件)。
- **`wget: exited with error 4` / `packages.adb: unexpected end of file`**:这是固件软件源索引下载失败,与 Carbon 签名无关。先在软件包页面尝试「更新列表」,检查路由器时间、DNS、WAN 和 HTTPS 连通性,以及软件源与当前 ImmortalWrt/OpenWrt 版本、target、架构是否匹配。不要混用两个发行版的软件源,也不要随意切到其它 snapshot 或发行版来解决依赖。签名修复不会修复软件源连接。
- **离线安装**:依赖已经安装时,可用 `apk add --repositories-file /dev/null /tmp/luci-theme-carbon-1.0.1-r1.apk` 跳过软件源,仅校验本地包。它仍验证签名,不需要 `--allow-untrusted`。标准 LuCI 上传流程没有通用的“忽略所有软件源”开关;要持续使用网页安装,应修复软件源问题。
- **`Read-only file system`**:系统根目录必须可写。这是容器或存储配置问题,与包签名不同。
## English
The simplest route is the release's `carbon-install.sh`: it embeds the signed APK and the public key, verifies the APK in a private key directory and installs it with apk — no key import needed, and online updates work. `--trust-key` additionally adds the key to `/etc/apk/keys`. The steps below are for manual LuCI uploads.
Release APKs are individually signed starting with **v1.0.1**. Import the Carbon public key once per device; subsequent installs and upgrades can use LuCI's package upload. The old v1.0.0 APK is unsigned and must be replaced with a new download.
1. Download `carbon-apk.pem` and the APK from [Releases](https://github.com/mrjoechen/luci-theme-carbon/releases/latest).
2. In Carbon's **Pro** mode, open **System → Administration → Repo Public Keys** if your firmware provides it. Paste the full public key and click **Add key**. This is separate from SSH authorized keys.
3. Open **System → Software → Upload Package**, select the APK and install. Select reinstall if the interface offers it when installing the same version again.
4. Refresh and log out/back in.
Older LuCI versions need a one-time SSH import: use the shell block above, which verifies the public PEM's SHA-256 before copying it to `/etc/apk/keys/carbon-apk.pem`. If the router cannot download the key, copy it from your computer to `/tmp/carbon-apk.pem` and skip `wget`. No global signature bypass is needed.
Add `/etc/apk/keys/carbon-apk.pem` to the backup file list in **System → Backup / Flash Firmware → Configuration** to retain it across upgrades. Re-import after a factory reset or an upgrade without preserved settings. Removing the theme does not remove this manually imported key. Delete only this key to revoke trust; preserve official keys. A trusted APK key is not restricted to a particular package name.
`UNTRUSTED signature` means the key is absent/mismatched, the file is an old unsigned release, or it is a raw SDK/Actions artifact. Use signed **Release assets**. `wget` / truncated `packages.adb` warnings are separate firmware repository download failures: check time, DNS, WAN, HTTPS, and firmware/target/architecture compatibility. Do not mix OpenWrt and ImmortalWrt feeds. If dependencies are already installed, the offline command above skips feeds while retaining signature verification; standard LuCI uploads still need working feed configuration. A read-only root filesystem must also be fixed separately.
## References
- [LuCI public-key management](https://github.com/openwrt/luci/blob/master/modules/luci-mod-system/htdocs/luci-static/resources/view/system/repokeys.js)
- [APK v3 signing](https://github.com/alpinelinux/apk-tools/blob/master/doc/apk-adbsign.8.scd)
- [APK trust directories and repository options](https://github.com/alpinelinux/apk-tools/blob/master/doc/apk.8.scd)
+44
View File
@@ -0,0 +1,44 @@
# Building signed APK releases
The SDK creates the APK; the release job then signs the **individual APK**, verifies it using only `keys/carbon-apk.pem`, and publishes it together with the public key, installation guide and `SHA256SUMS`. Signing only a repository index is insufficient for LuCI's local package upload.
## Maintainer setup
The production private key belongs in the repository's GitHub Actions secret **`APK_SIGNING_KEY`** (complete PEM content). It must match `keys/carbon-apk.pem`. Keep an encrypted backup outside the repository; `.private/` and `*.private.pem` are ignored as an extra precaution. Never commit the private key, print it in CI, or include it in artifacts. Ordinary builds and pull requests do not receive it. A release fails if the secret is missing or verification fails.
The existing project key is persistent: **do not generate a new key for each release**. Fork maintainers should generate their own key pair, replace the public key and its checksum, and update the installation guide's fingerprint and download URLs:
```sh
umask 077
mkdir -p .private keys
# For a NEW project/fork only. Do not overwrite an existing production key.
test ! -e .private/carbon-apk.private.pem &&
openssl genpkey -algorithm EC -pkeyopt ec_paramgen_curve:P-256 -out .private/carbon-apk.private.pem
openssl pkey -in .private/carbon-apk.private.pem -pubout -out keys/carbon-apk.pem
(cd keys && sha256sum carbon-apk.pem > SHA256SUMS)
```
Configure `APK_SIGNING_KEY` in **Settings → Secrets and variables → Actions**. With an authenticated GitHub CLI, the file can be supplied through stdin without printing it:
```sh
gh secret set APK_SIGNING_KEY < .private/carbon-apk.private.pem
```
After the secret is configured, push a version tag matching `PKG_VERSION`. The release job uses a pinned Alpine image with apk-tools 3, no container network, an ephemeral private-key file and a separate public-key trust directory. The private-key file is removed on exit. Only signed APKs enter the Release; `sdk-*` build artifacts remain unsigned development outputs. Existing published releases are not silently replaced.
## Local signing and validation
On a system with apk-tools 3:
```sh
sh scripts/sign-apk.sh .private/carbon-apk.private.pem keys/carbon-apk.pem dist/*.apk
apk --keys-dir keys verify dist/*.apk
```
The integration test needs apk-tools 3, OpenSSL and an unsigned SDK package. It creates disposable keys and checks rejection of unsigned packages, missing/mismatched keys, untrusted keys and damaged payloads, plus successful verification after signing:
```sh
sh tests/apk-signing.sh path/to/unsigned-sdk-package.apk
```
User setup: [APK installation](apk-install.md). If rotating a lost or compromised key, publish the new fingerprint and explicit import/revocation instructions; devices trusting the old key will not automatically trust the new one.
+68
View File
@@ -0,0 +1,68 @@
# Carbon online updates / 网页在线升级
## 使用
1. 首次手动安装 v1.1.0 或更新的原生 APK/IPK 包,退出并重新登录 LuCI,使新增 RPC 权限生效。
2. 打开「系统 → Carbon 主题」(v1.1.0 中名为「Carbon 更新」)。简洁和专业模式都有入口。
3. 点击「检查更新」,查看当前版本、最新稳定版和更新说明。
4. 点击「一键升级」,确认目标版本。后台执行下载、校验和安装,页面显示进度及日志;刷新页面不会取消安装。
5. 成功后点击「刷新页面」。升级到 v1.1.2 或更新版本时,主题自动刷新当前会话的菜单缓存,无需退出登录或重启路由器。
v1.1.0 / v1.1.1 的旧菜单名称缓存问题已在 v1.1.2 修复。可以直接从这两个版本通过网页升级到最新版,完成后刷新即可。首次安装更新器带来的新增 RPC 权限与菜单缓存不同,仍需按第 1 步重新登录一次。
更新保留 LuCI 语言、当前主题选择及浏览器中的浅色/深色、导航偏好。安装过程中请不要断电或同时操作其他软件包。安装失败时会显示原生包管理器日志;更新器不会声称自动回滚,也不会强制覆盖文件或忽略依赖。
更新说明以本地 Markdown 预览显示(v1.1.2 之后的版本),包括标题、列表、表格、引用、链接和代码块。原始 HTML 作为文本显示,不执行其中的脚本;链接在新标签页打开,状态轮询不会重建内容。
只读 LuCI 用户可以查看状态和检查更新,安装操作单独要求 `luci-theme-carbon-update` 的写权限。没有安装权限时升级按钮禁用。后台只接受已检查的目标版本,不接受浏览器传入下载地址、包路径、Shell 命令或密钥。
## 下载镜像(可选)
GitHub 下载缓慢或无法访问时,在同一页面的「下载镜像」中填写一个 HTTPS 前缀,例如 `https://mirror.example.com/`。下载地址变为前缀加原始链接:`https://mirror.example.com/https://github.com/mrjoechen/luci-theme-carbon/releases/download/…`。设置保存在 `/etc/config/carbon`(`carbon.update.mirror`),升级时保留。
- 镜像只用于下载安装包。版本、文件大小和 SHA-256 仍直接从 `api.github.com` 读取;镜像返回的文件必须与之完全一致,APK 还要通过签名校验。镜像无法篡改要安装的内容。
- 镜像失败或文件不一致时,自动改用 GitHub 直连;日志会显示每次尝试的来源。
- 只接受 `https://` 前缀,主机名和路径仅允许字母、数字及 `. _ ~ % + -`,最长 200 字符。留空即关闭。
- 检查更新本身仍需能访问 `api.github.com`。
## 签名与下载
- 固定来源:`mrjoechen/luci-theme-carbon` 的最新非草稿、非预发布 GitHub Release。
- APK:检查 GitHub 发布附件的 SHA-256、大小、实际包名和版本,再通过 `/usr/share/carbon/keys/carbon-apk.pem` 验证签名。安装时再次启用 APK 原生签名校验。没有 `--allow-untrusted`、自动下载新密钥或全局关闭验签的回退。
- 包内公钥仅用于 Carbon 更新器的独立信任目录,不会自动加入系统 `/etc/apk/keys`。标准 LuCI 上传仍按 [APK 配置说明](apk-install.md)导入公钥。
- APK 使用本地包及已安装依赖,跳过远端固件索引。缺失依赖时会失败,请先修复软件源并安装依赖。
- IPK:通过 HTTPS 获取发布元数据和包,核对 SHA-256、大小及包名/版本,使用原生 opkg 安装。IPK 不具有本项目 APK 的签名保证。
- 版本判断由设备原生包管理器执行,只允许更高版本;检查结果有效期为 30 分钟。
- 同一设备只运行一个任务。任务采用独立进程及文件锁,页面关闭或 rpcd 重载不会主动取消它。设备重启后临时状态会丢失;重新打开页面以包管理器中的实际版本为准。
## 常见问题
- **没有更新入口**:旧版未包含更新器,先安装新包并重新登录。确认 `rpcd` 已加载 `luci.carbon_update`。
- **提示「请先通过系统包管理器安装一次 Carbon」**:主题是复制文件安装的(`--files` 或 v1.1.3 之前的安装脚本),apk/opkg 中没有记录。重新运行一次当前的 `carbon-install.sh`:它会通过包管理器安装内置的签名包,无需导入公钥;也可以手动安装 APK/IPK。更新器本身不会把未登记的文件强制接管给包管理器。
- **缺少工具**:需要 `curl`、`ca-bundle` 和 `flock`,通常随包依赖安装。不要为解决 HTTPS 问题关闭证书校验。
- **下载失败**:检查路由器时间、DNS、外网和 GitHub 连通性;GitHub API 限流也会导致检查失败,稍后重试。
- **签名/校验失败**:没有执行安装。重新检查并下载;若持续失败,请提供错误和日志,不要禁用签名验证。
- **安装失败或中断**:查看日志及已安装版本。包管理器可能已部分执行,先处理其报错再重试;不要在安装过程中强行中止。
- **原始 SDK/Actions 临时产物**:在线更新只使用正式 Release 中的已签名 APK,不使用未签名的 CI 构建产物。
## English
Install the native v1.1.0+ APK/IPK once, then log out/back in to activate the newly added RPC permissions. Open **System → Carbon Theme Settings** (**Carbon Update** in v1.1.0), check for updates, review the notes and confirm **Install update**. Progress and logs survive page refreshes. When upgrading to v1.1.2 or later, reload after success; neither logout nor a router reboot is needed. Read-only users cannot install updates.
v1.1.2 refreshes LuCI's cached menu automatically when the Carbon version changes, including upgrades from v1.1.0 and v1.1.1. It preserves the login session and unrelated session data. First-time RPC permission activation still requires the initial login described above.
The updater only accepts newer stable releases from the fixed Carbon repository. It verifies size, SHA-256, package name/version and, for APK, the bundled Carbon public key. APK verifies the signature again during installation with the same isolated key directory and no firmware repository access. System trust settings are unchanged. IPK uses HTTPS, size and SHA-256 validation rather than APK signing. Existing dependencies must be available. Checks expire after 30 minutes, and a lock prevents overlapping updates.
Preferences and router configuration are retained. Installs made by copying files (`carbon-install.sh --files`, or installers before v1.1.3) are not registered with apk/opkg; run the current `carbon-install.sh` once, which installs the embedded signed package natively. Failed installations display logs and do not promise rollback; check the actual installed version before retrying. GitHub connectivity, correct system time, `curl`, `ca-bundle` and `flock` are required.
### Download mirror
If GitHub downloads are slow or blocked, set an optional HTTPS prefix under **Download mirror** on the same page (stored as `carbon.update.mirror` in `/etc/config/carbon`). The package URL becomes `<prefix>https://github.com/…`. Only the package bytes use the mirror: release metadata, size and SHA-256 still come from `api.github.com`, and APKs are signature-checked as before, so a mirror cannot change what gets installed. If the mirror fails or returns a mismatching file, the updater falls back to GitHub. Checking for updates still needs `api.github.com`.
## Maintainers
Publish version tags matching `Makefile`; GitHub Release asset names must remain `luci-theme-carbon-VERSION-rN.apk` and `luci-theme-carbon_VERSION-rN_all.ipk`. GitHub supplies each asset's SHA-256 digest through its release API. Upload APKs only after signing. Keep `root/usr/share/carbon/version` in sync with the package version and the bundled public key identical to `keys/carbon-apk.pem`. The CI checks both.
Run `python tests/update-integration.py` with Docker to test the production RPC script against OpenWrt's real APK manager, disposable signed packages and deterministic download fixtures. Signing and installation are never mocked. This suite checks bad signatures, bad checksums, incorrect metadata, network errors, expired requests, downgrades, concurrency, progress recovery, configuration preservation, mirror validation and fallback from a failing or tampered mirror.
Run `python tests/opkg-update.py` for the native OpenWrt 24.10 IPK upgrade regression, including legacy removal hooks that reset the theme. Both suites run before Release publication.
@@ -0,0 +1,47 @@
## English
### Install
| Firmware | Package manager | File |
|---|---|---|
| OpenWrt / ImmortalWrt 23.05, 24.10 | opkg | `luci-theme-carbon_*_all.ipk` |
| OpenWrt / ImmortalWrt 25.x, snapshot | apk | `luci-theme-carbon-*.apk` (signed) |
| Any of the above | apk or opkg | `carbon-install.sh` |
**Install script.** Run on the router. It installs the signed APK or the IPK through apk/opkg, so online updates work and no key import is needed:
```sh
wget -O /tmp/carbon-install.sh https://github.com/@REPOSITORY@/releases/latest/download/carbon-install.sh && sh /tmp/carbon-install.sh
```
Add `--trust-key` to also trust Carbon's key for LuCI package uploads, or `--files` to only copy the files.
**Upload in LuCI (apk).** Import the attached `carbon-apk.pem` once in System → Administration → Repo Public Keys, then upload the APK in System → Software. The attached `APK-INSTALL.md` covers firmware without that page.
**Online updates.** Once installed through apk/opkg, System → Carbon Theme Settings checks and installs new releases. APK signatures stay verified; IPK downloads are checked against this release's SHA-256 and size.
After a first install, log out and back in once so the dashboard and settings permissions take effect.
## 简体中文
### 安装
| 固件 | 包管理器 | 文件 |
|---|---|---|
| OpenWrt / ImmortalWrt 23.05、24.10 | opkg | `luci-theme-carbon_*_all.ipk` |
| OpenWrt / ImmortalWrt 25.x、snapshot | apk | `luci-theme-carbon-*.apk`(已签名) |
| 以上任意固件 | apk 或 opkg | `carbon-install.sh` |
**安装脚本。** 在路由器上执行。脚本通过 apk/opkg 安装已签名的 APK 或 IPK,在线升级可用,无需导入公钥:
```sh
wget -O /tmp/carbon-install.sh https://github.com/@REPOSITORY@/releases/latest/download/carbon-install.sh && sh /tmp/carbon-install.sh
```
加 `--trust-key` 可同时信任 Carbon 公钥(用于在 LuCI 上传软件包),加 `--files` 只复制文件。
**在 LuCI 上传(apk)。** 首次在「系统 → 管理权 → 软件源公钥」导入附件 `carbon-apk.pem`,之后在「系统 → 软件包」上传 APK。没有该页面的固件请参考附件 `APK-INSTALL.md`。
**在线升级。** 通过 apk/opkg 安装后,可在「系统 → Carbon 主题」检查并安装新版本。APK 保留签名校验;IPK 按本版本公布的 SHA-256 和文件大小校验。
首次安装后请退出并重新登录一次,让仪表盘和设置页的权限生效。
+15
View File
@@ -0,0 +1,15 @@
### v1.1.1
- 将「Carbon 更新」统一更名为「Carbon 主题设置」,同步菜单、页面标题、中英文文案和使用说明。
- 左侧菜单改用 Carbon 六边形与中心圆点的单色线框图标,与其他菜单的尺寸、线宽和状态配色一致,简洁与专业模式均生效。
- 沿用原 Carbon APK 签名公钥,升级继续验证签名、SHA-256 和文件大小。
**从 v1.1.0 升级:** 打开「系统 → Carbon 更新」,点击「检查更新」,确认目标为 `1.1.1-r1`,然后点击「一键升级」并确认。完成后刷新页面,入口变为「Carbon 主题设置」。无需重新导入公钥;主题与语言偏好保留。
**English:** Renames Carbon Update to Carbon Theme Settings and uses a monochrome Carbon outline icon matching the other navigation icons in Simple and Pro modes. From v1.1.0, open **System → Carbon Update → Check for updates → Install update**, confirm `1.1.1-r1`, and reload after completion. The existing signing key and signature verification remain in use; theme and language preferences are retained.
**菜单缓存提示:** 升级后若菜单或面包屑仍显示 `Carbon Update` /「Carbon 更新」,请退出并重新登录 LuCI 一次,清除旧会话菜单缓存。无需重新安装或重新导入公钥。
**发布后验证:** 在隔离的 OpenWrt 25.12.6(APK)与 24.10.8(IPK)中,从未经修改的 v1.1.0 正式包,通过 LuCI 网页发现并安装 v1.1.1 正式发布包,均成功升级至 `1.1.1-r1`。APK 签名校验通过;主题与中文配置保留。重新登录后两种模式均显示新名称与线框图标。
**Verification:** Both original v1.1.0 Release packages successfully discovered and installed the published v1.1.1 through LuCI in isolated OpenWrt 25.12.6 (APK) and 24.10.8 (IPK) environments. APK signature verification passed and theme/language settings were preserved. If the old menu name remains, log out and back in once to clear LuCI's session menu cache; no reinstall or key import is needed.
+10
View File
@@ -0,0 +1,10 @@
### v1.1.2
- 升级后无需退出登录:检测 Carbon 版本变化,自动刷新 LuCI 菜单缓存;成功页的「刷新页面」也会清理菜单缓存。登录状态、主题与语言偏好保留。
- 修复移动端多页面 luci-app 的顶部导航:自动将当前子页面滚动到可见位置,支持嵌套页面、异步生成的表单标签和屏幕尺寸变化。
- 自动定位仅滚动标签栏,不移动输入焦点或垂直页面;不会在普通状态刷新时打断手动滑动。
- 继续使用原有 Carbon 公钥及 APK 原生签名校验,无需重新导入密钥。
**升级:** 在「系统 → Carbon 主题设置」点击「检查更新」和「一键升级」,成功后点击「刷新页面」。v1.1.0 的入口仍叫「Carbon 更新」。首次安装更新器新增 RPC 权限时,仍需重新登录一次。
**English:** Refresh after upgrading without logging out. Carbon invalidates only the menu cache when its version changes. Mobile route and form tabs now reveal the active page, including nested and dynamically inserted tabs, without moving keyboard focus or scrolling the document. The existing APK signing key and native signature checks remain in use. First-time installation of the updater still requires a new login to activate its RPC permissions.
+17
View File
@@ -0,0 +1,17 @@
### v1.1.3
- **更轻的概览页:** 「详细状态」收起时暂停 LuCI 原生状态组件的轮询,路由器不再被重复查询;展开后恢复。
- **在线设备更准确:** 合并 DHCPv4/v6 租约、Wi‑Fi 关联列表和 ARP 邻居,固定 IP 设备也能显示;Wi‑Fi 设备显示频段和信号强度,名称来自 LuCI 主机信息。
- **IPv6 与流量:** 概览显示外网 IPv6 地址;「实时流量」可选择统计的接口(自动跟随 WAN,或指定 LAN 等)。
- **温度:** 读取所有热区和 hwmon 传感器(CPU、SoC、无线芯片、x86 coretemp),最多显示三项。
- **多语言:** 主题文案改用标准 gettext(`po/`),新增繁体中文;侧栏语言切换列出所有已安装的 LuCI 语言(超过两种时使用下拉框,可选「自动」),不再把其他语言覆盖为英文。
- **下载镜像:** 「Carbon 主题设置」可填写 HTTPS 镜像前缀。只用于下载安装包,版本、大小和 SHA-256 仍以 GitHub 为准;镜像失败自动改用 GitHub。
- **无障碍:** 手机抽屉菜单打开时锁定背景并管理焦点;分段按钮支持方向键;收起的侧栏在触屏上点按展开子菜单,键盘可用 Enter / → 进入、Esc 返回。
- **安装脚本走包管理器:** `carbon-install.sh` 内置签名 APK、IPK 和公钥,通过 apk/opkg 安装,在线升级可用,无需手动导入公钥(APK 在独立密钥目录中验签,不修改 `/etc/apk/keys`)。重新运行即可把旧版脚本安装转为正式安装;`--trust-key` 可同时信任公钥,`--files` 保留原来的复制文件方式。离线且缺少依赖时自动改为复制文件。
- **体积:** 发布包中的 CSS/JS 经过压缩(约小 20%),源码保持可读。
**升级:** 新增的仪表盘数据(Wi‑Fi 关联、ARP、主机信息、全部温度传感器)需要新的 RPC 权限,升级后**退出并重新登录一次**才会显示;未重新登录前仪表盘按原方式工作。
**以前用安装脚本安装、页面提示「请先通过系统包管理器安装一次 Carbon」的设备:** 重新运行一次本版本的 `carbon-install.sh`,之后即可在网页一键升级,无需导入公钥。
**English:** The overview pauses LuCI's own status polling while its details are collapsed. Connected devices now merge DHCPv4/v6 leases, Wi‑Fi stations (band and signal) and ARP neighbours, so static-IP clients appear. The hero shows the WAN IPv6 address, live traffic can follow any interface, and all thermal/hwmon sensors are read. Theme strings use gettext catalogues (`po/`) with a new Traditional Chinese translation, and the language switch lists every installed LuCI language. The updater accepts an optional HTTPS download mirror; metadata and SHA-256 still come from GitHub, with automatic fallback. Accessibility improves for the phone drawer, segmented controls and the collapsed rail on touch and keyboard. `carbon-install.sh` now embeds the signed APK, the IPK and the public key and installs through apk/opkg, so script installs get online updates without importing a key (the APK is verified in a private key directory); rerunning it converts older script-only installs. `--trust-key` also trusts the key for LuCI uploads, `--files` keeps the copy-only mode. Release assets are minified. Log out and back in once after upgrading to grant the new dashboard permissions. Devices that show "install Carbon through the package manager" after a script install: run this release's `carbon-install.sh` once to enable online updates.
+35
View File
@@ -0,0 +1,35 @@
## English
### What's new
- **Custom logo.** Upload a PNG, JPEG, WebP, GIF or SVG (up to 256 KB) in System → Carbon Theme Settings. It replaces the logo in the sidebar, on the login page, on the overview and in the browser tab, and is kept across theme updates and firmware upgrades that keep settings. SVGs with scripts, event handlers or embedded documents are rejected.
- **Ten more languages.** German, Spanish, French, Italian, Japanese, Korean, Brazilian Portuguese, Russian, Turkish and Vietnamese, alongside English and Simplified and Traditional Chinese.
- **Language menu.** With more than two languages installed, the sidebar shows a Carbon-styled list instead of the browser's own select. It works with keyboard (arrows, type-ahead, Esc) and touch, and opens beside the collapsed rail.
- **Live traffic.** Physical network devices, such as an xPON port carrying several VLANs, can be picked in addition to interfaces.
- **Docker.** The Docker menu uses a whale icon, and each Docker page has its own icon.
- **Plugins.** The DiskMan partition bar fits its card on desktops and phones; the ttyd terminal fills the window.
- **Carbon Theme Settings.** Buttons, links and fields line up on one line, and the download-mirror explanation opens from a "?" hint.
- **Login page.** Shows the logo and hostname only, without the device model.
- **Smaller package.** Despite the new languages, the package is smaller than 1.1.3: release notes are rendered by a small built-in renderer instead of a bundled Markdown library.
### Upgrade notes
- If uploading a logo reports *Permission denied*, log out and back in once.
## 简体中文
### 更新内容
- **自定义 Logo。** 在「系统 → Carbon 主题」上传 PNG、JPEG、WebP、GIF 或 SVG(不超过 256 KB),替换侧栏、登录页、概览页和浏览器标签上的 Logo;主题升级和保留配置的固件升级后仍会保留。含脚本、事件处理或嵌入文档的 SVG 会被拒绝。
- **新增十种语言。** 德语、西班牙语、法语、意大利语、日语、韩语、巴西葡萄牙语、俄语、土耳其语和越南语,加上原有的英文、简体中文和繁体中文。
- **语言菜单。** 安装了两种以上语言时,侧栏使用与主题风格一致的下拉列表,不再使用浏览器自带的下拉框;支持键盘(方向键、首字母跳转、Esc)和触屏,侧栏收起时在旁边弹出。
- **实时流量。** 除接口外,还可以选择物理网络设备,例如承载多个 VLAN 的 xPON 光口。
- **Docker。** Docker 菜单使用鲸鱼图标,各个 Docker 页面也有各自的图标。
- **插件适配。** DiskMan 分区条在电脑和手机上都不再超出卡片;ttyd 终端铺满窗口。
- **Carbon 主题页面。** 菜单项「Carbon 主题设置」更名为「Carbon 主题」;按钮、链接和输入框对齐在同一行,下载镜像的说明收进「?」提示中。
- **登录页。** 只显示 Logo 和主机名,不再显示设备型号。
- **安装包更小。** 虽然新增了多种语言,安装包仍比 1.1.3 小:更新说明改用内置的小型渲染器显示,不再打包完整的 Markdown 库。
### 升级须知
- 如果上传 Logo 时提示「权限不足」,请退出并重新登录一次。
+33
View File
@@ -0,0 +1,33 @@
## English
### What's new
- **Side-router device discovery.** Fix LAN neighbours being omitted when LAN obtains its own address by DHCP. Device discovery continues to combine DHCP leases, Wi-Fi associations and IPv4 ARP neighbours with the local DHCP server disabled. Recognisable separate uplinks are excluded; ambiguous custom interfaces are retained. Addresses [issue #3](https://github.com/mrjoechen/luci-theme-carbon/issues/3).
- **Clearer device information.** The overview now says "Discovered devices": lease records and neighbour caches may include offline devices and do not represent every device on the network. Gateways, neighbour entries and DHCP leases are labelled separately, instead of assuming that a missing local lease means a fixed IP. Labels are translated into all bundled languages and wrap on phones to preserve room for device names.
- **Dashboard data permissions.** Allow ARP and temperature readings through their resolved procfs/sysfs paths, fixing missing data on systems whose rpcd checks those paths.
- **Traffic selector.** Use the Carbon listbox for the live-traffic interface picker, with grouped choices and keyboard support. Listboxes stay open when a page update triggers a scroll without moving the control.
- **Layout.** Use more space for dashboards and tables on wide screens, with two columns of devices where space permits. Improve phone layouts for menus, tables and dashboard content.
- **Device brands.** Show brand logos in LuCI's native lease tables as well as the overview, and add Midea and Haier device badges.
- **Dark mode.** Fix the colour of enabled switches.
### Upgrade notes
- After upgrading, log out of LuCI and back in once so the updated dashboard permissions take effect, especially if ARP devices or temperatures are missing.
- "Discovered devices" is based on data visible to this router. It may contain offline records and cannot guarantee a complete live count of the network.
## 简体中文
### 更新内容
- **旁路由设备发现。** 修复 LAN 自身通过 DHCP 获取地址时,邻居设备被遗漏的问题。关闭本机 DHCP 服务后,仍通过 DHCP 租约、Wi-Fi 关联列表与 IPv4 ARP 邻居合并发现设备;排除可识别的独立上联接口,对角色不明确的自定义接口保留发现结果。对应 [issue #3](https://github.com/mrjoechen/luci-theme-carbon/issues/3)。
- **设备信息更准确。** 概览改为“已发现设备”:租约和邻居缓存可能包含离线设备,也不代表全网所有设备。明确区分网关、邻居记录和 DHCP 租约,不再将缺少本机租约的设备一律标为固定 IP。同步全部内置语言,手机端标签换行,避免挤压设备名称。
- **仪表盘数据权限。** 补充 ARP 与温度文件解析后的 procfs/sysfs 实际路径权限,修复部分 rpcd 版本下无法读取数据的问题。
- **流量接口选择。** 实时流量的接口选择改为 Carbon 样式列表,支持选项分组与键盘操作;页面更新引起滚动、但控件位置未改变时,下拉列表不再意外关闭。
- **布局优化。** 宽屏下的仪表盘和表格充分利用空间,设备列表在空间足够时显示为两列;改善手机端菜单、表格与仪表盘内容的布局。
- **设备品牌。** LuCI 原生租约表也显示品牌图标,新增美的和海尔设备标识。
- **深色模式。** 修复开关启用状态的颜色。
### 升级须知
- 升级后请退出 LuCI 并重新登录一次,让更新后的仪表盘权限生效;尤其适用于 ARP 设备或温度信息缺失的情况。
- “已发现设备”来自本机可见的数据,可能包含离线记录,不能保证完整的全网实时在线数量。