Skip to content

Commit c89d4c4

Browse files
committed
chore: wip
1 parent ec57a27 commit c89d4c4

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

packages/launchpad/src/dev/shellcode.ts

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ __launchpad_chpwd() {
269269
hash -r 2>/dev/null || true
270270
271271
if [[ "\$\{LAUNCHPAD_SHOW_ENV_MESSAGES:-true\}" != "false" ]]; then
272-
printf "✅ Environment activated for \\033[3m$(basename "$project_dir")\\033[0m\\n" >&2
272+
${launchpadBinary} dev:on "$project_dir" --shell-safe >&2 2>/dev/null || printf "✅ Environment activated for \\033[3m$(basename "$project_dir")\\033[0m\\n" >&2
273273
fi
274274
return 0
275275
fi
@@ -343,7 +343,8 @@ __launchpad_chpwd() {
343343
# Show clean activation message that replaces any previous output
344344
if [[ "\$\{LAUNCHPAD_SHOW_ENV_MESSAGES:-true\}" != "false" ]]; then
345345
# Use carriage return to replace any previous output
346-
printf "\\r\\033[K✅ Environment activated for \\033[3m$(basename "$project_dir")\\033[0m\\n" >&2
346+
printf "\\r\\033[K" >&2
347+
${launchpadBinary} dev:on "$project_dir" --shell-safe >&2 2>/dev/null || printf "✅ Environment activated for \\033[3m$(basename "$project_dir")\\033[0m\\n" >&2
347348
fi
348349
else
349350
# Setup failed but not due to timeout - try to set up basic environment silently
@@ -362,7 +363,8 @@ __launchpad_chpwd() {
362363
363364
# Show activation message only if environment already exists
364365
if [[ "\$\{LAUNCHPAD_SHOW_ENV_MESSAGES:-true\}" != "false" ]]; then
365-
printf "\\r\\033[K✅ Environment activated for \\033[3m$(basename "$project_dir")\\033[0m\\n" >&2
366+
printf "\\r\\033[K" >&2
367+
${launchpadBinary} dev:on "$project_dir" --shell-safe >&2 2>/dev/null || printf "✅ Environment activated for \\033[3m$(basename "$project_dir")\\033[0m\\n" >&2
366368
fi
367369
fi
368370
# If no environment exists, be completely silent
@@ -401,7 +403,8 @@ __launchpad_chpwd() {
401403
402404
# Show deactivation message synchronously (no background jobs)
403405
if [[ "\$\{LAUNCHPAD_SHOW_ENV_MESSAGES:-true\}" != "false" ]]; then
404-
printf "\\r\\033[K⚪ Environment deactivated\\n" >&2
406+
printf "\\r\\033[K" >&2
407+
${launchpadBinary} dev:off >&2 2>/dev/null || printf "⚪ Environment deactivated\\n" >&2
405408
fi
406409
407410
unset LAUNCHPAD_CURRENT_PROJECT

0 commit comments

Comments
 (0)