Commit Graph
75 Commits
Author SHA1 Message Date
jonandClaude Opus 4.8 05d4e04cb0 feat(ollama): use nexus-core/models as the model store on Windows too
Windows pulled into %USERPROFILE%\.ollama while ncp and doctor looked in
nexus-core\models. The installer now sets OLLAMA_MODELS for its pulls and moves
an existing default store across first (instant on the same volume, no
refetch), and ollama_manager sets OLLAMA_MODELS on every platform. The env block
was duplicated in two methods, which is why the carve-out existed twice; folded
into _serve_env().

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 15:52:07 -05:00
jonandClaude Opus 4.8 97d7c3cb14 fix(ncp): find Ollama on PATH, not only the bundled copy
'ncp doctor' reported a missing Ollama binary on Windows, where winget installs
it to %LOCALAPPDATA%\Programs and on PATH rather than into the repo; the same
assumption made 'ncp models install' refuse to run there. Adds ollama_bin()
mirroring _ollama_bin() in ollama_manager.py.

Also renames wait_for_port's early message to READY - 'already running' for a
service the same command just started reads like a stale process.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 15:49:18 -05:00
jonandClaude Opus 4.8 6755a2477d fix(status): /status blocked the event loop and outran its own client timeout
The backend logged 200 OK for polls the client had already timed out on.
is_running() waited 2s for an Ollama that ships OFF (now 0.5s), is_available()
spawned 'ollama --version' every call and that command blocks ~5s when Ollama is
wedged (now cached), and both ran synchronously inside an async def, stalling the
event loop on every poll while the UI polls continuously (now to_thread).

Measured with Ollama's port blackholed: /status 5.89s -> 0.64s, concurrent GET /
stalled -> 0.06s. Poll timeout in nexus_window.py raised 2s -> 5s for margin.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 15:39:04 -05:00
jonandClaude Opus 4.8 cace36f122 fix(ncp): exit quietly on Ctrl+C instead of dumping a traceback
Ctrl+C is how you quit 'ncp web', which blocks on the UI window. It printed a
six-frame traceback ending in WaitForSingleObject, reading as a crash. Exits 130
instead.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 15:30:07 -05:00
jonandClaude Opus 4.8 4cc0481ffd fix(ncp web): no stray consoles, and show a loading window while services start
The two black terminals had two causes: uvicorn --reload (a dev flag whose
reloader spawns the server as a child, and Windows gives a console window to a
child of a console-less parent), and DETACHED_PROCESS in launch(), which is
exactly the console-less condition that triggers it. Drops --reload here
(launch_nexus.sh keeps it for the Linux dev loop) and uses CREATE_NO_WINDOW.

The window now opens immediately on an inline 'Loading Nexus core services' page
and navigates to the app once /status answers, instead of waiting 40s offscreen.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 15:22:44 -05:00
jonandClaude Opus 4.8 a62b68a909 feat(install-windows): close the terminal at the end, since its PATH is stale
A process reads PATH once, at startup, so the shell the installer ran in can
never resolve ncp. The ending now says that and closes the window. Uses
Stop-Process -Id $PID rather than 'exit', which only closes the window when the
host was started with -File.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 15:17:59 -05:00
jonandClaude Opus 4.8 e54864ad34 feat(install-windows): close the window only when the installer owns it
'Press Enter to close' closed nothing when run from an existing shell, and
closing unconditionally would kill the caller's session and any transcript in
it. Adds an -OwnsWindow switch passed only to the elevated run the script starts
for itself; that run may close its own window, a guest run returns quietly.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 15:05:30 -05:00
jonandClaude Opus 4.8 786552b790 fix: delete management/ncp.ps1 - it shadowed the ncp.cmd PATH shim
PowerShell resolves ExternalScript (.ps1) ahead of Application (.cmd), and both
lived in the directory the installer puts on PATH -- so in PowerShell `ncp` ran
the .ps1 and was execution-policy-bound again, the exact thing the .cmd exists
to avoid. Its other justification (giving ncp to pwsh on Linux) stopped being
true once /usr/local/bin/ncp existed: pwsh runs a PATH symlink to a shell script
as an Application. A test now prevents the file coming back.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 14:59:56 -05:00
jonandClaude Opus 4.8 b5564c4720 style(install-windows): filter winget's spinner frames out of the log
Piping winget to Out-Host defeats its carriage-return redraw, so every spinner
and progress-bar frame lands as its own line. Filters the frames, keeps the
messages. Block characters spelled by code point to keep the file ASCII.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 14:53:32 -05:00
jonandClaude Opus 4.8 38af74581f fix(install-windows): don't let a missing Ollama process abort the last step
taskkill writes to stderr when the process isn't running, and with
$ErrorActionPreference = Stop PowerShell 5.1 promotes native stderr to a
terminating error (2>$null doesn't prevent it). The normal case -- Ollama not
running -- threw and printed a failure warning for work that had succeeded.
Uses Get-Process | Stop-Process instead.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 14:51:44 -05:00
jonandClaude Opus 4.8 18df04c5d8 fix: decode native output as UTF-8 on Windows, so progress bars stop mojibaking
winget draws its progress bar with UTF-8 block characters, but PowerShell
decodes native output using the console codepage (437), turning each block into
three Latin characters and burying the real messages. Sets
[Console]::OutputEncoding to UTF-8 in install-windows.ps1, and chcp 65001 in
ncp.cmd for the check marks and em-dashes ncp.py prints.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 14:32:43 -05:00
jonandClaude Opus 4.8 4961d765c8 fix(install-windows): pull models last, so Ctrl+C can't abort the install
Ctrl+C in PS 5.1 kills the whole script, and the multi-GB model pull sat in the
middle -- skipping the download also skipped the ncp PATH registration and the
desktop shortcut. Moves the pull after them. Also drops the pipe that buffered
ollama's progress bar (a running download looked like a hang) and replaces a
try/catch that native commands never trigger with $LASTEXITCODE checks.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 14:30:09 -05:00
jonandClaude Opus 4.8 6137710c25 feat: put ncp on PATH on both platforms; rename WSL reqs to Windows
Ports the ncp PATH work from upstream. Registering ncp as a shell-profile
function failed three ways on Windows: the default Restricted execution policy
blocks the profile itself, profiles don't exist outside PowerShell (cmd, Win+R,
Task Scheduler), and the self-elevating installer writes the admin's profile.

