- Macアプリの申請をFastlaneで行えるようにしようとした。
- メタ情報の更新はできるものの、バイナリのアップロードが上手くいかなかった。
- コードを読んだり、Issuesなどを見ている限り、最新版(1.101.0)ではMac App Storeの申請ができないのかも?
Mac App Storeへのビルドのアップロードに対応しているのか?
GitHub上には、Map App Storeへのビルドのアップロードに対応しているように解釈できる記述が幾つか存在している。
fastlane is a tool for iOS, Mac, and Android developers to automate tedious tasks like generating screenshots, dealing with provisioning profiles, and releasing your application.
gym already does support Mac apps. Or did you run into problems using it?
There is even a Mac project example in the examples directory
※ただし、最新のExampleにはMacアプリのバイナリアップロードをするものはなさそう…
一方で、Issueにはこんな記述もある。(Sep 16, 2015)
@fousa right now deliver only supports app metadata and screenshots for Mac applications, not the binary. If you find a way to upload a mac application using the iTunes Transporter command line tool, I'm happy to integrate this into deliver. You're right, there are some validations to make sure the file format is ipa.
何がうまくいかないか
'/path/to/MyMacApp.app' doesn't seem to be an ipa file
fastlane mac appstore
で、deliver
の段階でファイルがipa
じゃないというエラーが起きる。
deliver fails on a macOS app with the message
deliver seems to think mac app is iOS #5757 まさにこの問題。
Macアプリなのだが、deliver
がipa
ファイルをアップロードしようとして、エラーが発生する。
コードと説明から推測する正しいフロー
-
fastlane
はMacアプリに関するactionの時は、下記のような振る舞いをする。 -
gym
がpkg
ファイルを生成する。 -
deliver
がpkg
ファイルをApp Storeにアップロードする。
deliver
の説明にはIf you use fastlane you don't have to manually specify the path to your ipa/pkg file.
という記述があるのだが、どうやらこれが動いていないようだ。
gymでpkgファイルを作ることができない?
こちらのIssueでは、下記のような指摘がされている。
The issue is gym doesn't generate any .pkg archive to be able pass forward to Deliver.
gym
でMacアプリをビルドすると.app
がつくられるのだが、deliver
は.pkg
ファイルを求めるので、そこで齟齬が発生している模様。
gym builds and packages iOS and macOS apps for you. It takes care of all the heavy lifting and makes it super easy to generate a signed ipa or app file 💪
gym
の説明では、ipa
かapp
を作ることができる、と書いてあり、pkg
に関する記述はない。
また、ソースコードのオプションに関する実装を読んでも、pkg
を生成するオプションはなさそうだ。
サンプルのFastlaneを見ても、macの時はバイナリのアップロードをしていない
githubにあがっているMindNoteアプリのサンプルの設定では、iOSの方にはApp Storeにバイナリをアップロードするための設定があるが、macの方にはメタ情報のアップロードしかない。
platform :mac do
desc "[WIP] Upload App Metadata of the Mac App to iTunes Connect"
lane :metadata do
deliver(
skip_deploy: true,
force: true,
deliver_file_path: File.join(Dir.pwd, 'Mac') # Mac specific app metadata
)
end
desc "Adds frames around the screenshots located in `./fastlane/Mac/screenshots`"
desc "This will not generate new screenshots, but only frame the existing ones"
lane :screenshots do
frameit(path: './fastlane/Mac/screenshots', force_device_type: "Mac")
end
desc "Uploads metadata only (Mac) - no binary will be uploaded"
desc "You'll get a summary of the collected metadata before it's uploaded"
lane :upload_metadata do
deliver(
metadata_only: true,
deliver_file_path: File.join(Dir.pwd, 'Mac') # Mac specific app metadata)
)
end
end
結論: 一旦諦めた
どうやら、もともとはMacアプリもバイナリのアップロードまで対応していたようだが、iTunes Connectのアップデートなど諸々の理由で、現時点では正しく動作しなくなっている可能性が高そう。Macアプリに関するFastlaneの記事もほとんど出てこないので、残念ながら使えないのかも…。
もしうまく動いている、という方がいたら教えてください。