@@ -293,8 +293,14 @@ async function main() {
293293 const stats = statSync ( nodePath )
294294 const sizeMB = ( stats . size / 1024 / 1024 ) . toFixed ( 1 )
295295 printFooter ( `Node.js built successfully! Size: ${ sizeMB } MB` )
296+ console . log ( `\n✨ To run locally:` )
297+ console . log ( ` ${ nodePath } [script.js]` )
298+ console . log ( ` # Or use with Socket CLI:` )
299+ console . log ( ` ${ nodePath } bin/cli.js [command]` )
296300 } else {
297301 printFooter ( 'Node.js built successfully!' )
302+ console . log ( `\n✨ To run locally:` )
303+ console . log ( ` ./build/socket-node/node-v24.9.0-custom/out/Release/node [script.js]` )
298304 }
299305 }
300306 return
@@ -314,7 +320,17 @@ async function main() {
314320 log . error ( 'Stub build failed' )
315321 process . exitCode = stubExitCode
316322 } else {
323+ // Determine the output path for the stub binary
324+ const platformName = process . platform === 'darwin' ? 'macos' : process . platform
325+ const stubExt = WIN32 ? '.exe' : ''
326+ const stubPath = path . join ( rootPath , 'binaries' , 'stub' , `socket-${ platformName } -${ process . arch } ${ stubExt } ` )
327+
317328 printFooter ( 'Stub/SEA binary built successfully!' )
329+ console . log ( `\n✨ To run locally:` )
330+ console . log ( ` ${ stubPath } [command]` )
331+ console . log ( ` # Examples:` )
332+ console . log ( ` ${ stubPath } --help` )
333+ console . log ( ` ${ stubPath } scan .` )
318334 }
319335 return
320336 }
@@ -391,6 +407,16 @@ async function main() {
391407 process . exitCode = exitCode
392408 } else {
393409 printFooter ( 'Build completed successfully!' )
410+ // Only show run instructions for non-watch, non-types-only builds
411+ if ( ! values . watch && ! ( values . types && ! values . src ) ) {
412+ console . log ( `\n✨ To run locally:` )
413+ console . log ( ` pnpm exec socket [command]` )
414+ console . log ( ` # Or directly:` )
415+ console . log ( ` ./bin/cli.js [command]` )
416+ console . log ( ` # Examples:` )
417+ console . log ( ` pnpm exec socket --help` )
418+ console . log ( ` ./bin/cli.js scan .` )
419+ }
394420 }
395421 } catch ( error ) {
396422 log . error ( `Build runner failed: ${ error . message } ` )
0 commit comments