Windows now ships management/ncp.cmd and the installer appends management\ to
the Machine PATH via [Environment]::SetEnvironmentVariable -- never setx, which
truncates PATH at 1024 chars. A .cmd is exempt from the execution policy.

Linux symlinks /usr/local/bin/ncp -> management/nexus-cli.sh, falling back to
the old .bashrc function when sudo is unavailable.

Also renames requirements-wsl.txt to requirements-windows.txt and purges stale
WSL references, including vite.config.js's dev-server comment and
controlpanel.py's "Check WSLg." error string.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 14:11:18 -05:00
jonandClaude Opus 4.8 9befa1d561 Sync from upstream: runtime-stage $HOME check allows the pwsh profile
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 11:42:31 -05:00
jonandClaude Opus 4.8 98006f395a Sync from upstream: ncp.ps1 works under PowerShell on Linux
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 11:41:03 -05:00
jonandClaude Opus 4.8 9e639100cf Sync from upstream: ncp stop no longer misreports Ollama
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 11:37:48 -05:00
jonandClaude Opus 4.8 ca8bc7425c Sync from upstream: ncp is Python now, runs on Windows too
management/ncp.py replaces the bash CLI's logic; nexus-cli.sh and the new
ncp.ps1 are thin wrappers, so Linux keeps its entry point and Windows gains one.
psutil handles process and port work on both platforms.

install-windows.ps1 registers ncp in the PowerShell profile. The panel VPN
switch now resolves its WireGuard connection through NetworkManager instead of
a hardcoded name, and the .ps1 ASCII guard globs rather than naming files.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 11:34:15 -05:00
jonandClaude Opus 4.8 bcad43502c Sync from upstream: README install note, CRLF fix in gen-nvidia-reqs
gen-nvidia-reqs.py wrote requirements-nvidia.txt with os.linesep, so running
it on Windows produced CRLF. Pinned to newline="\n".

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 11:06:33 -05:00
jonandClaude Opus 4.8 80d0f6dfee Remove GitNexus logo from the distributable
assets/gitnexus-logo.svg is branding for the Gitea instance that hosts this
project, not for NexusOS itself, so it does not belong in the public repo.
.gitignore already listed it, but gitignore does not apply to tracked files,
so it stayed until removed explicitly.

The README header already points at assets/n-small.png, so nothing references
it anymore.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 10:58:31 -05:00
Jon Wingender 0cef68cffa Update README.md 2026-07-22 14:51:23 +00:00
jonandClaude Opus 4.8 ee6e5bead7 Replace stale bin/install.sh with a wrapper over sync.py restore
bin/install.sh still rsynced --delete from a backup path retired in July, so
the documented Linux install both failed and could erase a working tree. Every
step it claimed to do already lives in bin/sync.py, shared with Windows.

Root ./install.sh is now a thin wrapper over `sync.py restore`, so deployment
stays one bash command. It also registers ncp/promethean in ~/.bashrc, which
was the only thing the old script uniquely did.

Split restore-linux.sh into runtime (Ollama binary, shell aliases) and desktop
(XFCE panel, theme, os-release). Only desktop writes outside the repo, it now
auto-skips off XFCE, and `--no-desktop` skips it explicitly. Two tests keep the
stage names in sync and the $HOME writes confined to the desktop stage.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 08:46:46 -05:00
Jon Wingender c75f17de6e Update .gitignore 2026-07-22 04:58:28 +00:00
Jon Wingender bd8360fe45 README: use ncp start/stop, not the full nexus-cli.sh path 2026-07-21 23:23:21 -05:00
Jon Wingender b64f168bcc README: clarify public repo needs no Gitea account/token to clone 2026-07-21 23:01:26 -05:00
Jon Wingender 714b9fc890 Initial commit: NexusOS - local AI assistant platform 2026-07-21 22:48:38 -05:00