🏠 Home38 — Complete Developer Setup

Mac Mini Setup
+ Flutter + App Store

Your complete guide, Diavallan — from unboxing the Mac mini to submitting apps to the App Store and Google Play. Run a FREE local AI while you build. Let's go. 🔥

🍎 Mac Setup 🐦 Flutter 📱 App Stores 🧠 Free Local AI 🎤 Clash App Mic Fix
🎧
Listen to This Guide
Web Speech API · Reads each section aloud · Auto-scrolls
Speed:
Click ▶ Start Reading to hear this guide read aloud.
🍎
Section 1
Mac Mini Initial Setup
From box-open to fully ready developer machine — every step.
1
Unbox & Connect Everything

Plug in: power cable → HDMI to monitor → USB keyboard & mouse

  • No monitor? Use an iPad/iPhone with Sidecar or find a TV with HDMI input
  • No keyboard? A Bluetooth keyboard works — hold power button to enter pairing mode
  • iPhone as hotspot: Settings → Personal Hotspot → Allow Others to Join
2
First Power On → Setup Assistant

Press the power button on the back. macOS Setup Assistant will guide you through:

  • Language & Region selection
  • Wi-Fi setup (connect to your home network or iPhone hotspot)
  • Accessibility options (skip for now)
  • Data & Privacy settings
Choose "Set Up Later" for anything that can wait — you can always configure later in System Settings.
3
Sign in with Apple ID

When prompted, sign in with your existing Apple ID:

Email: diawarrior@gmail.com
ℹ️ This Apple ID is also used for the Apple Developer Program ($99/year) and App Store Connect submissions.
4
Enable iCloud Sync for Documents

System Settings → [Your Name] → iCloud → iCloud Drive → Options

  • Turn on Desktop & Documents Folders — instant backup to cloud
  • Enable Photos if you want cross-device photo sync
5
Privacy & Security Settings

System Settings → Privacy & Security → Security

Set "Allow apps downloaded from" → App Store and identified developers

⚠️ Required for Homebrew and Flutter tools to run. Without this, you'll get constant "unidentified developer" blocks.
6
Install All macOS Updates

System Settings → General → Software Update

Install everything. This may take 10–30 minutes and require a restart.

An up-to-date macOS = fewer compatibility issues with Flutter, Xcode, and dev tools.
7
Install Homebrew (Package Manager)

Open Terminal (Applications → Utilities → Terminal) and run:

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

Enter your Mac password when asked. The install takes 5–10 minutes.

ℹ️ Homebrew is like an app store for the Terminal — every dev tool you need can be installed with brew install.
8
Add Homebrew to PATH

Run these two commands after Homebrew installs:

echo 'eval "$(/opt/homebrew/bin/brew shellenv)"' >> ~/.zprofile source ~/.zprofile

Verify it works:

brew --version
9
Install Git, Node.js & VS Code
# Install Git (version control) brew install git # Install Node.js (for OpenClaw + web dev) brew install node # Install VS Code (best code editor) brew install --cask visual-studio-code

Verify installs:

git --version node --version code --version
10
Install Xcode from App Store

Open App Store → search "Xcode" → Install

⚠️ ~15GB download. Plug in power, connect to fast Wi-Fi, and let it run overnight if needed. This is REQUIRED for iOS builds.

After install, run the first launch setup:

sudo xcode-select --install xcodebuild -runFirstLaunch

Accept the license when prompted. This installs iOS simulators and build tools.

🤖
Section 2
Connect OpenClaw AI to Mac Mini
So Kreator can run from your Mac instead of the Raspberry Pi — or both at once.
1
Find Your Raspberry Pi IP Address

On your Raspberry Pi, open terminal and run:

hostname -I

You'll see something like 192.168.1.45 — note this down.

Or use the Tailscale IP which works from anywhere: 100.100.237.123

2
Install Tailscale on Mac (Secure VPN)

Tailscale lets Mac and Pi connect securely from anywhere — even different networks.

brew install --cask tailscale

Open Tailscale from Applications → Sign in with the same account as your Pi.

Now SSH to Pi from Mac using Tailscale IP:

ssh kreator@100.100.237.123
3
Sync Workspace from Pi to Mac

On your Mac, run this to copy the Pi's OpenClaw workspace:

rsync -avz kreator@100.100.237.123:~/.openclaw/workspace/ ~/openclaw-workspace/
ℹ️ Run this periodically to keep Mac workspace in sync with Pi. Add --delete flag to mirror exactly.
4
Install OpenClaw Natively on Mac (Optional)

Make the Mac a full OpenClaw host:

# Install OpenClaw globally npm install -g openclaw # Initialize a new OpenClaw instance openclaw init # Start the gateway service openclaw gateway start
Now you can run Kreator from the Mac! Same WhatsApp/Telegram connections — just configure the same API keys in openclaw init.
5
VS Code Remote SSH — Edit Pi Files from Mac

