SynapsesOS
Guides

Developer Setup

For contributors building Synapses from source.

Prerequisites

  • Go 1.22+
  • Git
  • (Optional) The Synapses desktop app installed

Build from Source

Terminal window
git clone https://github.com/SynapsesOS/synapses
cd synapses
go build -o ./build/synapses ./cmd/synapses

The binary at ./build/synapses is fully functional as a standalone CLI.

Connect to Desktop App

If you have the Synapses app installed and want it to use your custom binary:

Terminal window
# Point CLI to your custom binary
synapses dev link ./build/synapses
# Check which binary is active
synapses dev status
# Restore the app-bundled binary
synapses dev unlink

When dev-linked:

  • The app won’t overwrite your custom binary on updates
  • The app UI shows “Using custom binary” warning
  • synapses dev status shows the linked source path

Running Tests

Terminal window
# All tests
go test ./...
# With race detection
go test -race ./...
# Specific package
go test ./internal/config/

Project Structure

synapses/
cmd/synapses/ CLI entry point and commands
internal/
config/ Config loading and validation
graph/ Code graph types and operations
parser/ Language parsers (49+ languages)
store/ SQLite index storage
server/ MCP server implementation
brain/ Ollama-powered AI enrichment

Rebuilding After Changes

Terminal window
go build -o ./build/synapses ./cmd/synapses
# If dev-linked, the app picks up changes immediately