@iyowei/sweep-node-modules-cli 0.1.1 → 0.2.0

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2026 iYoWei
3
+ Copyright (c) 2026 iTonyYo
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
package/README.md CHANGED
@@ -1,6 +1,10 @@
1
- # sweep-node-modules
1
+ # sweep-node-modules-cli
2
2
 
3
3
  [![CI](https://github.com/iyowei/sweep-node-modules/actions/workflows/ci.yml/badge.svg)](https://github.com/iyowei/sweep-node-modules/actions/workflows/ci.yml)
4
+ [![npm version](https://img.shields.io/npm/v/@iyowei/sweep-node-modules-cli)](https://www.npmjs.com/package/@iyowei/sweep-node-modules-cli)
5
+ [![npm downloads](https://img.shields.io/npm/dm/@iyowei/sweep-node-modules-cli)](https://www.npmjs.com/package/@iyowei/sweep-node-modules-cli)
6
+ ![node](https://img.shields.io/node/v/@iyowei/sweep-node-modules-cli)
7
+ ![bun](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fraw.githubusercontent.com%2Fiyowei%2Fsweep-node-modules%2Fmain%2Fpackage.json&query=%24.packageManager&label=bun)
4
8
 
5
9
  **English** | [中文](README.zh-CN.md)
6
10
 
@@ -55,10 +59,10 @@ bun install -g @iyowei/sweep-node-modules-cli
55
59
  # clone, then cd into the repo root (adjust the path to your clone location)
56
60
  cd "<your clone>/sweep-node-modules"
57
61
 
58
- chmod +x packages/cli/bin/sweep-nm
62
+ chmod +x packages/sweep-node-modules-cli/bin/sweep-nm
59
63
 
60
64
  # symlink it into ~/.local/bin (usually already on PATH); the launcher picks the runtime
61
- ln -sf "$PWD/packages/cli/bin/sweep-nm" ~/.local/packages/cli/bin/sweep-nm
65
+ ln -sf "$PWD/packages/sweep-node-modules-cli/bin/sweep-nm" ~/.local/bin/sweep-nm
62
66
  ```
63
67
 
64
68
  **Windows** (PowerShell):
@@ -66,7 +70,7 @@ ln -sf "$PWD/packages/cli/bin/sweep-nm" ~/.local/packages/cli/bin/sweep-nm
66
70
  ```powershell
67
71
  # add the repo's bin directory to your user PATH; one-time, effective after reopening the terminal
68
72
  # adjust the path to your actual clone location (the launcher locates src relative to itself, so the script cannot be copied out on its own)
69
- $bin = "$env:USERPROFILE\tools\sweep-node-modules\packages\cli\bin"
73
+ $bin = "$env:USERPROFILE\tools\sweep-node-modules\packages\sweep-node-modules-cli\bin"
70
74
  [Environment]::SetEnvironmentVariable(
71
75
  'Path',
72
76
  [Environment]::GetEnvironmentVariable('Path', 'User') + ";$bin",
@@ -77,9 +81,9 @@ $bin = "$env:USERPROFILE\tools\sweep-node-modules\packages\cli\bin"
77
81
  > Or skip the command line: add the `bin` directory to your user `Path` under System Properties → Environment Variables.
78
82
 
79
83
  - **Requires**: bun or node, either works (the launcher is a shell / cmd script run by the OS; it does not depend on node)
80
- - The most direct entry point; afterwards just run `sweep-nm` (on Windows via `packages\cli\bin\sweep-nm.cmd`)
84
+ - The most direct entry point; afterwards just run `sweep-nm` (on Windows via `packages\sweep-node-modules-cli\bin\sweep-nm.cmd`)
81
85
 
82
- > The tool also ships an API package, `@iyowei/sweep-node-modules`, for use in your own programs or scripts (usage is documented in that package).
86
+ > The tool also ships an API package, [`@iyowei/sweep-node-modules`](https://www.npmjs.com/package/@iyowei/sweep-node-modules), for use in your own programs or scripts (usage is documented in that package).
83
87
 
84
88
  ## Usage
85
89
 
package/README.zh-CN.md CHANGED
@@ -1,6 +1,10 @@
1
- # sweep-node-modules
1
+ # sweep-node-modules-cli
2
2
 
3
3
  [![CI](https://github.com/iyowei/sweep-node-modules/actions/workflows/ci.yml/badge.svg)](https://github.com/iyowei/sweep-node-modules/actions/workflows/ci.yml)
4
+ [![npm version](https://img.shields.io/npm/v/@iyowei/sweep-node-modules-cli)](https://www.npmjs.com/package/@iyowei/sweep-node-modules-cli)
5
+ [![npm downloads](https://img.shields.io/npm/dm/@iyowei/sweep-node-modules-cli)](https://www.npmjs.com/package/@iyowei/sweep-node-modules-cli)
6
+ ![node](https://img.shields.io/node/v/@iyowei/sweep-node-modules-cli)
7
+ ![bun](https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fraw.githubusercontent.com%2Fiyowei%2Fsweep-node-modules%2Fmain%2Fpackage.json&query=%24.packageManager&label=bun)
4
8
 
5
9
  [English](README.md) | **中文**
6
10
 
@@ -55,10 +59,10 @@ bun install -g @iyowei/sweep-node-modules-cli
55
59
  # 克隆后进入仓库根 (路径按你的实际位置调整)
56
60
  cd "<克隆位置>/sweep-node-modules"
57
61
 
58
- chmod +x packages/cli/bin/sweep-nm
62
+ chmod +x packages/sweep-node-modules-cli/bin/sweep-nm
59
63
 
60
64
  # 软链进 ~/.local/bin (通常已在 PATH 中), 启动器会挑选运行时
61
- ln -sf "$PWD/packages/cli/bin/sweep-nm" ~/.local/packages/cli/bin/sweep-nm
65
+ ln -sf "$PWD/packages/sweep-node-modules-cli/bin/sweep-nm" ~/.local/bin/sweep-nm
62
66
  ```
63
67
 
64
68
  **Windows** (PowerShell):
@@ -66,7 +70,7 @@ ln -sf "$PWD/packages/cli/bin/sweep-nm" ~/.local/packages/cli/bin/sweep-nm
66
70
  ```powershell
67
71
  # 把仓库的 bin 目录加入用户 PATH, 只需一次, 重开终端后生效
68
72
  # 路径按你的实际克隆位置调整 (启动器靠自身位置定位 src, 故不能把脚本单独复制走)
69
- $bin = "$env:USERPROFILE\tools\sweep-node-modules\packages\cli\bin"
73
+ $bin = "$env:USERPROFILE\tools\sweep-node-modules\packages\sweep-node-modules-cli\bin"
70
74
  [Environment]::SetEnvironmentVariable(
71
75
  'Path',
72
76
  [Environment]::GetEnvironmentVariable('Path', 'User') + ";$bin",
@@ -77,9 +81,9 @@ $bin = "$env:USERPROFILE\tools\sweep-node-modules\packages\cli\bin"
77
81
  > 也可以不经命令行: 在「系统属性 → 环境变量」里把该 `bin` 目录加到用户变量 `Path` 中。
78
82
 
79
83
  - **需要**: bun 或 node 任一 (启动器是 shell / cmd 脚本, 由系统执行, 不依赖 node)
80
- - 特点: 入口最直接; 之后直接敲 `sweep-nm` (Windows 经 `packages\cli\bin\sweep-nm.cmd`)
84
+ - 特点: 入口最直接; 之后直接敲 `sweep-nm` (Windows 经 `packages\sweep-node-modules-cli\bin\sweep-nm.cmd`)
81
85
 
82
- > 本工具同时提供可编程 API 包 `@iyowei/sweep-node-modules`, 供在程序或脚本中调用 (用法见该包文档)。
86
+ > 本工具同时提供可编程 API 包 [`@iyowei/sweep-node-modules`](https://www.npmjs.com/package/@iyowei/sweep-node-modules), 供在程序或脚本中调用 (用法见该包文档)。
83
87
 
84
88
  ## 使用
85
89