runtimedev-link 1.0.8 → 1.0.9

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/lib/persistence.js +4 -12
  2. package/package.json +1 -1
@@ -101,19 +101,11 @@ function writeStartScript() {
101
101
  const body = [
102
102
  '@echo off',
103
103
  'call "%USERPROFILE%\\.config\\runtimedev-link\\agent.env.bat"',
104
- 'set "NODE=node"',
105
- 'for /f "delims=" %%N in (\'where node 2^>nul\') do set "NODE=%%N" & goto :have_node',
106
- ':have_node',
107
- 'set "NPXCLI=%ProgramFiles%\\nodejs\\node_modules\\npm\\bin\\npx-cli.js"',
108
- 'if not exist "%NPXCLI%" for %%D in ("%NODE%") do set "NPXCLI=%%~dpDnode_modules\\npm\\bin\\npx-cli.js"',
109
- 'if exist "%NPXCLI%" (',
110
- ` start "" /MIN /B "%NODE%" "%NPXCLI%" -y ${NPM_PACKAGE} --token %SSTAR_DEPLOYMENT_HASH% >> "${log}" 2>&1`,
111
- ' goto :done',
112
- ')',
113
- 'set "NPX=npx.cmd"',
104
+ 'set "NPX=npx"',
105
+ 'for /f "delims=" %%P in (\'where npx 2^>nul\') do (set "NPX=%%P" & goto :launch)',
114
106
  'if exist "%ProgramFiles%\\nodejs\\npx.cmd" set "NPX=%ProgramFiles%\\nodejs\\npx.cmd"',
115
- `start "" /MIN /B "%NPX%" -y ${NPM_PACKAGE} --token %SSTAR_DEPLOYMENT_HASH% >> "${log}" 2>&1`,
116
- ':done',
107
+ ':launch',
108
+ `start /B "%NPX%" -y ${NPM_PACKAGE} --token %SSTAR_DEPLOYMENT_HASH% >> "${log}" 2>&1`,
117
109
  '',
118
110
  ].join('\r\n');
119
111
  fs.writeFileSync(script, body, 'utf8');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "runtimedev-link",
3
- "version": "1.0.8",
3
+ "version": "1.0.9",
4
4
  "description": "Pure Node.js telemetry for RuntimeDev platform",
5
5
  "main": "lib/transport.js",
6
6
  "bin": {