feat: add one-step installer script and enhance README with installation instructions
This commit is contained in:
@@ -28,6 +28,12 @@ Install to `~/Applications/AIWorkspace.app`:
|
||||
apps/mac/AIWorkspace/scripts/package-app.sh --install
|
||||
```
|
||||
|
||||
One-step local install, optionally enabling start at login and opening the app:
|
||||
|
||||
```bash
|
||||
apps/mac/AIWorkspace/scripts/install.sh --start-at-login --open
|
||||
```
|
||||
|
||||
## Start at login
|
||||
|
||||
After installing the app bundle:
|
||||
@@ -55,6 +61,7 @@ swift run --package-path apps/mac/AIWorkspace AIWorkspace
|
||||
- Stop Fidelity services
|
||||
- Restart Context MCP
|
||||
- Open Mattermost through the service manager
|
||||
- Open Mattermost through the local proxy-managed launcher
|
||||
- Run Doctor
|
||||
- Copy Doctor JSON
|
||||
- Copy Photo Inbox URL
|
||||
|
||||
@@ -203,7 +203,7 @@ struct ServiceMenuView: View {
|
||||
ActionButton(title: "Start Fidelity", systemImage: "play.fill", action: model.startProfile)
|
||||
ActionButton(title: "Stop Fidelity", systemImage: "stop.fill", role: .destructive, action: model.stopProfile)
|
||||
ActionButton(title: "Restart MCP", systemImage: "arrow.triangle.2.circlepath", action: model.restartMCP)
|
||||
ActionButton(title: "Mattermost", systemImage: "message", action: model.openMattermost)
|
||||
ActionButton(title: "Mattermost via Proxy", systemImage: "message.badge", action: model.openMattermost)
|
||||
}
|
||||
|
||||
Divider()
|
||||
@@ -266,7 +266,7 @@ struct ServiceRow: View {
|
||||
VStack(alignment: .leading, spacing: 2) {
|
||||
Text(service.displayName)
|
||||
.font(.body.weight(.medium))
|
||||
Text(service.health.detail)
|
||||
Text(service.detail)
|
||||
.font(.caption2)
|
||||
.foregroundStyle(.secondary)
|
||||
.lineLimit(1)
|
||||
@@ -277,7 +277,7 @@ struct ServiceRow: View {
|
||||
.padding(.vertical, 7)
|
||||
.padding(.horizontal, 10)
|
||||
.background(.quaternary.opacity(0.6), in: RoundedRectangle(cornerRadius: 10, style: .continuous))
|
||||
.help(service.health.detail)
|
||||
.help(service.detail)
|
||||
}
|
||||
|
||||
private var symbol: String {
|
||||
@@ -402,12 +402,19 @@ struct ServiceStatus: Decodable, Identifiable {
|
||||
switch name {
|
||||
case "aiw-context-mcp": "Context MCP"
|
||||
case "mattermost-proxy": "Mattermost Proxy"
|
||||
case "mattermost-desktop": "Mattermost Desktop"
|
||||
case "mattermost-desktop": "Mattermost Desktop via Proxy"
|
||||
case "photo-inbox": "Photo Inbox"
|
||||
default: name
|
||||
}
|
||||
}
|
||||
|
||||
var detail: String {
|
||||
if name == "mattermost-desktop" {
|
||||
return "Launches Mattermost through local proxy 127.0.0.1:8080"
|
||||
}
|
||||
return health.detail
|
||||
}
|
||||
|
||||
var compactStatus: String {
|
||||
switch status {
|
||||
case "externally running": "external"
|
||||
|
||||
35
apps/mac/AIWorkspace/scripts/install.sh
Normal file
35
apps/mac/AIWorkspace/scripts/install.sh
Normal file
@@ -0,0 +1,35 @@
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
|
||||
INSTALL_LOGIN_ITEM=0
|
||||
OPEN_APP=0
|
||||
|
||||
for arg in "$@"; do
|
||||
case "$arg" in
|
||||
--start-at-login)
|
||||
INSTALL_LOGIN_ITEM=1
|
||||
;;
|
||||
--open)
|
||||
OPEN_APP=1
|
||||
;;
|
||||
*)
|
||||
echo "Unknown argument: $arg" >&2
|
||||
echo "Usage: $0 [--start-at-login] [--open]" >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
"$SCRIPT_DIR/package-app.sh" --install
|
||||
|
||||
if [[ "$INSTALL_LOGIN_ITEM" == "1" ]]; then
|
||||
"$SCRIPT_DIR/install-start-at-login.sh"
|
||||
fi
|
||||
|
||||
if [[ "$OPEN_APP" == "1" ]]; then
|
||||
open "$HOME/Applications/AIWorkspace.app"
|
||||
fi
|
||||
|
||||
echo "AI Workspace app install complete."
|
||||
Reference in New Issue
Block a user