dsh-remote-local-plugin 0.8.2 → 0.8.3
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/README.md +1 -1
- package/cordis.patch.yml +1 -1
- package/lib/index.js +42 -7
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -7,7 +7,7 @@ Remote development that appears as ordinary local sessions.
|
|
|
7
7
|
This plugin targets the official **DSH Desktop** application. Tested/supported versions:
|
|
8
8
|
|
|
9
9
|
- [DSH Desktop](https://github.com/deepseek-ai/deepseek-harness) [`0.2.1-rc.2`](https://github.com/deepseek-ai/deepseek-harness/releases/tag/dsh-v0.2.1-rc.2)
|
|
10
|
-
- Plugin [`0.8.
|
|
10
|
+
- Plugin [`0.8.3`](https://www.npmjs.com/package/dsh-remote-local-plugin)
|
|
11
11
|
- Remote DSH [`0.2.1-rc.2`](https://github.com/deepseek-ai/deepseek-harness/releases/tag/dsh-v0.2.1-rc.2)
|
|
12
12
|
- Remote [Node.js `22.19+`](https://nodejs.org/en/download) on Linux/macOS
|
|
13
13
|
|
package/cordis.patch.yml
CHANGED
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
remotePnpmVersion: 11.21.0
|
|
34
34
|
remoteStart: systemd
|
|
35
35
|
provisionTimeoutMs: 600000
|
|
36
|
-
# Remote-visible HTTP(S) proxy. Empty means
|
|
36
|
+
# Remote-visible HTTP(S) proxy. Empty means inspect the account login shell.
|
|
37
37
|
remoteInstallProxy: ''
|
|
38
38
|
remoteInstallNoProxy: 127.0.0.1,localhost
|
|
39
39
|
|
package/lib/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* dsh-remote-local-plugin@0.8.
|
|
1
|
+
/* dsh-remote-local-plugin@0.8.3 — bundled host entry */
|
|
2
2
|
|
|
3
3
|
// src/index.ts
|
|
4
4
|
import { credentialRef } from "@deepseek-ai/dsh-credentials";
|
|
@@ -2806,12 +2806,47 @@ export DSH_HOME
|
|
|
2806
2806
|
mkdir -p "$INSTALL_DIR" "$DSH_HOME/remote-agent"
|
|
2807
2807
|
echo "dsh-remote: preparing remote install"
|
|
2808
2808
|
if [ -z "$PROXY_URL" ]; then
|
|
2809
|
-
# Reuse a proxy already configured
|
|
2810
|
-
|
|
2811
|
-
|
|
2812
|
-
if
|
|
2813
|
-
|
|
2814
|
-
|
|
2809
|
+
# Reuse a proxy already configured by the account's actual login shell.
|
|
2810
|
+
LOGIN_SHELL="\${SHELL:-}"
|
|
2811
|
+
if [ -z "$LOGIN_SHELL" ] || [ ! -x "$LOGIN_SHELL" ]; then
|
|
2812
|
+
if command -v getent >/dev/null 2>&1; then
|
|
2813
|
+
LOGIN_SHELL="$(getent passwd "$(id -un)" 2>/dev/null | cut -d: -f7)"
|
|
2814
|
+
else
|
|
2815
|
+
LOGIN_SHELL="$(awk -F: -v u="$(id -un)" '$1 == u { print $7; exit }' /etc/passwd)"
|
|
2816
|
+
fi
|
|
2817
|
+
fi
|
|
2818
|
+
if [ -z "$LOGIN_SHELL" ] || [ ! -x "$LOGIN_SHELL" ]; then
|
|
2819
|
+
LOGIN_SHELL=/bin/sh
|
|
2820
|
+
fi
|
|
2821
|
+
PROXY_TIMEOUT=""
|
|
2822
|
+
if command -v timeout >/dev/null 2>&1; then
|
|
2823
|
+
PROXY_TIMEOUT="timeout 5"
|
|
2824
|
+
fi
|
|
2825
|
+
read_proxy_env() {
|
|
2826
|
+
if [ -n "$PROXY_TIMEOUT" ]; then
|
|
2827
|
+
$PROXY_TIMEOUT "$LOGIN_SHELL" "$@" -c 'env' 2>/dev/null || true
|
|
2828
|
+
else
|
|
2829
|
+
"$LOGIN_SHELL" "$@" -c 'env' 2>/dev/null || true
|
|
2830
|
+
fi
|
|
2831
|
+
}
|
|
2832
|
+
proxy_from_env() {
|
|
2833
|
+
local proxy_value
|
|
2834
|
+
proxy_value="$(printf '%s\\n' "$1" | tr -d '\\r' | sed -n -e 's/^HTTPS_PROXY=//p' -e 's/^https_proxy=//p' | head -n 1)"
|
|
2835
|
+
if [ -z "$proxy_value" ]; then
|
|
2836
|
+
proxy_value="$(printf '%s\\n' "$1" | tr -d '\\r' | sed -n -e 's/^HTTP_PROXY=//p' -e 's/^http_proxy=//p' | head -n 1)"
|
|
2837
|
+
fi
|
|
2838
|
+
printf '%s' "$proxy_value"
|
|
2839
|
+
}
|
|
2840
|
+
PROXY_ENV="$(read_proxy_env -l -i)"
|
|
2841
|
+
PROXY_URL="$(proxy_from_env "$PROXY_ENV")"
|
|
2842
|
+
if [ -z "$PROXY_URL" ]; then
|
|
2843
|
+
PROXY_ENV="$(read_proxy_env -l)"
|
|
2844
|
+
PROXY_URL="$(proxy_from_env "$PROXY_ENV")"
|
|
2845
|
+
fi
|
|
2846
|
+
if [ -z "$PROXY_URL" ]; then
|
|
2847
|
+
PROXY_ENV="$(read_proxy_env -i)"
|
|
2848
|
+
PROXY_URL="$(proxy_from_env "$PROXY_ENV")"
|
|
2849
|
+
fi
|
|
2815
2850
|
fi
|
|
2816
2851
|
if [ -n "$PROXY_URL" ]; then
|
|
2817
2852
|
export HTTP_PROXY="$PROXY_URL" http_proxy="$PROXY_URL"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-remote-local-plugin",
|
|
3
|
-
"version": "0.8.
|
|
3
|
+
"version": "0.8.3",
|
|
4
4
|
"description": "DSH remote-development local plugin: host registry, SSH tunnels, remote workspace/session discovery, an authenticated Connection RPC surface, agent tools, and a Settings page.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"dsh",
|