@kurokeita/add-skill 2.2.1 → 2.2.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.
package/dist/bin/cli.js CHANGED
@@ -1549,7 +1549,7 @@ async function remove(type, options) {
1549
1549
  }
1550
1550
 
1551
1551
  // package.json
1552
- var version = "2.2.1";
1552
+ var version = "2.2.2";
1553
1553
 
1554
1554
  // bin/cli.ts
1555
1555
  var program = new Command();
@@ -121,6 +121,8 @@ Read **all** git state from a single `git -C "$cwd" status -b --porcelain` call,
121
121
 
122
122
  The last-commit row needs one further call: `git -C "$cwd" log -1 --format='%h %s'`.
123
123
 
124
+ Every git call must skip optional locks: export `GIT_OPTIONAL_LOCKS=0` once at the top of the script. A plain `git status` takes `.git/index.lock` to refresh stat info, and the statusline re-runs on every turn, so it races the user's own `git add`/`commit` and makes them fail with `Unable to create '.git/index.lock': File exists`.
125
+
124
126
  ## Quota Colors (by REMAINING quota = 100 - used%)
125
127
 
126
128
  | Remaining | Color | 24-bit ANSI |
@@ -195,6 +197,10 @@ JSON parsing rules:
195
197
 
196
198
  set -u
197
199
 
200
+ # The statusline re-runs on every Claude turn. A plain `git status` grabs
201
+ # .git/index.lock to refresh stat info, racing the user's own git writes.
202
+ export GIT_OPTIONAL_LOCKS=0
203
+
198
204
  if ! command -v jq >/dev/null 2>&1; then
199
205
  printf '%s' "statusline: jq not installed"
200
206
  exit 0
@@ -532,6 +538,9 @@ Write `statusline-command.ps1` to the targeted platform directory. Use `ConvertF
532
538
 
533
539
  ```powershell
534
540
  $ErrorActionPreference = 'SilentlyContinue'
541
+ # The statusline re-runs on every Claude turn. A plain `git status` grabs
542
+ # .git/index.lock to refresh stat info, racing the user's own git writes.
543
+ $env:GIT_OPTIONAL_LOCKS = '0'
535
544
  [Console]::OutputEncoding = [System.Text.Encoding]::UTF8
536
545
  $OutputEncoding = [System.Text.Encoding]::UTF8
537
546
  $ESC = [char]27
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kurokeita/add-skill",
3
- "version": "2.2.1",
3
+ "version": "2.2.2",
4
4
  "description": "CLI to install AI agent skills to various platforms",
5
5
  "type": "module",
6
6
  "bin": {