Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
a91491d
Add wiki engine core with devcontainer
aniongithub Apr 26, 2026
2df07af
Add MCP tools layer and wire up serve command
aniongithub Apr 26, 2026
dd4667d
Add VS Code tasks, launch configs, and extensions
aniongithub Apr 26, 2026
1cc2829
Fix jsonschema struct tags for MCP SDK
aniongithub Apr 26, 2026
b3dafaa
Implement HTTP/SSE transport for MCP server
aniongithub Apr 26, 2026
5cccbff
Add full MCP tool test suite via InMemoryTransport
aniongithub Apr 26, 2026
28dbed1
Fix gitignore for SQLite WAL/SHM files
aniongithub Apr 26, 2026
2bc313d
Add Preact web UI — metro-inspired wiki client over MCP SSE
aniongithub Apr 26, 2026
c7a8232
Add netcat-traditional to Dockerfile for waitForServer task
aniongithub Apr 26, 2026
612d467
Fix webui serving path with --webui flag
aniongithub Apr 26, 2026
12d9628
Add CI/CD workflows and install script
aniongithub Apr 26, 2026
9d09bd3
Add Windows WSL installer and --skip-mcp-config flag
aniongithub Apr 26, 2026
18e0067
Fix WSL installer: distro selection and docker-desktop filtering
aniongithub Apr 27, 2026
482149c
Remove debug binary and add to gitignore
aniongithub Apr 27, 2026
b69cf74
Update README in devcontainer-mcp style
aniongithub Apr 27, 2026
b522136
Fix README: remove incorrect dogfooding claim
aniongithub Apr 27, 2026
82679e4
Expand development section with devcontainer links
aniongithub Apr 27, 2026
be56632
Simplify dev setup: use VS Code, not CLI commands
aniongithub Apr 27, 2026
1c291b7
List dev options in order: VS Code, devcontainer-mcp, CLI
aniongithub Apr 27, 2026
4f2c8af
Use devcontainer-mcp website link
aniongithub Apr 27, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
FROM debian:bookworm-slim

ARG DEBIAN_FRONTEND=noninteractive

RUN apt-get update \
&& apt-get install -y --no-install-recommends \
build-essential \
curl \
wget \
pkg-config \
libssl-dev \
ca-certificates \
git \
git-lfs \
netcat-traditional \
sudo \
&& git lfs install \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*

# Create non-root user
ARG USERNAME=vscode
ARG USER_UID=1000
ARG USER_GID=$USER_UID
RUN groupadd --force --gid $USER_GID $USERNAME \
&& useradd --uid $USER_UID --gid $USER_GID -m $USERNAME -s /bin/bash || true \
&& echo "$USERNAME ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers.d/$USERNAME \
&& chmod 0440 /etc/sudoers.d/$USERNAME
47 changes: 47 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
{
"name": "mind-map",
"build": {
"dockerfile": "Dockerfile"
},
"remoteUser": "vscode",
"features": {
"ghcr.io/devcontainers/features/go:1": {
"version": "latest"
},
"ghcr.io/devcontainers/features/node:1": {
"version": "lts"
},
"ghcr.io/devcontainers/features/sshd:1": {
"version": "latest"
}
},
"postCreateCommand": "go version && node --version",
"postAttachCommand": "npm install --prefix webui",
"customizations": {
"vscode": {
"extensions": [
"golang.Go",
"hbenl.vscode-test-explorer",
"ethan-reesor.vscode-go-test-adapter",
"idered.npm",
"qwtel.sqlite-viewer",
"dbaeumer.vscode-eslint"
],
"settings": {
"go.buildTags": "sqlite_fts5",
"go.testTags": "sqlite_fts5",
"go.buildFlags": ["-tags=sqlite_fts5"],
"go.testEnvVars": {
"CGO_ENABLED": "1"
}
}
}
},
"forwardPorts": [8080],
"portsAttributes": {
"8080": {
"label": "mind-map Server",
"onAutoForward": "notify"
}
}
}
28 changes: 28 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: CI

on:
pull_request:
branches: [main]
push:
branches: [main]

jobs:
check:
name: Check & Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- name: Build and test in devcontainer
uses: devcontainers/ci@v0.3
with:
push: never
runCmd: |
set -e

# Build webui
cd webui && npm install && npm run build && cd ..

# Go checks
CGO_ENABLED=1 go vet -tags sqlite_fts5 ./...
CGO_ENABLED=1 go test -tags sqlite_fts5 ./...
CGO_ENABLED=1 go build -tags sqlite_fts5 -o /tmp/mind-map ./cmd/mind-map/
104 changes: 104 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,104 @@
name: Release

on:
release:
types: [created]

permissions:
contents: write

jobs:
build:
name: Build release binaries
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5

- name: Build all targets in devcontainer
uses: devcontainers/ci@v0.3
with:
push: never
runCmd: |
set -e

# Build webui first
cd webui && npm install && npm run build && cd ..

# Install cross-compilation toolchain for linux-arm64
sudo apt-get update && sudo apt-get install -y gcc-aarch64-linux-gnu

# Build linux-x64 (native)
CGO_ENABLED=1 GOOS=linux GOARCH=amd64 \
go build -tags sqlite_fts5 -o mind-map-linux-x64 ./cmd/mind-map/

# Build linux-arm64 (cross-compile)
CGO_ENABLED=1 GOOS=linux GOARCH=arm64 CC=aarch64-linux-gnu-gcc \
go build -tags sqlite_fts5 -o mind-map-linux-arm64 ./cmd/mind-map/

