✅ アプリケーション登録
Capgo にプロダクション チャネルでアプリケーションが登録されています。
このプラグインのインストールステップとフルマークダウンガイドまでの全てのステップを含むセットアップの質問をコピーします。
The Capgo CLI provides an interactive onboarding that sets up live updates for your Capacitor app. You’ll:
予想時間: 10-20分(インターネット接続速度とビルド時間に基づいて変わります)
API キーとともにオンボーディングコマンドを実行してください:
npx @capgo/cli@latest init [APIKEY]welcome メッセージが表示されます:
Capgo onboarding 🛫13 のインタラクティブ ステップで CLI が導きます:
セットアップフェーズ (ステップ 1-6):
@capgo/capacitor-updater プラグインテストフェーズ (ステップ 7-12):
完了 (ステップ 13):
CLIは開発環境を確認し、必要なツールがインストールされているかを確認します。
確認されるもの:
可能な結果:
✅ 両方の環境が見つかりました:
✅ Xcode detected - iOS development ready✅ Android SDK detected - Android development ready⚠️ 環境が見つかりませんでした:
⚠️ Xcode not found⚠️ Android SDK not found❌ No development environment detected
📱 To develop mobile apps with Capacitor, you need: • For iOS: Xcode (macOS only) - https://developer.apple.com/xcode/ • For Android: Android Studio - https://developer.android.com/studio質問されるかもしれません:
はCLIを使用してCapgoにログインし、アプリをアカウントに追加します。
(spinner) Running: npm @capgo/cli@latest login ***Login Done ✅
❓ Add {appId} in Capgo?アプリIDがすでに取られている場合:
はCLIが代替案を提示します:
❌ App ID "com.example.app" is already taken💡 Here are some suggestions: 1. com.example.app2 2. com.example.app3 3. com.example.app.new 4. com.example.app.app
❓ What would you like to do?代替案を選択するか、カスタムアプリIDを入力できます。
チャンネルは、アプリの更新フローを管理するために使用できます。
❓ Create default channel production for {appId} in Capgo?はいを選択した場合:
(spinner) Running: npm @capgo/cli@latest channel add production {appId} --defaultChannel add Done ✅ (or "Channel already added ✅")production チャンネルが作成され、デフォルトの設定になります。このオプションは、ほとんどのユーザーにとって推奨されるオプションです。
はいを選択しない場合:
If you change your mind, run it for yourself with: "npm @capgo/cli@latest channel add production {appId} --default"後でチャンネルを作成および設定する必要があります。代わりに、
capacitor.config.ts チャンネルを設定するsetChannel() 方法を使用して、動的にチャンネルを設定するCLIは、CLIのバージョンに適合した @capgo/capacitor-updater plugin compatible with your Capacitor version.
❓ Automatic Install "@capgo/capacitor-updater" dependency in {appId}?バージョン互換性:
@capgo/capacitor-updater v5@capgo/capacitor-updater v6@capgo/capacitor-updater v7即時更新オプション:
インストール後、次の質問が行われます:
❓ Do you want to set instant updates in {appId}? Read more: https://capgo.app/docs/live-updates/update-behavior/#applying-updates-immediatelyYesを選択した場合:
directUpdate: 'always' そして autoSplashscreen: true configに追加されますcapacitor.config.ts 自動的に更新されますあなたが「No」を選択した場合:
capacitor.config.tsCLIは、必要なcodeを自動的にあなたの主なアプリケーションファイルにインジェクトします。
❓ Automatic Add "CapacitorUpdater.notifyAppReady()" code and import in {appId}?何が追加される:
import { CapacitorUpdater } from '@capgo/capacitor-updater'
CapacitorUpdater.notifyAppReady()プロジェクトタイプの検出:
plugins/capacitorUpdater.client.tsエンドツーエンド暗号化は、更新のセキュリティ層を追加します。
🔐 End-to-end encryption ✅ Use this for: Banking, healthcare, or apps with legal encryption requirements ⚠️ Note: Makes debugging harder - skip if you don't need it
❓ Enable end-to-end encryption for {appId} updates?CLI を有効にすると、次のことが行われます。
初期設定の際にテストするプラットフォームを選択します。
📱 Platform selection for onboarding This is just for testing during onboarding - your app will work on all platforms
❓ Which platform do you want to test with during this onboarding? Options: - iOS - AndroidCLIはアプリをビルドし、Capacitorと同期します。
❓ Automatic build {appId} with "npm run build"?何が起こるか:
npx cap sync {platform}ビルドスクリプトが見つからない場合:
ビルドをスキップするか、プロジェクトにビルドスクリプトを追加するかを尋ねられます。 package.json.
デバイスまたはシミュレータでアプリの初期バージョンをテストしてください。
❓ Run {appId} on {PLATFORM} device now to test the initial version?あなたが選択した場合 はい:
(spinner) Running: npx cap run {platform}(device picker appears)App started ✅📱 Your app should now be running on your {platform} device with Capgo integrated🔄 This is your baseline version - we'll create an update nextあなたは Capgo の更新システムをテストするために、変更を実行する必要があります。
🎯 Now let's test Capgo by making a visible change and deploying an update!
❓ How would you like to test the update? Options: - Auto: Let Capgo CLI make a visible change for you - Manual: I'll make changes myself自動モード: CLI は自動的にファイルを変更して、テスト用の表示可能なバナーを追加します。
手動モード: あなた自身で変更を加えることができます (例: テキスト、色、または要素を追加)。
バージョン管理:
❓ How do you want to handle the version for this update? Options: - Auto: Bump patch version ({currentVersion} → {nextVersion}) - Manual: I'll provide the version number変更を反映したビルド:
❓ Build {appId} with changes before uploading?あなたのアップデートされたアプリケーションバンドルを Capgo にアップロードしてください。
❓ Upload the updated {appId} bundle (v{version}) to Capgo?CapgoはCLIを実行します。
npx @capgo/cli@latest bundle uploadΔルートの更新は、直接更新が有効の場合に提示されます。
💡 Direct Update (instant updates) is enabled in your config Delta updates send only changed files instead of the full bundle
❓ Enable delta updates for this upload? (Recommended with Direct Update)成功:
✅ Update v{version} uploaded successfully!🎉 Your updated bundle is now available on Capgoアップデートを実行してみましょう!
🧪 Time to test the Capgo update system!📱 Go to your device where the app is running即時更新の場合:
🔄 IMPORTANT: Background your app (swipe up/press home button) and then reopen it⏱️ The update should be downloaded and applied automatically標準的な更新の場合:
📱 With standard updates, you will need to: 1. Background the app (swipe up/press home button) to start download 2. Wait a few seconds for download to complete 3. Background and foreground again to see the updateログの監視:
❓ Monitor Capgo logs to verify the update worked?あなたが選択した場合 はいあなたは、デバイスから実行中の更新プロセスをリアルタイムで表示することができます。
Welcome onboard ✈️!おめでとうございます!あなたはアプリのCapgoライブアップデートを成功で設定しました。
オンボーディングを完了した後、次のことが実行されます:
✅ アプリケーション登録
Capgo にプロダクション チャネルでアプリケーションが登録されています。
✅ プラグインのインストール
Capacitor アップデート プラグインがインストールおよび設定されています。
✅ Code の統合
code の統合がアプリケーションに追加されています。
✅ アップデートのテスト
ライブ アップデートを成功的にデプロイし、更新を受信しました。
以降のアップデートの場合、使用してください:
npm run buildnpx @capgo/cli@latest bundle upload --channel=production詳細なデプロイオプションについては ライブアップデートをデプロイ.
オンボーディングプロセスを中断しても、いつでも再開できます。
npx @capgo/cli@latest init [APIKEY]次のようになります。
You have already got to the step {stepNumber}/13 in the previous session❓ Would you like to continue from where you left off?問題: XcodeやAndroid SDK のいずれも検出されませんでした。
解決策
問題: あなたのアプリIDはすでに登録されています。
解決策: 提案されたオプションのいずれかを選択するか、逆ドメイン記法でカスタムのアプリIDを入力してください。
問題: No build script found in __CAPGO_KEEP_0__. package.json.
解決策: Add a build script to your __CAPGO_KEEP_0__. package.json:
{ "scripts": { "build": "your-build-command" }}問題: CLI は自動的に code の統合を挿入できません。
解決策: Add the code manually to your main file:
import { CapacitorUpdater } from '@capgo/capacitor-updater'
CapacitorUpdater.notifyAppReady()問題: Capacitor のバージョンは v5 未満です。
解決策: Capacitor を v5 またはそれ以上のバージョンにアップグレードしてください。
オンボーディングを完了した後は、これらのトピックを探索してください:
Deploy Updates
Capgoのアップデートをデプロイする方法を学びましょう
Update Types
OTAアップデートの種類のリファレンス: アプリケーションタイミング、遅延条件、バージョンブロッキング、配信
CI/CD Integration
CI/CDを使用してアップデートのデプロイを自動化
Channels
複数のアップデートストリームを管理するチャンネル
Encryption
アップデートをエンドツーエンドで暗号化してセキュリティを確保
Update Behavior
アップデートの適用時期と方法をカスタマイズ(直接、デルタなど)
初期設定中に問題が発生した場合