harmonyos-skills-pack 0.1.2 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +39 -9
- package/bin/cli.js +7 -0
- package/package.json +5 -1
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 yibaiba
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
[](https://www.npmjs.com/package/harmonyos-skills-pack)
|
|
4
4
|
[](https://github.com/yibaiba/harmonyos-skills-pack/releases)
|
|
5
5
|
|
|
6
|
-
Current Version: 0.1.
|
|
6
|
+
Current Version: 0.1.3
|
|
7
7
|
|
|
8
8
|
这是一个面向 Claude、GitHub Copilot、Codex 等 Coding Agent 的可安装 Skills 项目。
|
|
9
9
|
|
|
@@ -20,7 +20,7 @@ Current Version: 0.1.1
|
|
|
20
20
|
|
|
21
21
|
## 包含内容
|
|
22
22
|
|
|
23
|
-
|
|
23
|
+
当前版本包含两个核心技能和一个子技能:
|
|
24
24
|
|
|
25
25
|
### 1. harmonyos-ark
|
|
26
26
|
|
|
@@ -30,17 +30,28 @@ Current Version: 0.1.1
|
|
|
30
30
|
- 网络请求、本地存储、媒体与设备能力
|
|
31
31
|
- 测试、签名、打包、上架发布
|
|
32
32
|
- 2025 创作激励与审核避坑
|
|
33
|
-
- Starter Kit
|
|
33
|
+
- Starter Kit 极速实现包(16 模块)
|
|
34
34
|
|
|
35
|
-
其中 starter-kit 已包含
|
|
35
|
+
其中 starter-kit 已包含 16 个模块模板:
|
|
36
36
|
|
|
37
37
|
- 登录模块、单机离线/免登录、游客升级登录同步
|
|
38
|
-
- 列表页、详情页、表单页、TabBar
|
|
38
|
+
- 列表页、详情页、表单页、TabBar 导航、抽屉导航
|
|
39
39
|
- 深色模式与多端适配模板
|
|
40
|
+
- 状态管理最佳实践
|
|
40
41
|
- 本地数据持久化、后台任务、通知处理
|
|
41
42
|
- WebSocket 实时通信、相机与媒体、支付与计费
|
|
42
43
|
- Day-by-Day 执行顺序与提审前清单
|
|
43
44
|
|
|
45
|
+
#### 1.1 arkts-modernization-guard(子技能)
|
|
46
|
+
|
|
47
|
+
ArkTS 编译现代化守卫,自动扫描代码中的已知坑:
|
|
48
|
+
|
|
49
|
+
- 9 条扫描规则(P0/P1/P2 分级)
|
|
50
|
+
- 自动检测 `@Prop` 函数回调、`FontWeight.Black`、deprecated API 等
|
|
51
|
+
- 15+ 错误码→修复方案映射表
|
|
52
|
+
- 9 个 diff 格式代码替换模板
|
|
53
|
+
- bash 扫描脚本,可集成 CI/CD
|
|
54
|
+
|
|
44
55
|
### 2. universal-product-quality
|
|
45
56
|
|
|
46
57
|
面向项目无关的通用产品质量校验,覆盖:
|
|
@@ -146,12 +157,17 @@ cd harmonyos-skills-pack
|
|
|
146
157
|
|
|
147
158
|
## 项目结构说明
|
|
148
159
|
|
|
149
|
-
- .claude/skills/
|
|
150
|
-
- Claude 标准技能入口目录
|
|
151
|
-
- .github/skills/
|
|
152
|
-
- Copilot 标准技能入口目录
|
|
153
160
|
- skills/
|
|
154
161
|
- 内容维护目录,作为 canonical source
|
|
162
|
+
- harmonyos-ark/ — 鸿蒙 Ark 开发技能(52 主题 + starter-kit + 清单)
|
|
163
|
+
- arkts-modernization-guard/ — ArkTS 编译现代化守卫(子技能)
|
|
164
|
+
- universal-product-quality/ — 通用产品质量检查技能
|
|
165
|
+
- .claude/skills/
|
|
166
|
+
- Claude 标准技能入口目录(由 sync-skills.sh 生成)
|
|
167
|
+
- .github/skills/
|
|
168
|
+
- Copilot 标准技能入口目录(由 sync-skills.sh 生成)
|
|
169
|
+
- bin/
|
|
170
|
+
- npx CLI 安装器
|
|
155
171
|
- scripts/
|
|
156
172
|
- 安装、卸载、同步、校验、发布脚本
|
|
157
173
|
- releases/
|
|
@@ -208,6 +224,20 @@ ArkUI 状态管理、页面路由和生命周期要分别看哪些主题文档
|
|
|
208
224
|
帮我按 ArkTS 规范检查命名、类型使用、装饰器边界、异步错误处理和依赖方向
|
|
209
225
|
```
|
|
210
226
|
|
|
227
|
+
### ArkTS 编译错误排查
|
|
228
|
+
|
|
229
|
+
```text
|
|
230
|
+
编译报错 10505001,帮我定位根因和修复方案
|
|
231
|
+
```
|
|
232
|
+
|
|
233
|
+
```text
|
|
234
|
+
帮我扫描项目中的 deprecated API 和已知编译坑,给出替换建议
|
|
235
|
+
```
|
|
236
|
+
|
|
237
|
+
```text
|
|
238
|
+
运行 arkts-modernization-guard 扫描,检查是否有 @Prop 回调、FontWeight.Black 等问题
|
|
239
|
+
```
|
|
240
|
+
|
|
211
241
|
### 激励与提审
|
|
212
242
|
|
|
213
243
|
```text
|
package/bin/cli.js
CHANGED
|
@@ -38,6 +38,12 @@ const color = {
|
|
|
38
38
|
// ── 参数解析 ──────────────────────────────────────────
|
|
39
39
|
const args = process.argv.slice(2);
|
|
40
40
|
|
|
41
|
+
if (args.includes('--version') || args.includes('-v')) {
|
|
42
|
+
const pkg = require('../package.json');
|
|
43
|
+
console.log(pkg.version);
|
|
44
|
+
process.exit(0);
|
|
45
|
+
}
|
|
46
|
+
|
|
41
47
|
if (args.includes('--help') || args.includes('-h')) {
|
|
42
48
|
console.log(`
|
|
43
49
|
${color.bold('harmonyos-skills-pack')} — 鸿蒙 Ark AI Agent Skills 一键安装
|
|
@@ -45,6 +51,7 @@ ${color.bold('harmonyos-skills-pack')} — 鸿蒙 Ark AI Agent Skills 一键安
|
|
|
45
51
|
${color.cyan('用法:')}
|
|
46
52
|
npx harmonyos-skills-pack 安装到当前目录
|
|
47
53
|
npx harmonyos-skills-pack --target . 指定目标目录
|
|
54
|
+
npx harmonyos-skills-pack --version 查看版本号
|
|
48
55
|
npx harmonyos-skills-pack --force 强制覆盖已有文件
|
|
49
56
|
npx harmonyos-skills-pack --mirror 使用国内镜像加速下载
|
|
50
57
|
npx harmonyos-skills-pack --claude-only 仅 .claude/skills
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "harmonyos-skills-pack",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.4",
|
|
4
4
|
"description": "一键安装鸿蒙 Ark 开发文档 + 通用产品质量 skills pack,适配 Claude/Copilot/Codex Agent",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"harmonyos",
|
|
@@ -15,6 +15,10 @@
|
|
|
15
15
|
],
|
|
16
16
|
"author": "yibaiba",
|
|
17
17
|
"license": "MIT",
|
|
18
|
+
"homepage": "https://github.com/yibaiba/harmonyos-skills-pack#readme",
|
|
19
|
+
"bugs": {
|
|
20
|
+
"url": "https://github.com/yibaiba/harmonyos-skills-pack/issues"
|
|
21
|
+
},
|
|
18
22
|
"repository": {
|
|
19
23
|
"type": "git",
|
|
20
24
|
"url": "https://github.com/yibaiba/harmonyos-skills-pack.git"
|