Commit 2bf873d

Anton Golub <antongolub@antongolub.com>
2024-12-30 21:41:10
docs: mention `halt` and `run` API (#1046)
closes #961
1 parent b90eab3
Changed files (1)
docs/process-promise.md
@@ -4,10 +4,16 @@ The `$` returns a `ProcessPromise` instance. When resolved, it becomes a [`Proce
 
 ```js
 const p = $`command` // ProcessPromise
-
 const o = await p    // ProcessOutput
 ```
 
+By default, `$` spawns a new process immediately, but you can delay the start to trigger in manually.
+
+```ts
+const p = $({halt: true})`command`
+const o = await p.run()
+```
+
 ## `stdin`
 
 Returns a writable stream of the stdin process. Accessing