unsloth/studio
Daniel Han f2c2b3f327 studio/setup.ps1: mirror step/substep output to [Console]::Out for piped consumers
Follow-up to 47432b0b. The -Command + *>&1 redirect at the
powershell.exe invocation level is not enough on its own: PS 5.1's
Write-Host writes via $Host.UI.WriteLine, and the default ConsoleHost
does not always forward host-UI output to the inherited stdout
handle when there is no console attached (CREATE_NO_WINDOW) and
stdout is a pipe. Even with $InformationPreference = 'Continue',
the parent's `tee` saw nothing, so `unsloth studio update --local
2>&1 | tee logs/update.log` produced an empty update.log.

Add a small Write-StudioStdoutMirror helper and have step/substep
mirror the plain (no ANSI) form of each line to [Console]::Out
when [Console]::IsOutputRedirected is true. [Console]::Out always
lands on the OS-level stdout file handle, so the line propagates
through install.ps1 -> unsloth.exe -> python -> powershell.exe ->
setup.ps1 unaffected by host-UI vs information-stream quirks.

Gated on IsOutputRedirected so the interactive-console UX stays
unchanged (no double-printing of the colorized step lines).

Net effect: the Windows Studio Update CI's grep for "prebuilt up to
date and validated" / "prebuilt installed and validated" finds the
marker because step() now writes the plain text to stdout from
inside setup.ps1.
2026-05-08 03:04:28 +00:00
..
backend Merge remote-tracking branch 'origin/main' into ci/workflow-permissions-and-fewer-skips 2026-05-07 10:58:10 +00:00
frontend Merge branch 'main' into ci/workflow-permissions-and-fewer-skips 2026-05-07 14:15:12 -07:00
src-tauri install: support STUDIO_HOME / UNSLOTH_STUDIO_HOME for custom install paths (#5190) 2026-05-05 23:17:40 -07:00
__init__.py Final cleanup 2026-03-12 18:28:04 +00:00
install_llama_prebuilt.py fix(install): retry GitHub API 403 with Retry-After / X-RateLimit-Reset 2026-05-07 11:23:30 +00:00
install_python_stack.py Add native GGUF intake to Studio (#5246) 2026-05-04 11:46:18 +02:00
LICENSE.AGPL-3.0 Add AGPL-3.0 license to studio folder 2026-03-09 19:36:25 +00:00
setup.bat Final cleanup 2026-03-12 18:28:04 +00:00
setup.ps1 studio/setup.ps1: mirror step/substep output to [Console]::Out for piped consumers 2026-05-08 03:04:28 +00:00
setup.sh Route CPU-only Linux x86_64 to ggml-org/llama.cpp prebuilts (#5302) 2026-05-05 23:22:22 -07:00
Unsloth_Studio_Colab.ipynb studio: add --local to setup.sh + overlay unsloth-zoo from git main (#5252) 2026-05-02 08:51:56 +04:00