@narumitw/pi-caffeinate 0.1.9 → 0.1.11

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/README.md +37 -14
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -1,16 +1,27 @@
1
- # pi-caffeinate
1
+ # pi-caffeinate — Keep Your Computer Awake While Pi Works
2
2
 
3
- A public [pi](https://pi.dev) extension package that keeps your computer awake while the pi agent is processing a prompt.
3
+ [![npm](https://img.shields.io/npm/v/@narumitw/pi-caffeinate)](https://www.npmjs.com/package/@narumitw/pi-caffeinate) [![Pi extension](https://img.shields.io/badge/Pi-extension-blue)](https://pi.dev) [![License: MIT](https://img.shields.io/badge/license-MIT-green.svg)](./LICENSE)
4
4
 
5
- The extension starts an OS sleep inhibitor on `agent_start` and releases it on `agent_end` or `session_shutdown`.
5
+ `@narumitw/pi-caffeinate` is a cross-platform [Pi coding agent](https://pi.dev) extension that prevents your computer from sleeping while the Pi agent is processing a prompt.
6
6
 
7
- ## Install
7
+ It is designed for long-running coding, refactoring, debugging, web research, and autonomous agent workflows where a suspended laptop or desktop would interrupt progress.
8
+
9
+ ## ✨ Features
10
+
11
+ - Starts an OS sleep inhibitor when Pi begins processing (`agent_start`).
12
+ - Releases the inhibitor when processing ends (`agent_end`) or the session shuts down.
13
+ - Supports macOS, Windows, WSL, and Linux.
14
+ - Provides `/caffeinate-status` and `/caffeinate-stop` commands.
15
+ - Allows a custom inhibitor command through environment configuration.
16
+ - Fails safely when no supported inhibitor is available.
17
+
18
+ ## 📦 Install
8
19
 
9
20
  ```bash
10
21
  pi install npm:@narumitw/pi-caffeinate
11
22
  ```
12
23
 
13
- Try without installing:
24
+ Try without installing permanently:
14
25
 
15
26
  ```bash
16
27
  pi -e npm:@narumitw/pi-caffeinate
@@ -22,17 +33,17 @@ Try this package locally from the repository root:
22
33
  pi -e ./extensions/pi-caffeinate
23
34
  ```
24
35
 
25
- ## Supported platforms
36
+ ## 🖥️ Supported platforms
26
37
 
27
- - macOS: uses `caffeinate -dimsu`
28
- - Windows: uses PowerShell `SetThreadExecutionState`
29
- - WSL: uses Windows `powershell.exe` with `SetThreadExecutionState`
30
- - Linux: uses `systemd-inhibit` with `sleep infinity`
31
- - Linux fallback: uses `caffeinate -dimsu` if available
38
+ - macOS: uses `caffeinate -dimsu`.
39
+ - Windows: uses PowerShell `SetThreadExecutionState`.
40
+ - WSL: uses Windows `powershell.exe` with `SetThreadExecutionState`.
41
+ - Linux: uses `systemd-inhibit` with `sleep infinity`.
42
+ - Linux fallback: uses `caffeinate -dimsu` when available.
32
43
 
33
44
  If no supported inhibitor is available, the extension stays loaded and reports that caffeinate is unavailable.
34
45
 
35
- ## Commands
46
+ ## 🚀 Commands
36
47
 
37
48
  ```text
38
49
  /caffeinate-status
@@ -46,7 +57,7 @@ Shows whether an inhibitor is active, unavailable, or disabled.
46
57
 
47
58
  Manually releases any active inhibitor for the current session.
48
59
 
49
- ## Configuration
60
+ ## ⚙️ Configuration
50
61
 
51
62
  Disable the extension:
52
63
 
@@ -62,7 +73,11 @@ PI_CAFFEINATE_COMMAND='systemd-inhibit --what=idle:sleep --why="pi running" --mo
62
73
 
63
74
  The custom command is parsed with shell-like quoting and is run directly without a shell.
64
75
 
65
- ## Package layout
76
+ ## 🧠 Why use pi-caffeinate?
77
+
78
+ AI coding agents often run tool-heavy tasks that take several minutes. `pi-caffeinate` keeps your machine awake during active Pi work, helping browser automation, local builds, test runs, code generation, and long prompts finish reliably.
79
+
80
+ ## 🗂️ Package layout
66
81
 
67
82
  ```txt
68
83
  extensions/pi-caffeinate/
@@ -73,3 +88,11 @@ extensions/pi-caffeinate/
73
88
  ├── tsconfig.json
74
89
  └── package.json
75
90
  ```
91
+
92
+ ## 🔎 Keywords
93
+
94
+ Pi extension, Pi coding agent, caffeinate, prevent sleep, keep awake, sleep inhibitor, AI agent automation, long-running coding task, TypeScript Pi package.
95
+
96
+ ## 📄 License
97
+
98
+ MIT. See [`LICENSE`](./LICENSE).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@narumitw/pi-caffeinate",
3
- "version": "0.1.9",
3
+ "version": "0.1.11",
4
4
  "description": "Pi extension that keeps the computer awake while the agent is running.",
5
5
  "type": "module",
6
6
  "license": "MIT",