This is a game-changer: edit your Pi's files using the full Mac VS Code:

  1. Open VS Code → Extensions → search "Remote - SSH" → Install
  2. Press Cmd+Shift+P → "Remote-SSH: Connect to Host"
  3. Enter: kreator@100.100.237.123
  4. VS Code opens the Pi's filesystem on your Mac screen 🚀
🔥 This is the BEST way to work on Pi files. Full VS Code features, autocomplete, file explorer — all running on the Pi but displayed on Mac.
🐦
Section 3
Install Flutter
Full Flutter SDK setup for iOS + Android development on your Mac mini.
1
Download Flutter SDK
# Clone stable Flutter release git clone https://github.com/flutter/flutter.git -b stable ~/flutter # Add Flutter to your PATH echo 'export PATH="$HOME/flutter/bin:$PATH"' >> ~/.zprofile source ~/.zprofile # Verify installation flutter --version
2
Run Flutter Doctor
flutter doctor

You'll see a list of checks. Green ✓ = good, Red ✗ = needs fixing.

Common fixes flutter doctor suggests:

  • Xcode license: sudo xcodebuild -license
  • CocoaPods: sudo gem install cocoapods
  • Android licenses: flutter doctor --android-licenses
3
iOS Setup — CocoaPods + Simulator
# Install CocoaPods (iOS dependency manager) sudo gem install cocoapods # Or with Homebrew (recommended) brew install cocoapods

Then in Xcode:

  • Xcode → Settings → Platforms
  • Download the iOS Simulator (pick latest iOS version)
  • This lets you test your app without a real iPhone
4
Android Setup — Android Studio + SDK
# Install Android Studio brew install --cask android-studio

Open Android Studio then:

  1. More Actions → SDK Manager
  2. Install: Android SDK, SDK Build-Tools, SDK Platform-Tools
  3. Accept all licenses from terminal:
flutter doctor --android-licenses

Type y to accept each license.

5
Verify & Create Test Project
# Full verbose check — all should be green ✓ flutter doctor -v

Create and run a test project:

flutter create my_test_app cd my_test_app flutter run
🎉 If the demo app launches on simulator, you're ready to build real apps!
📱
Section 4
Convert Web Apps to Flutter
Turn your existing reggae-square.com apps into native iOS/Android apps.
1
Two Approaches — Choose Your Strategy
Option A — Fast
WebView Wrapper
Load your existing web app inside a Flutter WebView. App in stores within days. Best for getting started.
Option B — Best
Native Flutter Rebuild
Rebuild UI with Flutter widgets. Better performance, offline support, native features. Takes longer but is the real deal.
💡 Start with Option A to get into stores FAST. Then rebuild natively in the background while users already have your app.
2
WebView Wrapper — Get Into Stores Fast
# Create a new Flutter project flutter create clash_app cd clash_app # Add WebView package flutter pub add webview_flutter

In lib/main.dart, replace the body with:

3
Clash App — Full Native Setup

Your pubspec.yaml dependencies section should include:

4
Add iOS Permissions (Info.plist)

Edit ios/Runner/Info.plist — add these keys before </dict>:

⚠️ Apple WILL reject your app if you request mic access without a clear description. Be specific about why you need it.
5
Add Android Permissions (AndroidManifest.xml)

Edit android/app/src/main/AndroidManifest.xml — add inside <manifest>:

🍎
Section 5
Submit to Apple App Store
From Xcode archive to App Store Connect — step by step.
1
Enroll in Apple Developer Program

Go to developer.apple.com → Account → Enroll

  • Cost: $99 USD/year
  • Sign in with: diawarrior@gmail.com
  • Approval takes 24–48 hours
  • Gives you: App Store distribution, TestFlight, Apple Pay, iCloud, push notifications
⚠️ You CANNOT submit apps without this. Do this first — it takes time to activate.
2
Create App ID & Bundle Identifier

developer.apple.com → Certificates, IDs & Profiles → Identifiers → +

  • Type: App IDs
  • Platform: iOS
  • Bundle ID: com.buildersmusic.clashapp (Explicit)
  • Enable capabilities: Push Notifications, Sign In with Apple (if needed)
3
Configure Xcode for Release

In your Flutter project, open Xcode:

In Xcode → select RunnerSigning & Capabilities:

  • Team: Select your developer account
  • Bundle Identifier: com.buildersmusic.clashapp
  • Version: 1.0.0
  • Build: 1

Change the target to "Any iOS Device (arm64)"

4
Archive & Upload to App Store

In Xcode menu:

  1. Product → Archive (takes a few minutes to build)
  2. Organizer window opens → click Distribute App
  3. Method: App Store Connect
  4. Options: Leave defaults → click Upload
  5. Processing takes 5–30 minutes in App Store Connect
ℹ️ Or use the command line: flutter build ipa --release then upload the .ipa with Transporter app.
5
Submit in App Store Connect

