$30 off During Our Annual Pro Sale. View Details »

Xcode Cloudの評価

Xcode Cloudの評価

Kishikawa Katsumi

September 29, 2022
Tweet

More Decks by Kishikawa Katsumi

Other Decks in Programming

Transcript

  1. Kishikawa Katsumi Xcode CloudͷධՁ

  2. Xcode CloudͷධՁ • Conclusion • Pros / Cons • Workaround

    • Summary
  3. Xcode Cloud at a glance https://speakerdeck.com/kishikawakatsumi/xcode-cloud-at-a-glance

  4. Xcode CloudͷධՁ Summary • iOS/watchOS/tvOS/macOSΞϓϦΛTestFlight΍App StoreʹΞοϓϩʔυ ͢Δ͜ͱ͸ؔͯ͠͸࠷ߴͷπʔϧ • ͦΕҎ֎ͷλεΫɺ൚༻తͳCIͱͯ͠ߟ͑ΔͱྉۚΛߟྀͯ͠΋ଞͷαʔϏε ʹେ͖͘ݟྼΓ͢Δ

  5. None
  6. None
  7. Xcode CloudͷධՁ Pros • iOS/watchOS/tvOS/macOSΞϓϦΛTestFlight΍App StoreʹΞοϓϩʔυ͢Δ͜ͱ͕ඇ ৗʹ؆୯ • Distributionͷίʔυॺ໊ʹ·ͭΘΔ͞·͟·ͳτϥϒϧ͔Βղ์͞ΕΔ •

    ྉ͕ۚखࠒʢଥ౰Ͱ͋Δͱ͸ݴͬͯͳ͍ʣ • ΞΫγϣϯ͸͢΂ͯฒྻʹ࣮ߦ͞ΕΔ • ৽͍͠XcodeͱOSͷରԠ͕Ұ൪ૣ͍ • UI Test͕͋ΔͱεΫϦʔϯγϣοτ͕ࣗಈతʹ࢒ΓɺXcode΍Web͔Β݁ՌΛ֬ೝͰ͖Δ
  8. Xcode CloudͷධՁ Cons • ൚༻తͳCIαʔϏεͱͯ͠͞·͟·ͳλεΫΛ࣮ߦͤ͞Δ͜ͱ͸೉͍͠ • αʔυύʔςΟ੡ͷϏϧυπʔϧ͕ Pre-Install͞Ε͍ͯͳ͍ • HomebrewͷΈ

    • CocoaPods΍Carthage͕ඞཁͳ৔߹͸HomebrewͰΠϯετʔϧ͢Δ • Ruby͸ೖ͍ͬͯΔ͕ݹ͍ ruby 2.6.8p205 (2021-07-07 revision 67951) •࣮ߦͰ͖ΔΞΫγϣϯ͕طఆͷ΋ͷʹݶΒΕ͍ͯΔ
  9. Xcode CloudͷධՁ Cons • ΧελϜεΫϦϓτͷॊೈੑ͕௿͍ • ηοτΞοϓʹXcode͕ඞཁ • ϫʔΫϑϩʔΛϦϙδτϦͰ؅ཧͰ͖ͳ͍ •

    App Store Connect APIΛ࢖ͬͯ಺༰Λμ΢ϯϩʔυ͢ΔͳͲ޻෉͢Δ • ̍ਓͰ࢖͏෼ʹ͸ྑ͍͕νʔϜͰ࢖͍ʹ͍͘ • M1Ϛγϯ͸ʢ͓ͦΒ͘ʣ·ͩ࢖͑ͳ͍
  10. Xcode CloudͷධՁ Ұ೥લ͔ΒมΘͬͨ఺ • εέδϡʔϧ࣮ߦ͕Մೳʹͳͬͨ

  11. Xcode CloudͷධՁ εέδϡʔϧ࣮ߦ͕Մೳʹͳͬͨ

  12. Xcode CloudͷධՁ εέδϡʔϧ࣮ߦ͕Մೳʹͳͬͨ

  13. ৽͍͠XcodeͱOSͷରԠ͕Ұ൪ૣ͍

  14. Pros ৽͍͠XcodeͱOSͷରԠ͕Ұ൪ૣ͍

  15. Pros ৽͍͠XcodeͱOSͷରԠ͕Ұ൪ૣ͍

  16. OSͱXcodeόʔδϣϯͷରԠ Bitrise

  17. OSͱXcodeόʔδϣϯͷରԠ Codemagic

  18. ൚༻తͳCIαʔϏεͱͯ͠࢖͍ʹ͍͘

  19. ൚༻తͳCIαʔϏεͱͯ͠࢖͍ʹ͍͘ ࣮ߦͰ͖ΔΞΫγϣϯ͕طఆͷ΋ͷʹݶΒΕ͍ͯΔ

  20. ൚༻తͳCIαʔϏεͱͯ͠࢖͍ʹ͍͘ ࣮ߦͰ͖ΔΞΫγϣϯ͕طఆͷ΋ͷʹݶΒΕ͍ͯΔ

  21. ൚༻తͳCIαʔϏεͱͯ͠࢖͍ʹ͍͘ αʔυύʔςΟ੡ͷϏϧυπʔϧ͕ Pre-Install͞Ε͍ͯͳ͍ https://developer.apple.com/documentation/xcode/making-dependencies-available-to-xcode-cloud

  22. ൚༻తͳCIαʔϏεͱͯ͠࢖͍ʹ͍͘ αʔυύʔςΟ੡ͷϏϧυπʔϧ͕ Pre-Install͞Ε͍ͯͳ͍ https://developer.apple.com/documentation/xcode/making-dependencies-available-to-xcode-cloud

  23. ൚༻తͳCIαʔϏεͱͯ͠࢖͍ʹ͍͘ αʔυύʔςΟ੡ͷϏϧυπʔϧ͕ Pre-Install͞Ε͍ͯͳ͍ https://developer.apple.com/documentation/xcode/making-dependencies-available-to-xcode-cloud

  24. None
  25. ൚༻తͳCIαʔϏεͱͯ͠࢖͍ʹ͍͘ ΧελϜεΫϦϓτͷॊೈੑ͕௿͍

  26. • ϦϙδτϦͷci_scriptsσΟϨΫτϦʹci_post_clone.shɺ ci_pre_xcodebuild.shɺci_post_xcodebuild.shͷ໊લͰεΫϦϓτ Λ֨ೲ͢Δ • ϦϙδτϦ͝ͱʹ֤λΠϛϯάͷεΫϦϓτΛ͔̍ͭͣͭ͠ஔ͚ͳ͍ • ෳ਺ͷΞΫγϣϯ·ͨ͸ϫʔΫϑϩʔͰҟͳΔॲཧΛ͢Δʹ͸εΫϦϓτத Ͱ෼ذ͢Δඞཁ͕͋Δ ൚༻తͳCIαʔϏεͱͯ͠࢖͍ʹ͍͘

    ΧελϜεΫϦϓτͷॊೈੑ͕௿͍
  27. ൚༻తͳCIαʔϏεͱͯ͠࢖͍ʹ͍͘ ΧελϜεΫϦϓτͷॊೈੑ͕௿͍ https://developer.apple.com/documentation/xcode/writing-custom-build-scripts

  28. ηοτΞοϓʹXcode͕ඞཁ

  29. ηοτΞοϓʹXcode͕ඞཁ

  30. ηοτΞοϓʹXcode͕ඞཁ Ұ౓ηοτΞοϓ͕׬ྃ͢Ε͹Web͔Βಉ༷ʹӾཡɾฤूͰ͖Δ

  31. ηοτΞοϓʹXcode͕ඞཁ ϑϨʔϜϫʔΫͷ৔߹μΠϨΫτΞΫηεҎ֎ʹWebͰΈΔखஈ͕ͳ͍

  32. ϫʔΫϑϩʔΛϦϙδτϦͰ؅ཧͰ͖ͳ͍

  33. ϫʔΫϑϩʔΛϦϙδτϦͰ؅ཧͰ͖ͳ͍ App Store Connect APIͰऔಘ͢Δ͜ͱ͸Ͱ͖Δ

  34. ʢ༨ஊʣϫʔΫϑϩʔΛAPIͰ࡞Δ͜ͱ͸Մೳ طଘͷηοτΞοϓͷ৘ใ͕ඞཁͳͷͰ࠷ॳͷηοτΞοϓ͸Ͱ͖ͳ͍ʢ௥ՃͷΈʣ

  35. M1Ϛγϯ͸·ͩ࢖͑ͳ͍

  36. M1Ϛγϯ͸·ͩ࢖͑ͳ͍ +/Volumes/workspace/repository/ci_scripts/ci_post_clone.sh:5> uname -m x86_64 +/Volumes/workspace/repository/ci_scripts/ci_post_clone.sh:6> system_profiler \ SPSoftwareDataType \

    SPHardwareDataType Software: System Software Overview: System Version: macOS 12.6 (21G115) Kernel Version: Darwin 21.6.0 Boot Volume: Macintosh HD Boot Mode: Normal Computer Name: 65f75d2b-8366-4cb2-8ab6-6172469216e8-765df7c9b-6xhrf-vm User Name: local (local) Secure Virtual Memory: Enabled System Integrity Protection: Enabled Time since boot: 46 minutes
  37. M1Ϛγϯ͸·ͩ࢖͑ͳ͍ Hardware: Hardware Overview: Model Name: Mac Model Identifier: MacVM1,1

    Processor Name: Unknown Processor Speed: 2 GHz Number of Processors: 4 Total Number of Cores: 4 L2 Cache (per Processor): 4 MB L3 Cache (per Processor): 16 MB Memory: 16 GB System Firmware Version: AVM11.88Z.0003.D00.2110230656 OS Loader Version: 540.120.3~22 SMC Version (system): 1.13f3 Serial Number (system): XCC34RG97D9B Hardware UUID: 42774E5C-1EBC-4D12-BD7F-DA2BF93D7A53 Provisioning UDID: 42774E5C-1EBC-4D12-BD7F-DA2BF93D7A53
  38. None
  39. Xcode CloudͷධՁ Summary • iOS/watchOS/tvOS/macOSΞϓϦΛTestFlight΍App StoreʹΞοϓϩʔυ͢Δ͜ͱ͕ඇৗʹ؆୯ • Distributionͷίʔυॺ໊ʹ·ͭΘΔ͞·͟·ͳτϥϒϧ͔Βղ์͞ΕΔ • SwiftPMҎ֎ͷύοέʔδϚωʔδϟΛ࢖͍ͬͯΔ৔߹͸޻෉͕ඞཁ

    • Ϗϧυͷ௚લ·ͰผͷCIαʔϏεͰ࣮ߦͯ͠ɺ͢΂ͯͷϑΝΠϧΛಛఆͷϒϥϯνʹίϛοτͯ͠Xcode CloudΛτϦΨʔ͢Δͷ͕γϯϓϧ • ഑෍Ҏ֎ͷ໨తʹ࢖༻͢Δʹ͸͔ͳΓ࢖͍ʹ͍͘ • ଞਓɾෳ਺ͷApp Store ConnectΞΧ΢ϯτʹ഑෍͢Δ͜ͱ͸೉͍͠ʢΫϥΠΞϯτϫʔΫͳͲʣ • ཁ͸Ϋϥ΢υίʔυॺ໊͚͕ͩXcode Buildͷ།ҰͰ࠷େͷར఺ͳͷͰͦΕҎ֎ͷ͜ͱ͸ଞͷCIαʔϏεΛ࢖͏ ͱ͏·͍͘͘