Universal Plugin System for Taskbar/Menu Bar - Write Once, Run Everywhere
Crossbar is a revolutionary cross-platform plugin system inspired by BitBar (macOS) and Argos (Linux), bringing the power of scriptable status bar widgets to all platforms - desktop and mobile.
-- cpu.10s.lua — Works on ALL platforms (Linux, macOS, Windows, Android, iOS)
local cpu = crossbar.cpu()
local color = cpu >= 80 and 'red' or cpu >= 60 and 'yellow' or 'green'
print('⚡ ' .. math.floor(cpu + 0.5) .. '% | color=' .. color)
print('---')
print('Usage: ' .. string.format('%.1f%%', cpu))
print('Platform: ' .. crossbar.platform())
print('Refresh | refresh=true')- 🌍 True Cross-Platform: One plugin, five target platforms (Linux, macOS, Windows, Android, iOS)
- 🌙 Lua-First Plugins: 25 sample plugins in Lua run on all platforms via embedded interpreter. Also supports Bash, Python, Node.js, Dart, Go, Rust, YAML
- ⚡ Hot Reload: Automatic plugin detection and reload (<1s)
- 🎨 Adaptive Rendering: Same plugin renders as tray icon, notification, or widget
- 🔒 Secure Storage: Passwords stored in system Keychain/KeyStore
- 🌐 76+ CLI Commands: Unified API for system info, network, media, clipboard, QR codes, and more
| Feature | BitBar/Argos | Crossbar |
|---|---|---|
| Platforms | macOS/Linux only | Linux + Windows + macOS + Android + iOS |
| Output Formats | Text only | Text + JSON + Structured Data |
| UI Targets | Menu bar only | Tray + Notifications + Widgets + Menu bar |
| CLI API | None (scripts call system commands) | 76+ unified commands (crossbar cpu) |
| Configuration | Manual scripting | Declarative JSON with auto-generated UI |
| Mobile Support | ❌ None | ✅ Widgets + Persistent Notifications (Android) + Home/Lock Screen Widgets (iOS) |
| Controls | Read-only | Bidirectional (volume, media, system) |
| Hot Reload | Manual refresh | Automatic file watching |
- System tray integration with custom icons
- Menu bar dropdown with unlimited items
- Window management and theming
- Tray Display Mode (Settings → System Tray):
- Unified: Single tray icon with menu for all plugins (default)
- Separate: One tray icon per plugin (Linux only)
- Smart Overflow: Shows all plugins as separate icons until count exceeds threshold, then switches to Unified.
- Smart Collapse: Shows first N plugins as separate icons, others in Unified menu.
- Home screen widgets (1x1, 2x2, 4x4 layouts)
- Persistent notifications (Android foreground service)
- Lock screen widgets (iOS)
Linux / macOS:
curl -fsSL install.cat/verseles/crossbar | shWindows (PowerShell):
irm install.cat/verseles/crossbar?format=ps1 | iexAndroid:
Download the latest APK directly: crossbar-android-arm64.apk
On Linux this installs Crossbar to ~/.local/share/crossbar with a symlink at ~/.local/bin/crossbar.
On macOS this installs Crossbar.app to ~/Applications/Crossbar.app and creates ~/.local/bin/crossbar.
On Windows this installs Crossbar to %LOCALAPPDATA%\Crossbar and adds this path to user PATH.
Download the latest release from GitHub Releases:
- Linux:
crossbar-linux-x64.tar.gz - macOS:
crossbar-macos-arm64.tar.gz - Windows:
crossbar-windows-x64.zip - Android:
crossbar-android-arm64.apk
Linux manual install:
mkdir -p ~/.local/share/crossbar
tar -xzf crossbar-linux-x64.tar.gz -C ~/.local/share/crossbar
ln -sf ~/.local/share/crossbar/crossbar ~/.local/bin/crossbarmacOS manual install:
mkdir -p ~/Applications
tar -xzf crossbar-macos-arm64.tar.gz -C /tmp
mv /tmp/crossbar.app ~/Applications/Crossbar.app
ln -sf ~/Applications/Crossbar.app/Contents/MacOS/crossbar ~/.local/bin/crossbarWindows manual install (PowerShell):
Expand-Archive .\crossbar-windows-x64.zip -DestinationPath "$env:LOCALAPPDATA\Crossbar" -Force
[Environment]::SetEnvironmentVariable("Path", "$([Environment]::GetEnvironmentVariable('Path','User'));$env:LOCALAPPDATA\Crossbar", "User")Usage:
crossbar # Launch (Start in Tray)
crossbar gui # Launch GUI (Open Window)
crossbar --help # Show CLI commands
crossbar cpu # Example CLI usagePrerequisites:
- Flutter 3.38.3+ (Install Flutter)
- Dart 3.10.0+ (comes with Flutter)
make(optional, for easier build commands)
git clone https://github.com/verseles/crossbar.git
cd crossbar
flutter pub get
make linux # or make macos, make windows- Create a plugin file in
~/.crossbar/plugins/(plugins can be files in the root or inside subdirectories):
-- ~/.crossbar/plugins/hello.10s.lua
print('👋 Hello Crossbar!')
print('---')
print('Platform: ' .. crossbar.platform())
print('Uptime: ' .. crossbar.uptime())
print('Refresh | refresh=true')- The plugin will auto-refresh every 10 seconds (from filename
*.10s.lua)
Tip: Lua plugins work on all platforms (Linux, macOS, Windows, Android, iOS) without external dependencies. For desktop-only scripts, you can also use
.sh,.py,.js, etc.
Crossbar supports multiple plugin types for different use cases:
| Type | Extension | Platforms | Use Case |
|---|---|---|---|
| Lua ⭐ | .lua |
All ✅ | Recommended — embedded, fast, sandboxed |
| YAML | .yaml |
All ✅ | Simple data display, no code needed |
| Dart Interpreted | .dart |
All ✅ | Logic without external packages |
| Script | .sh, .py, .js |
Desktop | Existing scripts, shell commands |
| Dart Compiled | .dart.exe |
Desktop | Full Dart with any package |
Quick Examples:
# YAML Plugin - weather.30m.yaml
name: Weather
source:
type: http
url: "https://api.example.com/weather"
output:
text: "🌡️ ${response.temp}°C"// Dart Plugin - clock.1s.dart
import 'package:crossbar_bridge/crossbar_bridge.dart';
void main() {
final crossbar = CrossbarBridge();
print('⏰ ${crossbar.time()}');
}📖 Detailed Guides:
- Codebase Architecture Guide - Start here for developers!
- Plugin Types Overview
- YAML Plugins
- Dart Plugins
- Writing Portable Plugins
- crossbar_api Package
Crossbar supports two output formats:
#!/bin/bash
echo "🔋 85%" # Tray text (first line)
echo "---" # Separator
echo "Status | color=green"
echo "Details | bash='crossbar battery --json'"Attributes:
color=red|blue|#FF0000- Text colorbash='command'- Execute on clickrefresh=true- Refresh all plugins on clickhref='https://url'- Open URL on clickfont=Monaco- Custom fontsize=12- Font size
#!/usr/bin/env python3
import json
print(json.dumps({
"icon": "🔋",
"text": "85%",
"tooltip": "Battery Level",
"color": "#00FF00",
"menu": [
{"text": "Show Details", "bash": "crossbar battery --json"},
{"text": "---"}, # Separator
{"text": "Settings", "href": "https://settings"}
]
}))Crossbar provides 76+ unified commands accessible via crossbar [command].
crossbar cpu # CPU usage (0-100)
crossbar memory # Memory usage (e.g., "8.2/16 GB")
crossbar battery # Battery status
crossbar disk # Disk usage
crossbar uptime # System uptime
crossbar hostname # Machine hostname
crossbar username # Current user
crossbar kernel # Kernel version
crossbar arch # Architecture (x64, arm64)
crossbar os # Operating systemcrossbar net status # "online" | "offline" | "wifi"
crossbar net ip # Local IP address
crossbar net ip --public # Public IP (via ipify.org)
crossbar net ping google.com # Ping latency
crossbar wifi status # WiFi status
crossbar wifi ssid # WiFi network name
crossbar bluetooth status # "on" | "off"
crossbar vpn status # VPN statuscrossbar screen size # Screen resolution
crossbar screen brightness # Get brightness
crossbar power sleep # Suspend system
crossbar wallpaper # Get current wallpaper pathcrossbar audio volume # Current volume (0-100)
crossbar audio volume 50 # Set volume
crossbar audio mute # Toggle mute
crossbar media playing --json # Current media info
crossbar media play # Resume playback
crossbar media pause
crossbar media next
crossbar media prevcrossbar clipboard # Get clipboard text
crossbar clipboard "text" # Copy to clipboardcrossbar file exists /path/file
crossbar file read /path/file
crossbar file size /path/file
crossbar dir list /path/dircrossbar time [12h|24h]
crossbar date
crossbar uuid # Generate UUID
crossbar random [min] [max]
crossbar hash "text"
crossbar base64 encode "text"
crossbar base64 decode "dGV4dA=="
crossbar exec "command" # Execute shell command
crossbar notify "Title" "Msg" # Send notification
crossbar open url "https://..." # Open URL
crossbar open file "/path/..." # Open fileSee full API: original_plan_specs.md
Plugins can declare their configuration needs:
// ~/.crossbar/plugins/weather.30m.py.schema.json
{
"name": "Weather Plugin",
"description": "Shows current weather",
"version": "1.0.0",
"settings": [
{
"key": "API_KEY",
"type": "password",
"label": "OpenWeather API Key",
"required": true
},
{
"key": "LOCATION",
"type": "text",
"label": "City Name",
"default": "São Paulo"
},
{
"key": "UNITS",
"type": "select",
"label": "Temperature Units",
"options": [
{ "value": "metric", "label": "Celsius" },
{ "value": "imperial", "label": "Fahrenheit" }
],
"default": "metric"
},
{
"key": "ALERT_AT",
"type": "datetime",
"label": "Alert datetime",
"default": "2026-12-31T23:59:59+00:00"
}
]
}Crossbar automatically generates a configuration dialog with proper UI controls.
Tipos com suporte direto na UI hoje:
text, password, number, select, checkbox, color, file, path,
url, textarea, slider, date, time, datetime.
Every plugin receives these variables:
CROSSBAR_OS=linux # Platform (linux/macos/windows/android/ios)
CROSSBAR_DARK_MODE=true # System theme
CROSSBAR_VERSION=1.0.0 # Crossbar version
CROSSBAR_PLUGIN_ID=cpu.10s.sh # Plugin filename
# User configs (from .schema.json)
WEATHER_API_KEY=abc123 # Passwords from Keychain
WEATHER_LOCATION=São Paulo
WEATHER_UNITS=metricFor comprehensive documentation, see:
- API Reference - Complete CLI command documentation (~75 commands)
- Plugin Development Guide - Lua-first development guide with multi-language support
- Configuration Schema - Field types and validation reference
- Security Policy - Vulnerability reporting and security considerations
Crossbar includes 25 Lua sample plugins that run on all platforms via the embedded Lua interpreter:
cpu.10s.lua- CPU usage with color codingmemory.10s.lua- RAM usage visualizationbattery.2s.lua- Battery status with dynamic iconsdisk.5m.lua- Disk space monitoruptime.1m.lua- System uptimesystem-info.1m.lua- Comprehensive system infoprocess-monitor.10s.lua- Top CPU processes
clock.1s.lua- Current time displaytime.1s.lua- Time with day phase iconemoji-clock.1m.lua- Time as emoji clock facesworld-clock.1m.lua- Multi-timezone clockscountdown.1s.lua- Event countdown timerpomodoro.1s.lua- Pomodoro technique timer
weather.30m.lua- Weather from OpenWeatherMap APIip-info.1h.lua- Public IP and geolocationsite-check.1m.lua- Website uptime checkernetwork.30s.lua- Network interface status
git-status.30s.lua- Git repository statusnpm-downloads.1h.lua- NPM package statsgithub-notifications.5m.lua- GitHub notification countspotify.5s.lua- Now playing on Spotifyssh-connections.30s.lua- Active SSH connections
todo.1m.lua- Simple todo listquotes.1h.lua- Random inspirational quotesbitcoin.5m.lua- BTC price from CoinGecko
Note: Users can still write plugins in Bash, Python, Node.js, Dart, Go, Rust, or YAML. Lua is the recommended default for cross-platform compatibility.
crossbar/
├── lib/
│ ├── core/ # Core plugin system (Flutter)
│ │ ├── plugin_manager.dart # Discovery & lifecycle
│ │ ├── script_runner.dart # Execution engine
│ │ ├── output_parser.dart # BitBar/JSON parser
│ │ └── api/ # CLI commands
│ ├── models/ # Data models
│ ├── services/ # Background services
│ │ ├── scheduler_service.dart # Auto-refresh triggers
│ │ ├── refresh_service.dart # Unified refresh engine
│ │ ├── tray_service.dart # System tray
│ │ ├── hot_reload_service.dart # File watcher
│ │ ├── marketplace_service.dart # Plugin discovery
│ │ ├── logger_service.dart # Rotating logs
│ │ ├── ipc_server.dart # Inter-process communication
│ │ ├── notification_service.dart # Cross-platform notifications
│ │ ├── settings_service.dart # User settings management
│ │ └── widget_service.dart # Home screen widget updates
│ ├── ui/ # User interface
│ └── l10n/ # 10 languages
├── packages/ # Monorepo packages
│ ├── crossbar_core/ # Pure Dart shared APIs & models
│ │ └── lib/src/
│ │ ├── core/ # Shared core utilities
│ │ ├── models/ # Plugin, Config models
│ │ └── api/ # System, Network, Media APIs
│ └── crossbar_cli/ # Pure Dart CLI package
│ ├── bin/crossbar.dart # CLI entry point
│ └── lib/src/
│ ├── core/ # CLI-specific plugin manager
│ └── commands/ # 76+ CLI command handlers
├── plugins/ # Example plugins
├── test/ # 116 tests (>90% coverage)
└── .github/workflows/ # CI/CD pipelines
# Run all tests
flutter test
# Run with coverage
flutter test --coverage
genhtml coverage/lcov.info -o coverage/html
open coverage/html/index.html
# Analyze code
flutter analyzeCurrent stats:
- 676 tests passing (individual test cases)
- 40.7% code coverage (Target: 60%)
- 0 analysis errors
- Core: Plugin discovery, execution, parsing
- Services: Background tasks, system integration
- UI: Flutter Material Design 3 interface
- CLI: Dart-based command-line API
- Flutter 3.35+ - Cross-platform framework
- Dart 3.10+ - Type-safe language
- tray_manager - System tray integration
- dio - HTTP client for API calls
- flutter_local_notifications - Push notifications
- home_widget - Home screen widgets
- flutter_secure_storage - Keychain integration
- Add API method in
lib/core/api/:
// lib/core/api/system_api.dart
Future<String> getHostname() async {
final result = await Process.run('hostname', []);
return result.stdout.toString().trim();
}- Add CLI handler in
lib/cli/cli_handler.dart(in the switch statement):
case 'hostname':
print(Platform.localHostname);Note: The main executable (crossbar) automatically supports both GUI (no args) and CLI (with args) modes.
- Add tests in
test/unit/core/api/system_api_test.dart
Crossbar supports 13 languages:
- 🇺🇸 English (en)
- 🇧🇷 Portuguese (pt)
- 🇪🇸 Spanish (es)
- 🇩🇪 German (de)
- 🇫🇷 French (fr)
- 🇨🇳 Chinese (zh)
- 🇯🇵 Japanese (ja)
- 🇰🇷 Korean (ko)
- 🇮🇹 Italian (it)
- 🇷🇺 Russian (ru)
- 🇸🇦 Arabic (ar)
- 🇧🇩 Bengali (bn)
- 🇮🇳 Hindi (hi)
Locale is auto-detected from system settings.
| Metric | Target | Actual |
|---|---|---|
| Boot Time (desktop) | <2s | ✅ ~1.5s |
| Memory (idle, 3 plugins) | <150MB | ✅ ~120MB |
| Plugin Execution Overhead | <50ms | ✅ ~30ms |
| Hot Reload | <1s | ✅ ~500ms |
| Binary Size (Linux) | <50MB | ✅ 41MB |
Contributions are welcome! Please read CONTRIBUTING.md for guidelines.
- 🐛 Report bugs via GitHub Issues
- 💡 Suggest features
- 📝 Improve documentation
- 🔌 Create and share plugins
- 🌐 Add translations
- 🧪 Write tests
This project is licensed under the GNU Affero General Public License v3.0 (AGPLv3).
This ensures that:
- ✅ You can use, modify, and distribute the software
- ✅ All derivatives must remain open source
- ✅ SaaS deployments must share source code (network copyleft)
- ✅ Community improvements benefit everyone
See LICENSE for full terms.
Inspired by:
Built with:
- 📖 Documentation
- 🐛 Issue Tracker
- 💬 Discussions
- 📧 Email: support@crossbar.dev (coming soon)
Full roadmap: See ROADMAP.md for detailed timeline, completed features, and technical debt tracking.
Mobile Mastery & Configuration Engine
- Configuration Engine: JSON schema support, secure storage (Keychain), and UI generation.
- Mobile Widgets: Native Android (XML) and iOS (WidgetKit) home screen widgets.
- Refresh Engine: Unified behavior across UI, Tray and Background.
- Core: Plugin Manager, Script Runner, Output Parser.
- CLI: 76+ commands.
- Platforms: Linux, macOS, Windows, Android, iOS.
Advanced Desktop UI & API Completion
- Global Hotkey (Ctrl+Alt+C).
- Tray Overflow Logic (Smart Collapse).
- Window State Persistence.
- New CLI commands:
location,qr.
- 🌐 Plugins remotos (execução server-side).
- 📊 Integração OpenTelemetry e Grafana.
- 🤖 Sugestões de plugins com IA.
- 🔗 Plataforma de integração (webhooks, IFTTT/Zapier).
- 🎮 Editor visual de plugins (no-code).
- 🌍 Extensão de navegador e suporte a smartwatch.
Quer influenciar o roadmap? Vote em funcionalidades nas GitHub Issues ou participe das Discussions!
📜 Changelog
See CHANGELOG.md for the complete version history.
🔒 Security Policy
See SECURITY.md for security policy, vulnerability reporting, and best practices.
🤝 Contributing
See CONTRIBUTING.md for contribution guidelines, development setup, and coding standards.
If you find Crossbar useful, please consider giving it a star!
Made with ❤️ by the Crossbar Team