Introduces @kuns/claude-mailbox under node/, a wire-compatible TypeScript port of the .NET daemon that distributes via the public Gitea npm registry. The .NET project stays in src/ClaudeMailbox/ untouched; users pick whichever flavor they prefer. - node/ project: fastify + @modelcontextprotocol/sdk StreamableHTTPServerTransport + better-sqlite3, schema and wire surface match the C# version (port 47822, X-Mailbox header, MCP tool names, snake_case SQLite columns) - Cross-platform autostart: Scheduled Task (Win, no admin) / Windows Service (Win, --service) / launchd (mac) / systemd --user (linux) - 9/9 vitest tests pass; end-to-end /health + send/check round-trip verified - CI split: existing ci.yml/release.yml renamed to *-dotnet.yml with path filters, new ci-node.yml and release-node.yml publish to Gitea npm registry - install.ps1 / install.sh bootstrap one-liners at repo root; homebrew/ contains a tap formula template - README install section reordered: npm path primary, dotnet publish secondary Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
47 lines
1.4 KiB
PowerShell
47 lines
1.4 KiB
PowerShell
#Requires -Version 5.1
|
|
<#
|
|
.SYNOPSIS
|
|
Bootstrap installer for ClaudeMailbox on Windows.
|
|
|
|
.DESCRIPTION
|
|
Configures the @kuns scoped npm registry to point at the public Gitea
|
|
package registry, installs @kuns/claude-mailbox globally, and optionally
|
|
registers per-user autostart via Scheduled Task.
|
|
|
|
.PARAMETER NoAutostart
|
|
Skip the install-autostart step.
|
|
|
|
.PARAMETER Service
|
|
Install as a Windows Service (admin shell required) instead of a Scheduled Task.
|
|
|
|
.EXAMPLE
|
|
irm https://git.kuns.dev/releases/ClaudeMailbox/raw/branch/main/install.ps1 | iex
|
|
#>
|
|
[CmdletBinding()]
|
|
param(
|
|
[switch] $NoAutostart,
|
|
[switch] $Service
|
|
)
|
|
|
|
$ErrorActionPreference = "Stop"
|
|
|
|
if (-not (Get-Command npm -ErrorAction SilentlyContinue)) {
|
|
throw "Node.js / npm not found on PATH. Install Node 20+ from https://nodejs.org and retry."
|
|
}
|
|
|
|
Write-Host "Configuring @kuns scoped npm registry..." -ForegroundColor Cyan
|
|
npm config set "@kuns:registry" "https://git.kuns.dev/api/packages/releases/npm/"
|
|
|
|
Write-Host "Installing @kuns/claude-mailbox globally..." -ForegroundColor Cyan
|
|
npm install -g "@kuns/claude-mailbox"
|
|
|
|
if (-not $NoAutostart) {
|
|
$args = @("install-autostart")
|
|
if ($Service) { $args += "--service" }
|
|
Write-Host "Registering autostart..." -ForegroundColor Cyan
|
|
& claude-mailbox @args
|
|
}
|
|
|
|
Write-Host ""
|
|
Write-Host "ClaudeMailbox installed. Run 'claude-mailbox status' to verify." -ForegroundColor Green
|