aihezu 1.1.1 → 1.1.2

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.
Files changed (2) hide show
  1. package/bin/ccclear.js +14 -1
  2. package/package.json +1 -1
package/bin/ccclear.js CHANGED
@@ -6,7 +6,20 @@ const os = require('os');
6
6
  const fs = require('fs');
7
7
 
8
8
  const homeDir = os.homedir();
9
- const timestamp = new Date().toISOString().replace(/[-:]/g, '').replace(/\..+/, '').replace('T', '');
9
+
10
+ // 生成本地时间戳,格式:YYYYMMDDHHMMSS
11
+ function getLocalTimestamp() {
12
+ const now = new Date();
13
+ const year = now.getFullYear();
14
+ const month = String(now.getMonth() + 1).padStart(2, '0');
15
+ const day = String(now.getDate()).padStart(2, '0');
16
+ const hours = String(now.getHours()).padStart(2, '0');
17
+ const minutes = String(now.getMinutes()).padStart(2, '0');
18
+ const seconds = String(now.getSeconds()).padStart(2, '0');
19
+ return `${year}${month}${day}${hours}${minutes}${seconds}`;
20
+ }
21
+
22
+ const timestamp = getLocalTimestamp();
10
23
 
11
24
  console.log('🧹 Claude Code CLI 清理工具');
12
25
  console.log('🌐 Powered by https://aihezu.dev\n');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "aihezu",
3
- "version": "1.1.1",
3
+ "version": "1.1.2",
4
4
  "description": "Claude Code CLI 清理工具 - 快速备份和清理 Claude Code 的本地配置和缓存,同时修改 hosts 文件实现本地代理",
5
5
  "main": "bin/ccclear.js",
6
6
  "bin": {