スキル一覧に戻る
leepokai

setup

by leepokai

1🍴 0📅 2026年1月20日
GitHubで見るManusで実行

SKILL.md


name: setup description: This skill should be used when the user asks to "setup smart build", "configure build settings", "initialize smart build", "run setup", or uses the /setup command. First-time configuration for Smart Build plugin.

Smart Build Setup Skill

⚠️ CRITICAL: READ THIS FIRST

YOU MUST follow these instructions EXACTLY as written.

DO NOT:

  • ❌ Use Search or Glob tools - use the exact bash commands shown
  • ❌ Skip steps or change the order
  • ❌ Assume user preferences - YOU MUST use AskUserQuestion
  • ❌ Use AppleScript or osascript
  • ❌ Improvise or use alternative methods

YOU MUST:

  • ✅ Run the EXACT bash commands shown in each step
  • ✅ Use AskUserQuestion to ask user for mode preference
  • ✅ Follow the step order: 1 → 2 → 3 → 4

Step 1: Check Project Directory

YOU MUST run this command first:

ls *.xcodeproj 2>/dev/null || ls *.xcworkspace 2>/dev/null || echo "NO_PROJECT"

If output is "NO_PROJECT": STOP and tell user:

"No Xcode project found. Please run Claude from your project directory:

cd /path/to/YourApp
claude

Then run /swiftui-smart-build:setup again."

Do NOT proceed if no project found.


Step 2: Check Existing Config

YOU MUST run:

cat .smart-build.json 2>/dev/null || echo "NO_CONFIG"

If config exists: Show current settings and ask if user wants to reconfigure.

If "NO_CONFIG": Continue to Step 3.


Step 3: Ask User Preference

YOU MUST use AskUserQuestion with these exact options:

Question: "How should Smart Build determine your build settings?"

Options:
1. "Xcode Sync (Recommended)" - Automatically use whatever is selected in Xcode
2. "Custom" - Specify a fixed scheme and destination

Step 4A: Xcode Sync Mode

If user chose Xcode Sync:

  1. Show current Xcode settings:
${CLAUDE_PLUGIN_ROOT}/scripts/get-xcode-settings.sh
  1. Create config file with EXACTLY this format:
{
  "mode": "xcode"
}
  1. Write to file:
echo '{"mode": "xcode"}' > .smart-build.json
  1. Tell user: "Setup complete! Smart Build will sync with Xcode."

Step 4B: Custom Mode

If user chose Custom:

  1. List available schemes:
xcodebuild -project *.xcodeproj -list -json 2>/dev/null | jq -r '.project.schemes[]'
  1. Ask user to pick a scheme using AskUserQuestion

  2. List available simulators:

xcrun simctl list devices available -j | jq -r '.devices[][] | select(.isAvailable==true) | select(.name | contains("iPhone")) | "\(.name) - \(.udid)"' | head -10
  1. Ask user to pick a destination using AskUserQuestion

  2. Create config file with EXACTLY this format:

{
  "mode": "custom",
  "scheme": "<USER_SELECTED_SCHEME>",
  "destination": {
    "type": "simulator",
    "name": "<DEVICE_NAME>",
    "udid": "<DEVICE_UDID>",
    "platform": "iphonesimulator"
  }
}
  1. Write config to .smart-build.json

Config Format

Xcode mode (simple):

{
  "mode": "xcode"
}

Custom mode:

{
  "mode": "custom",
  "scheme": "MyApp",
  "destination": {
    "type": "simulator",
    "name": "iPhone 16 Pro",
    "udid": "12345678-ABCD-1234-ABCD-123456789ABC",
    "platform": "iphonesimulator"
  }
}

DO NOT

❌ Do NOT add fields like xcodeSync, projectPath, defaultScheme, defaultDestination ❌ Do NOT use AppleScript to get Xcode settings ❌ Do NOT skip asking user for their preference ❌ Do NOT create config if no .xcodeproj found ❌ Do NOT use any format other than what is specified above

スコア

総合スコア

50/100

リポジトリの品質指標に基づく評価

SKILL.md

SKILL.mdファイルが含まれている

+20
LICENSE

ライセンスが設定されている

0/10
説明文

100文字以上の説明がある

0/10
人気

GitHub Stars 100以上

0/15
最近の活動

3ヶ月以内に更新がある

0/10
フォーク

10回以上フォークされている

0/5
Issue管理

オープンIssueが50未満

+5
言語

プログラミング言語が設定されている

+5
タグ

1つ以上のタグが設定されている

0/5

レビュー

💬

レビュー機能は近日公開予定です