# Package as tarballs
tar czf mind-map-linux-x64.tar.gz mind-map-linux-x64
tar czf mind-map-linux-arm64.tar.gz mind-map-linux-arm64

- name: Upload linux-x64
uses: softprops/action-gh-release@v3
with:
files: mind-map-linux-x64.tar.gz

- name: Upload linux-arm64
uses: softprops/action-gh-release@v3
with:
files: mind-map-linux-arm64.tar.gz

build-macos:
name: Build ${{ matrix.artifact }}
runs-on: macos-latest
strategy:
matrix:
include:
- target_os: darwin
target_arch: amd64
artifact: mind-map-darwin-x64
- target_os: darwin
target_arch: arm64
artifact: mind-map-darwin-arm64
steps:
- uses: actions/checkout@v5
- uses: actions/setup-go@v5
with:
go-version: '1.26'
- uses: actions/setup-node@v4
with:
node-version: 'lts/*'

- name: Build webui
run: cd webui && npm install && npm run build

- name: Build
env:
CGO_ENABLED: '1'
GOOS: ${{ matrix.target_os }}
GOARCH: ${{ matrix.target_arch }}
run: go build -tags sqlite_fts5 -o ${{ matrix.artifact }} ./cmd/mind-map/

- name: Codesign (ad-hoc)
run: codesign -s - ${{ matrix.artifact }} 2>/dev/null || true

- name: Package binary
run: tar czf ${{ matrix.artifact }}.tar.gz ${{ matrix.artifact }}

- name: Upload release asset
uses: softprops/action-gh-release@v3
with:
files: ${{ matrix.artifact }}.tar.gz

upload-install-script:
name: Upload install scripts
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- name: Upload install.sh and install.ps1
uses: softprops/action-gh-release@v3
with:
files: |
install.sh
install.ps1
15 changes: 15 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Build artifacts
/mind-map

# Wiki database files
.mind-map.db
.mind-map.db-shm
.mind-map.db-wal

# WebUI build output
webui/dist/
webui/node_modules/

# VS Code cache
.vscode/cache/
__debug_bin*
78 changes: 78 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
{
"version": "0.2.0",
"compounds": [
{
"name": "mind-map + WebUI",
"configurations": [
"mind-map Server",
"WebUI"
],
"stopAll": true
}
],
"configurations": [
{
"name": "mind-map Server",
"type": "go",
"request": "launch",
"mode": "auto",
"program": "${workspaceFolder}/cmd/mind-map",
"args": ["serve", "--addr", ":8080", "--dir", "${workspaceFolder}/testdata", "--webui", "${workspaceFolder}/webui/dist"],
"buildFlags": "-tags=sqlite_fts5",
"env": {
"CGO_ENABLED": "1"
},
"preLaunchTask": "build-webui"
},
{
"name": "mind-map Server (no WebUI)",
"type": "go",
"request": "launch",
"mode": "auto",
"program": "${workspaceFolder}/cmd/mind-map",
"args": ["serve", "--addr", ":8080", "--dir", "${workspaceFolder}/testdata", "--webui", "${workspaceFolder}/webui/dist"],
"buildFlags": "-tags=sqlite_fts5",
"env": {
"CGO_ENABLED": "1"
}
},
{
"name": "mind-map (stdio)",
"type": "go",
"request": "launch",
"mode": "auto",
"program": "${workspaceFolder}/cmd/mind-map",
"args": ["serve", "--stdio", "--dir", "${workspaceFolder}/testdata"],
"buildFlags": "-tags=sqlite_fts5",
"env": {
"CGO_ENABLED": "1"
}
},
{
"name": "WebUI",
"type": "chrome",
"request": "launch",
"browserLaunchLocation": "ui",
"runtimeExecutable": "stable",
"url": "http://localhost:8080",
"webRoot": "${workspaceFolder}/webui",
"preLaunchTask": "waitForServer",
"userDataDir": "${workspaceFolder}/.vscode/cache",
"sourceMaps": true,
"outFiles": [
"${workspaceFolder}/webui/dist/**/*.js"
]
},
{
"name": "Test (all)",
"type": "go",
"request": "launch",
"mode": "test",
"program": "${workspaceFolder}/internal/wiki",
"buildFlags": "-tags=sqlite_fts5",
"env": {
"CGO_ENABLED": "1"
}
}
]
}
62 changes: 62 additions & 0 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "build-webui",
"type": "npm",
"script": "build",
"path": "webui",
"group": {
"kind": "build",
"isDefault": true
},
"problemMatcher": [],
"detail": "Build WebUI with webpack"
},
{
"label": "watch-webui",
"type": "npm",
"script": "dev",
"path": "webui",
"group": {
"kind": "build",
"isDefault": false
},
"isBackground": true,
"problemMatcher": [],
"detail": "Watch WebUI with webpack"
},
{
"label": "build-go",
"type": "shell",
"command": "CGO_ENABLED=1 go build -tags sqlite_fts5 -o ${workspaceFolder}/mind-map ./cmd/mind-map/",
"group": "build",
"problemMatcher": ["$go"],
"detail": "Build Go binary"
},
{
"label": "test",
"type": "shell",
"command": "CGO_ENABLED=1 go test -v -tags sqlite_fts5 ./...",
"group": {
"kind": "test",
"isDefault": true
},
"problemMatcher": ["$go"]
},
{
"label": "waitForServer",
"type": "shell",
"command": "while ! nc -z localhost 8080; do sleep 1; done",
"group": "none",
"dependsOn": ["build-webui"],
"problemMatcher": {
"base": "$tsc",
"background": {
"beginsPattern": ".*",
"endsPattern": ".*"
}
}
}
]
}
Loading