asc-signing-setup
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
Chineseasc signing setup
asc 签名配置
Use this skill when you need to create or renew signing assets for iOS/macOS apps.
当你需要为iOS/macOS应用创建或更新签名资产时,可以使用该技能。
Preconditions
前置条件
- Auth is configured (or
asc auth loginenv vars).ASC_* - You know the bundle identifier and target platform.
- You have a CSR file for certificate creation.
- 已完成身份验证配置(或设置
asc auth login环境变量)。ASC_* - 已知应用的Bundle ID和目标平台。
- 拥有用于创建证书的CSR文件。
Workflow
操作流程
- Create or find the bundle ID:
asc bundle-ids list --paginateasc bundle-ids create --identifier "com.example.app" --name "Example" --platform IOS
- Configure bundle ID capabilities:
asc bundle-ids capabilities list --bundle "BUNDLE_ID"asc bundle-ids capabilities add --bundle "BUNDLE_ID" --capability ICLOUD- Add capability settings when required:
--settings '[{"key":"ICLOUD_VERSION","options":[{"key":"XCODE_13","enabled":true}]}]'
- Create a signing certificate:
asc certificates list --certificate-type IOS_DISTRIBUTIONasc certificates create --certificate-type IOS_DISTRIBUTION --csr "./cert.csr"
- Create a provisioning profile:
asc profiles create --name "AppStore Profile" --profile-type IOS_APP_STORE --bundle "BUNDLE_ID" --certificate "CERT_ID"- Include devices for development/ad-hoc:
asc profiles create --name "Dev Profile" --profile-type IOS_APP_DEVELOPMENT --bundle "BUNDLE_ID" --certificate "CERT_ID" --device "DEVICE_ID"
- Download the profile:
asc profiles download --id "PROFILE_ID" --output "./profiles/AppStore.mobileprovision"
- 创建或查找Bundle ID:
asc bundle-ids list --paginateasc bundle-ids create --identifier "com.example.app" --name "Example" --platform IOS
- 配置Bundle ID的功能权限:
asc bundle-ids capabilities list --bundle "BUNDLE_ID"asc bundle-ids capabilities add --bundle "BUNDLE_ID" --capability ICLOUD- 按需添加功能权限设置:
--settings '[{"key":"ICLOUD_VERSION","options":[{"key":"XCODE_13","enabled":true}]}]'
- 创建签名证书:
asc certificates list --certificate-type IOS_DISTRIBUTIONasc certificates create --certificate-type IOS_DISTRIBUTION --csr "./cert.csr"
- 创建配置描述文件:
asc profiles create --name "AppStore Profile" --profile-type IOS_APP_STORE --bundle "BUNDLE_ID" --certificate "CERT_ID"- 若用于开发/临时分发,需添加设备:
asc profiles create --name "Dev Profile" --profile-type IOS_APP_DEVELOPMENT --bundle "BUNDLE_ID" --certificate "CERT_ID" --device "DEVICE_ID"
- 下载配置描述文件:
asc profiles download --id "PROFILE_ID" --output "./profiles/AppStore.mobileprovision"
Rotation and cleanup
轮换与清理
- Revoke old certificates:
asc certificates revoke --id "CERT_ID" --confirm
- Delete old profiles:
asc profiles delete --id "PROFILE_ID" --confirm
- 吊销旧证书:
asc certificates revoke --id "CERT_ID" --confirm
- 删除旧的配置描述文件:
asc profiles delete --id "PROFILE_ID" --confirm
Shared team storage with asc signing sync
asc signing sync使用asc signing sync
实现团队共享存储
asc signing syncUse this when you want a lightweight, non-interactive alternative to fastlane match for encrypted git-backed certificate/profile storage.
bash
undefined如果你需要一个轻量、非交互式的方案来替代fastlane match,实现基于Git的加密证书/配置文件存储,可以使用该功能。
bash
undefinedPush current ASC signing assets into an encrypted git repo
将当前ASC签名资产推送到加密的Git仓库
asc signing sync push
--bundle-id "com.example.app"
--profile-type IOS_APP_STORE
--repo "git@github.com:team/certs.git"
--password "$MATCH_PASSWORD"
--bundle-id "com.example.app"
--profile-type IOS_APP_STORE
--repo "git@github.com:team/certs.git"
--password "$MATCH_PASSWORD"
asc signing sync push
--bundle-id "com.example.app"
--profile-type IOS_APP_STORE
--repo "git@github.com:team/certs.git"
--password "$MATCH_PASSWORD"
--bundle-id "com.example.app"
--profile-type IOS_APP_STORE
--repo "git@github.com:team/certs.git"
--password "$MATCH_PASSWORD"
Pull and decrypt them into a local directory
拉取并解密到本地目录
asc signing sync pull
--repo "git@github.com:team/certs.git"
--password "$MATCH_PASSWORD"
--output-dir "./signing"
--repo "git@github.com:team/certs.git"
--password "$MATCH_PASSWORD"
--output-dir "./signing"
Notes:
- `--password` falls back to `ASC_MATCH_PASSWORD`.
- The encrypted repo follows a familiar match-style git layout for certs and profiles.
- `pull` writes files to disk; keychain import or profile installation is a separate step.asc signing sync pull
--repo "git@github.com:team/certs.git"
--password "$MATCH_PASSWORD"
--output-dir "./signing"
--repo "git@github.com:team/certs.git"
--password "$MATCH_PASSWORD"
--output-dir "./signing"
注意事项:
- `--password` 参数会默认使用 `ASC_MATCH_PASSWORD` 环境变量的值。
- 加密仓库的目录结构与fastlane match的Git布局一致,用于存储证书和配置描述文件。
- `pull` 命令仅将文件写入磁盘;导入钥匙串或安装配置描述文件需要单独执行步骤。Notes
其他注意事项
- Always check for the exact enum values (certificate types, profile types).
--help - Use for large accounts.
--paginate - accepts comma-separated IDs when multiple certificates are required.
--certificate - Device management uses commands (UDID required).
asc devices
- 如需了解确切的枚举值(如证书类型、配置描述文件类型),请始终查看信息。
--help - 对于大型账号,请使用参数分页查询。
--paginate - 当需要多个证书时,参数接受逗号分隔的ID列表。
--certificate - 设备管理需使用系列命令(需要设备UDID)。
asc devices