Interactive setup CLI for Specchio iOS development environment.
Specchio Setup CLI simplifies the process of setting up a macOS development environment for the Specchio App . It automatically checks your system configuration, guides you through installing required tools (Xcode, iOS SDK, code signing certificates), and helps you connect and configure your iOS devices for development.
The easiest way to install specchio is via Homebrew:
brew tap Alexintosh/specchio
brew install specchioTo upgrade to the latest version:
brew upgrade specchioTo uninstall:
brew uninstall specchioAlternatively, you can download the binary directly from GitHub Releases:
# For Apple Silicon (ARM64)
curl -L https://github.com/Alexintosh/specchio/releases/latest/download/specchio-arm64 -o specchio
chmod +x specchio
sudo mv specchio /usr/local/bin/
# For Intel (x86_64)
curl -L https://github.com/Alexintosh/specchio/releases/latest/download/specchio-x64 -o specchio
chmod +x specchio
sudo mv specchio /usr/local/bin/- Interactive Setup Wizard - Step-by-step guidance through the entire setup process
- System Health Checks - Automatically verify macOS version, Xcode installation, iOS SDK, certificates, and connected devices
- Automatic Issue Detection - Identifies common configuration problems and suggests fixes
- Diagnostic Information - Gather detailed system information for troubleshooting
- Developer Mode Guidance - Helps enable Developer Mode on your iOS devices
- WiFi Debugging Setup - Configure wireless iOS deployment
- Cross-Architecture Support - Binaries available for both Apple Silicon and Intel Macs
The default command starts an interactive setup wizard that guides you through the entire process:
specchioThe wizard will:
- Check your macOS version (requires 14.0 Sonoma or later)
- Verify Xcode installation
- Accept the Xcode license
- Install the iOS SDK
- Create a code signing certificate
- Help you connect and configure your iOS device
- Enable Developer Mode and trust settings
Run all system checks to verify your development environment:
specchio checkRun a specific check:
specchio check macos # Check macOS version
specchio check xcode # Check Xcode installation
specchio check license # Check Xcode license status
specchio check ios-sdk # Check iOS SDK installation
specchio check certificate # Check code signing certificate
specchio check device # Check connected iOS deviceAttempt to automatically fix common issues:
specchio fixThis command will try to:
- Accept the Xcode license
- Configure Xcode developer tools
- Fix common certificate issues
Display detailed diagnostic information about your system:
specchio doctorOutput includes:
- System information (OS version, architecture, Bun version)
- Xcode information (version, license status)
- Development tools (git, brew, node, bun)
- Code signing certificates
- Connected iOS devices
Include this output when reporting bugs!
Check if your system is ready for Specchio development:
specchio verifyspecchio --help, -h # Show help message
specchio --version, -v # Show version information
specchio --verbose # Show detailed output# Start the interactive setup wizard
specchio
# Or run checks first to see what needs to be configured
specchio check
# Then fix any issues automatically
specchio fix# Get diagnostic information
specchio doctor
# Check a specific component
specchio check xcode
# Verify your setup is complete
specchio verify# Run all checks
specchio check
# Expected output:
# ✓ macOS 14.0 or later
# ✓ Xcode 15.0 or later installed
# ✓ Xcode license accepted
# ✓ iOS SDK installed
# ✓ Code signing certificate found
# ✓ iOS device connectedThis project uses Bun as the JavaScript runtime and build tool.
- Bun >= 1.0.0
- Git
# Clone the repository
git clone https://github.com/Alexintosh/specchio.git
cd specchio/cli
# Install dependencies
bun install
# Run in development mode with hot reload
bun run dev# Build to dist/ (for npm/bun packaging)
bun run build
# Build standalone binary for current architecture
bun run build:standalone
# Build for specific architectures
bun build --compile --target=bun-darwin-arm64 --outfile specchio-arm64 src/index.ts
bun build --compile --target=bun-darwin-x64 --outfile specchio-x64 src/index.ts# Run tests
bun testThis CLI provides utility functions in src/utils/:
import { exec, execWithSudo, execQuiet, commandExists } from './utils/exec.js';
// Execute command and get stdout
const output = await exec('sw_vers -productVersion');
// Execute with sudo privileges
await execWithSudo('xcodebuild -license accept');
// Execute without throwing on error
const result = await execQuiet('some-command');
console.log(result.stdout, result.stderr, result.exitCode);
// Check if command exists
const hasBun = await commandExists('bun');import { printSuccess, printError, printWarning, printInfo } from './utils/output.js';
printSuccess('Operation completed!');
printError('Something went wrong');
printWarning('This is a warning');
printInfo('Here is some info');
// Additional formatting functions
printHeader('Section Title');
printStep(1, 5, 'Installing dependencies');
printCommand('brew install bun');
printDivider();import { promptYesNo, promptContinue, promptText, promptSelect } from './utils/prompts.js';
// Yes/no prompt
const answer = await promptYesNo('Do you want to continue?');
// Press Enter to continue
await promptContinue('Press Enter when ready...');
// Text input
const name = await promptText('Enter your name', 'Default Name');
// Select from list
const options = ['Option 1', 'Option 2', 'Option 3'];
const selectedIndex = await promptSelect('Choose an option', options);
console.log(`You selected: ${options[selectedIndex]}`);- macOS 14.0 (Sonoma) or later
- Apple Silicon (M1/M2/M3/M4) or Intel processor
- Xcode 15.0 or later (from App Store)
- Xcode Command Line Tools
- Apple ID (for code signing)
- iPhone or iPad running iOS 16.0 or later (for testing)
Extensive documentation is available in the docs website.
To create a new release:
- Update the version in
package.jsonandsrc/index.ts - Build binaries for both architectures:
bun build --compile --target=bun-darwin-arm64 --outfile specchio-arm64 src/index.ts bun build --compile --target=bun-darwin-x64 --outfile specchio-x64 src/index.ts
- Generate SHA256 checksums:
shasum -a 256 specchio-arm64 shasum -a 256 specchio-x64
- Update the Homebrew formula with the new checksums
- Create a new GitHub release with the binaries
- Update the tag in the Homebrew formula
Contributions are welcome! Please read our Contributing Guidelines for details on our code of conduct and the process for submitting pull requests.
This project is licensed under the MIT License - see the LICENSE file for details.