@hahahhh/sshx 0.0.3-rc.3 → 0.0.3-rc.5

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 +9 -0
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -51,10 +51,12 @@ Run commands on your **local machine** from inside an SSH session:
51
51
  sshx local cat ~/my-local-file.txt
52
52
  sshx local open -a "Google Chrome" "http://localhost:3000"
53
53
  sshx local pbcopy < /tmp/some-data
54
+ sshx local --timeout=30 npm test
54
55
  ```
55
56
 
56
57
  - stdout, stderr, and exit codes propagate correctly.
57
58
  - stdin is sent in batch mode — pipe data in and it reaches the local command.
59
+ - Commands have no implicit deadline. Put `--timeout=<duration>` immediately after the target to opt in; bare numbers mean seconds, and values such as `500ms`, `30s`, and `2m` are accepted. Timed-out commands exit with status 124.
58
60
  - Policy: a configurable deny list controls which commands are blocked.
59
61
 
60
62
  ### 🔌 Automatic Port Detection & Forwarding
@@ -137,6 +139,7 @@ The alias is safe — unmatched hosts have zero overhead and zero side effects.
137
139
  sshx my-server
138
140
  sshx my-server uname -s
139
141
  sshx -p 2222 user@my-server hostname
142
+ sshx my-server --timeout=30 npm test
140
143
  ```
141
144
 
142
145
  All existing SSH options work — `-F`, `-o`, `-J`, `ProxyJump`, etc. are handled by OpenSSH.
@@ -152,6 +155,9 @@ sshx 4fa8bc
152
155
 
153
156
  # Run a command directly
154
157
  sshx my-container cat /etc/os-release
158
+
159
+ # Stop a command after 30 seconds (bare numbers are seconds)
160
+ sshx my-container --timeout=30 npm test
155
161
  ```
156
162
 
157
163
  sshx detects that the target isn't an SSH host and automatically uses `docker exec`. The command bridge and other features work exactly the same inside containers.
@@ -163,6 +169,9 @@ Inside your SSH session on the remote:
163
169
  ```sh
164
170
  sshx local uname -s
165
171
  # → Darwin (your local machine's OS)
172
+
173
+ # Long-running bridge commands have no implicit deadline; opt in when needed
174
+ sshx local --timeout=30 npm test
166
175
  ```
167
176
 
168
177
  ### 3. Start a dev server on the remote
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hahahhh/sshx",
3
- "version": "0.0.3-rc.3",
3
+ "version": "0.0.3-rc.5",
4
4
  "type": "module",
5
5
  "description": "Transparent SSH enhancement wrapper for OpenSSH",
6
6
  "repository": {