Go to appstoreconnect.apple.com:

  1. My Apps → + New App
  2. Name, Bundle ID, SKU, language
  3. Fill in: Description, Keywords, Support URL, Privacy Policy URL
  4. Screenshots: required for iPhone 6.5" and 5.5" sizes (use simulator screenshots)
  5. Select your uploaded Build
  6. Pricing: Free or set your price
  7. Click Submit for Review
Review usually takes 1–3 days. You'll get an email when approved or if there are issues.
▶️
Section 6
Submit to Google Play Store
One-time $25 fee. Build your Android App Bundle and submit.
1
Create Google Play Developer Account

Go to play.google.com/console

  • Sign in with your Google account
  • Pay: $25 USD one-time fee (no annual renewal!)
  • Fill in developer profile
  • Account activation: instant to 48 hours
Unlike Apple, Google's fee is one-time only. Pay once, publish forever.
2
Create Your Signing Keystore

CRITICAL: Every Android app needs to be signed. Do this ONCE — save the file safely:

keytool -genkey -v \ -keystore ~/upload-keystore.jks \ -keyalg RSA \ -keysize 2048 \ -validity 10000 \ -alias upload
🚨 Back up upload-keystore.jks to iCloud/Google Drive! If you lose this file, you can NEVER update your app — you'd have to create a new listing.
3
Configure Signing in Flutter

Create android/key.properties:

storePassword=YOUR_STORE_PASSWORD keyPassword=YOUR_KEY_PASSWORD keyAlias=upload storeFile=/Users/YOUR_USERNAME/upload-keystore.jks

In android/app/build.gradle, add signing config in the android block.

ℹ️ Add android/key.properties to .gitignore — never commit passwords to git!
4
Build Release App Bundle (AAB)

Google Play uses .aab (Android App Bundle) — it's smaller and more efficient than .apk.

5
Submit in Play Console

In play.google.com/console:

  1. Create app → App name, language, type (app/game), free/paid
  2. Fill store listing: Short description, Full description
  3. Add screenshots (phone, tablet if available)
  4. Add Feature graphic (1024×500px banner)
  5. Production → Releases → Create release
  6. Upload your app-release.aab
  7. Add release notes → Review and Publish
Google review: 1–7 days for new apps. Updates are usually approved within hours.
🧠
Section 7
Run FREE Local AI on Mac (Ollama)
Develop and test AI features without paying API costs. Runs 100% on your Mac mini — no internet needed.
1
Install Ollama
# Install Ollama brew install ollama # Start the Ollama service ollama serve

Keep this terminal open, or run it as a background service:

2
Download an AI Model

Choose based on your Mac mini's RAM:

Llama 3.2 3B
~2GB download
⚡ Fastest
Llama 3.1 8B
~5GB download
✨ Balanced
CodeLlama 7B
~4GB download
💻 Code
Mistral 7B
~4GB download
🏆 Best Overall
3
Chat With Your Local AI
🔥 100% FREE. 100% private. Runs completely offline. Your Mac mini's Apple Silicon chip makes this fast!
4
Use Ollama with OpenClaw

In your OpenClaw config file, add:

provider: ollama model: llama3.2:3b baseUrl: http://localhost:11434

OpenClaw will now use your FREE local AI instead of paying for Claude/GPT API calls.

ℹ️ Quality note: local models are good for coding help and quick questions. For complex reasoning, the paid models (Claude/GPT) are still better.
5
Web UI — ChatGPT-Style Interface

Get a beautiful ChatGPT-like interface for your local AI:

Open http://localhost:3000 in your browser → create account → start chatting!

🎯 This gives you a full ChatGPT-style UI with chat history, multiple models, file uploads — all FREE, all local on your Mac.
🎤
Section 8
Fix Clash App Mic System in Flutter
The web version's mic won't work in native apps. Here's the complete Flutter mic fix.
1
Why the Web Mic Doesn't Work in Native Apps

The problem: Your web Clash App uses WebRTC/getUserMedia — this only works in browsers.

When you wrap it in a WebView for native apps:

  • iOS: Safari's WebView blocks mic access without native permission grant
  • Android: WebView needs special flags to allow mic
  • Both: App Store / Play Store may reject WebRTC mic usage in WebViews

The solution: Use the record package for native microphone access.

2
Add Audio Packages
3
Request Mic Permission in Code
4
Record Audio for Clash Battles
5
Live Audio Streaming for Real-Time Battles

For real-time clash battles (live streaming audio):

⚠️ Always test on a real device! Microphone never works on the iOS/Android simulator. Plug in a real iPhone or Android phone to test audio.
6
Enable Mic in WebView (If Using Web Wrapper)

If you're using WebView to load your web Clash App, enable mic access:

💡 The onPermissionRequest callback auto-grants mic permission when your web app's JavaScript requests it. This works for modern WebView Flutter package.