SlideShare une entreprise Scribd logo
1  sur  17
Télécharger pour lire hors ligne
Continuous integration
for
iOS projects
Aleksandra Gavrilovska
Netcetera
355
AGENDA

>  iOS App Distribution Process
>  Practices of Continuous Integration
>  Jenkins
   –  How to configure slave
   –  How to configure job
>  Build system at Netcetera
   –  Overview of rake tasks
   –  Benefits
   –  Improvements




                                         2
iOS App Distribution Process




                               3
Practices of Continuous Integration


>    Maintain a code repository
>    Automate the build
>    Make the build self-testing
>    Everyone commits to the baseline every day
>    Every commit (to baseline) should be built
>    Keep the build fast
>    Test in a clone of the production environment
>    Make it easy to get the latest deliverables
>    Everyone can see the results of the latest build
>    Automate deployment


                                                        4
overview

>    Open source continuous integration service provider
>    Runs in servlet container such as Apache Tomcat
>    iOS Projects MUST be build on Mac
>    Jenkins instances as slaves




                                                           5
Configuring Jenkins Mac Slave




                                6
Create New Job

>  Properties that must be set




                                 7
Custom build system


>  Implemented in Ruby
>  Rake wrapper around xcodebuild
   –  Rakefile
   –  Several Ruby scripts
   –  Included in our xCode project templates




                                                8
Rakefile

xcode_project :"___PROJECTNAME___" do!
  # The artifact_id is a alias for the main Xcode target!
  artifact_id           "___ARTIFACT_ID___”!
  project_id            "___PROJECT_ID___"!
  group_id              "___GROUP_ID___"!
  svn                   "___SVN___"!
!
  release_destination "http://buildfs.group.nca/dav/projects/___PROJECTNAME___/
release/"!
  snapshot_destination "http://buildfs.group.nca/dav/projects/___PROJECTNAME___/
snapshots/"!
!
  itunes_artwork "src/main/resources/iTunesArtwork”!
!
  adhoc_package "NetceteraAdhoc" do!
     identity "iPhone Distribution: Netcetera AG"!
     # by default the provisioning profile used will be src/packaging/
ADHOC_PACKAGE_NAME.mobileprovision!
     # you can override by using!
     # provisioning_profile "path to provisioning profile"!
  end!
end!

                                                                              9
Rake tasks
agavrilo-2:agavrilo$ rake –tasks!
rake build             # Invokes xcode build to compile the project!
rake ci                 # Invoked by the CI system!
rake clean              #   Cleans the project!
rake package            #   Creates the packages!
rake release            #   Performs a release!
rake release:rollback   #   [TBD]!
rake report             #   Reports to techISR.!
rake symbolicate        #   Symbolicates the crash report provided under the
   REPORT variable.!
rake test               # Invokes The tests!
rake uitest             # Run Cucumber features!
!
!
task "ci"     => "deliver-snapshot”!
task "deliver-snapshot" => "package” !
task "package" => ["appstore-package", "adhoc-packages"]!
!
!                                                                              10
Test execution

>  rake test!
>  GHUnit as testing framework
>  Jenkins can run GHUnit tests
     –    http://gabriel.github.com/gh-unit/docs/appledoc_include/guide_ci.html!
>    UnitTest target should Run Script
>    Tests are executed on Simulator
>    JUnit test result report is created (XML file)
>    Reports to internal reporting tool




                                                                                   11
Packaging


>    rake package!
>    ‘Release’ configuration must exist in project scheme!
>    Creates app store package
>    .dSYM file is stored
>    Creates adhoc packages by resigning the app store packages
     –  Decreases the build time
     –  App store and adhoc application are both identical!




                                                                  12
Deployment


>  rake delivery!
>  Deploys all artifacts to snapshot_destination!
   –  All provisioning profiles
   –  App store build
   –  .dSYM package
   –  *.ipa packages
>  Ready to be fetched for testing or submission in iTunes Connect




                                                                     13
Debugging: Symbolicate crash


 >  rake symbolicate REPORT=path_to_report!
    –  REPORT can be a path to directory
 >  Extract the uuid from the crash report
lines = File.readlines(report).map {|line| line.tr("rn", '')}!
!
line = lines[lines.index("Binary Images:") + 1]!
!
line.match(/armv[67] +<[0-9a-z]+>/)[0].split(' ').map {|entry| entry.tr("<>", '')}!

 >  find the appropriate (matching) build on the DAV server
 "No snapshot can be found that matches uuid: #{uuid}, for
    architecture: #{arch}”!
 >  download it
 >  unpack it
 >  symbolicate it
                                                                              14
Conclusion


>  Benefits
   –  Not dependent on xCode version
   –  Control of the build process
   –  Control of the project state
   –  Applications are always ready to be tested
   –  Debugging
   –  Scalable and configurable build system
       • build of workspace
       • Installation of pods



>  Improvements
   –  Installation of certificates in keychain
   –  Check for code duplicates
   –  Check style
                                                   15
Questions




            16
Aleksandra Gavrilovska
Netcetera


aleksandra.gavrilovska@netcetera.com

Contenu connexe

Tendances

Tendances (20)

Continuous Infrastructure: Modern Puppet for the Jenkins Project - PuppetConf...
Continuous Infrastructure: Modern Puppet for the Jenkins Project - PuppetConf...Continuous Infrastructure: Modern Puppet for the Jenkins Project - PuppetConf...
Continuous Infrastructure: Modern Puppet for the Jenkins Project - PuppetConf...
 
Deploy your app with one Slack command
Deploy your app with one Slack commandDeploy your app with one Slack command
Deploy your app with one Slack command
 
Vagrant to-aws-flow
Vagrant to-aws-flowVagrant to-aws-flow
Vagrant to-aws-flow
 
"I have a framework idea" - Repeat less, share more.
"I have a framework idea" - Repeat less, share more."I have a framework idea" - Repeat less, share more.
"I have a framework idea" - Repeat less, share more.
 
Deployment Patterns in the Ruby on Rails World
Deployment Patterns in the Ruby on Rails WorldDeployment Patterns in the Ruby on Rails World
Deployment Patterns in the Ruby on Rails World
 
Jenkins, pipeline and docker
Jenkins, pipeline and docker Jenkins, pipeline and docker
Jenkins, pipeline and docker
 
How to successfully migrate to Bazel from Maven or Gradle - Riga Dev Days
How to successfully migrate to Bazel from Maven or Gradle - Riga Dev DaysHow to successfully migrate to Bazel from Maven or Gradle - Riga Dev Days
How to successfully migrate to Bazel from Maven or Gradle - Riga Dev Days
 
Dockerize node.js application
Dockerize node.js applicationDockerize node.js application
Dockerize node.js application
 
Drupal 8 DevOps . Profile and SQL flows.
Drupal 8 DevOps . Profile and SQL flows.Drupal 8 DevOps . Profile and SQL flows.
Drupal 8 DevOps . Profile and SQL flows.
 
Ci system part i
Ci system part iCi system part i
Ci system part i
 
Drupal contrib module maintaining
Drupal contrib module maintainingDrupal contrib module maintaining
Drupal contrib module maintaining
 
Learning Maven by Example
Learning Maven by ExampleLearning Maven by Example
Learning Maven by Example
 
Jenkins CI presentation
Jenkins CI presentationJenkins CI presentation
Jenkins CI presentation
 
DrupalCon Los Angeles - Continuous Integration Toolbox
DrupalCon Los Angeles - Continuous Integration ToolboxDrupalCon Los Angeles - Continuous Integration Toolbox
DrupalCon Los Angeles - Continuous Integration Toolbox
 
Modern Infrastructure from Scratch with Puppet
Modern Infrastructure from Scratch with PuppetModern Infrastructure from Scratch with Puppet
Modern Infrastructure from Scratch with Puppet
 
Jenkins days workshop pipelines - Eric Long
Jenkins days workshop  pipelines - Eric LongJenkins days workshop  pipelines - Eric Long
Jenkins days workshop pipelines - Eric Long
 
Chef training Day5
Chef training Day5Chef training Day5
Chef training Day5
 
Configuration Management in a Containerized World
Configuration Management in a Containerized WorldConfiguration Management in a Containerized World
Configuration Management in a Containerized World
 
Docker and Puppet for Continuous Integration
Docker and Puppet for Continuous IntegrationDocker and Puppet for Continuous Integration
Docker and Puppet for Continuous Integration
 
Chef training - Day3
Chef training - Day3Chef training - Day3
Chef training - Day3
 

En vedette (7)

Presentación: Martín Olmi-Analoga_eCommerce Day Montevideo 2013
Presentación: Martín Olmi-Analoga_eCommerce Day Montevideo 2013Presentación: Martín Olmi-Analoga_eCommerce Day Montevideo 2013
Presentación: Martín Olmi-Analoga_eCommerce Day Montevideo 2013
 
Canterbury Software Summit 2013 - Chairman's opening remarks
Canterbury Software Summit 2013 - Chairman's opening remarksCanterbury Software Summit 2013 - Chairman's opening remarks
Canterbury Software Summit 2013 - Chairman's opening remarks
 
550week3 simon
550week3 simon550week3 simon
550week3 simon
 
Proven Steps To a New Habit
Proven Steps To a New HabitProven Steps To a New Habit
Proven Steps To a New Habit
 
Sociale media voor fotografen: 4 basics en 10 quickwins
Sociale media voor fotografen: 4 basics en 10 quickwinsSociale media voor fotografen: 4 basics en 10 quickwins
Sociale media voor fotografen: 4 basics en 10 quickwins
 
Troubled E Press Kit
Troubled E Press KitTroubled E Press Kit
Troubled E Press Kit
 
Ftl 103 tourette
 Ftl 103 tourette Ftl 103 tourette
Ftl 103 tourette
 

Similaire à Jazoon12 355 aleksandra_gavrilovska-1

Similaire à Jazoon12 355 aleksandra_gavrilovska-1 (20)

DCSF 19 Building Your Development Pipeline
DCSF 19 Building Your Development Pipeline  DCSF 19 Building Your Development Pipeline
DCSF 19 Building Your Development Pipeline
 
From development environments to production deployments with Docker, Compose,...
From development environments to production deployments with Docker, Compose,...From development environments to production deployments with Docker, Compose,...
From development environments to production deployments with Docker, Compose,...
 
Webinar: Creating an Effective Docker Build Pipeline for Java Apps
Webinar: Creating an Effective Docker Build Pipeline for Java AppsWebinar: Creating an Effective Docker Build Pipeline for Java Apps
Webinar: Creating an Effective Docker Build Pipeline for Java Apps
 
Scala, docker and testing, oh my! mario camou
Scala, docker and testing, oh my! mario camouScala, docker and testing, oh my! mario camou
Scala, docker and testing, oh my! mario camou
 
DevOps Workflow: A Tutorial on Linux Containers
DevOps Workflow: A Tutorial on Linux ContainersDevOps Workflow: A Tutorial on Linux Containers
DevOps Workflow: A Tutorial on Linux Containers
 
Containers 101
Containers 101Containers 101
Containers 101
 
[Codelab 2017] Docker 기초 및 활용 방안
[Codelab 2017] Docker 기초 및 활용 방안[Codelab 2017] Docker 기초 및 활용 방안
[Codelab 2017] Docker 기초 및 활용 방안
 
GDG-ANDROID-ATHENS Meetup: Build in Docker with Jenkins
GDG-ANDROID-ATHENS Meetup: Build in Docker with Jenkins GDG-ANDROID-ATHENS Meetup: Build in Docker with Jenkins
GDG-ANDROID-ATHENS Meetup: Build in Docker with Jenkins
 
Delivery Pipeline for Windows Machines
Delivery Pipeline for Windows MachinesDelivery Pipeline for Windows Machines
Delivery Pipeline for Windows Machines
 
DevOpsDaysRiga 2017: Dmitry Buzdin - Delivery Pipeline for Windows Machines
DevOpsDaysRiga 2017: Dmitry Buzdin - Delivery Pipeline for Windows MachinesDevOpsDaysRiga 2017: Dmitry Buzdin - Delivery Pipeline for Windows Machines
DevOpsDaysRiga 2017: Dmitry Buzdin - Delivery Pipeline for Windows Machines
 
Continuous Integration with Scratchbox And CruiseControl
Continuous Integration with Scratchbox And CruiseControlContinuous Integration with Scratchbox And CruiseControl
Continuous Integration with Scratchbox And CruiseControl
 
Excelian hyperledger walkthrough-feb17
Excelian hyperledger walkthrough-feb17Excelian hyperledger walkthrough-feb17
Excelian hyperledger walkthrough-feb17
 
Docker - Demo on PHP Application deployment
Docker - Demo on PHP Application deployment Docker - Demo on PHP Application deployment
Docker - Demo on PHP Application deployment
 
Lightning talk: 12 Factor Containers
Lightning talk: 12 Factor ContainersLightning talk: 12 Factor Containers
Lightning talk: 12 Factor Containers
 
Omaha (Google Update) server
Omaha (Google Update) serverOmaha (Google Update) server
Omaha (Google Update) server
 
(2018) Webpack Encore - Asset Management for the rest of us
(2018) Webpack Encore - Asset Management for the rest of us(2018) Webpack Encore - Asset Management for the rest of us
(2018) Webpack Encore - Asset Management for the rest of us
 
Play framework
Play frameworkPlay framework
Play framework
 
#3 Hanoi Magento Meetup - Part 2: Scalable Magento Development With Containers
#3 Hanoi Magento Meetup - Part 2: Scalable Magento Development With Containers#3 Hanoi Magento Meetup - Part 2: Scalable Magento Development With Containers
#3 Hanoi Magento Meetup - Part 2: Scalable Magento Development With Containers
 
Continuous Delivery with Docker and Amazon ECS
Continuous Delivery with Docker and Amazon ECSContinuous Delivery with Docker and Amazon ECS
Continuous Delivery with Docker and Amazon ECS
 
(ARC402) Deployment Automation: From Developers' Keyboards to End Users' Scre...
(ARC402) Deployment Automation: From Developers' Keyboards to End Users' Scre...(ARC402) Deployment Automation: From Developers' Keyboards to End Users' Scre...
(ARC402) Deployment Automation: From Developers' Keyboards to End Users' Scre...
 

Plus de Netcetera

Plus de Netcetera (20)

Payment trend scouting - Kurt Schmid, Netcetera
Payment trend scouting - Kurt Schmid, NetceteraPayment trend scouting - Kurt Schmid, Netcetera
Payment trend scouting - Kurt Schmid, Netcetera
 
Boost your approved transaction volume - Ana Vuksanovikj Vaneska, Netcetera
Boost your approved transaction volume - Ana Vuksanovikj Vaneska, NetceteraBoost your approved transaction volume - Ana Vuksanovikj Vaneska, Netcetera
Boost your approved transaction volume - Ana Vuksanovikj Vaneska, Netcetera
 
Increase conversion, convenience and security in e-commerce checkouts - Silke...
Increase conversion, convenience and security in e-commerce checkouts - Silke...Increase conversion, convenience and security in e-commerce checkouts - Silke...
Increase conversion, convenience and security in e-commerce checkouts - Silke...
 
3-D Secure 2.0 - Stephan Rüdisüli, Netcetera & Patrick Juffern, INFORM
3-D Secure 2.0 - Stephan Rüdisüli, Netcetera & Patrick Juffern, INFORM3-D Secure 2.0 - Stephan Rüdisüli, Netcetera & Patrick Juffern, INFORM
3-D Secure 2.0 - Stephan Rüdisüli, Netcetera & Patrick Juffern, INFORM
 
Digital Payment in 2020 - Kurt Schmid, Netcetera
Digital Payment in 2020 - Kurt Schmid, NetceteraDigital Payment in 2020 - Kurt Schmid, Netcetera
Digital Payment in 2020 - Kurt Schmid, Netcetera
 
AI First. Erfolgsfaktoren für künstliche Intelligenz im Unternehmen
AI First. Erfolgsfaktoren für künstliche Intelligenz im UnternehmenAI First. Erfolgsfaktoren für künstliche Intelligenz im Unternehmen
AI First. Erfolgsfaktoren für künstliche Intelligenz im Unternehmen
 
Augmenting Maintenance
Augmenting MaintenanceAugmenting Maintenance
Augmenting Maintenance
 
Front-end up front
Front-end up frontFront-end up front
Front-end up front
 
The future of Prototpying
The future of PrototpyingThe future of Prototpying
The future of Prototpying
 
EMV Secure Remote Commerce (SRC)
EMV Secure Remote Commerce (SRC)EMV Secure Remote Commerce (SRC)
EMV Secure Remote Commerce (SRC)
 
Online shopping technology in the fast lane?
Online shopping technology in the fast lane?Online shopping technology in the fast lane?
Online shopping technology in the fast lane?
 
Merchant tokenization and EMV® Secure Remote Commerce
Merchant tokenization and EMV® Secure Remote CommerceMerchant tokenization and EMV® Secure Remote Commerce
Merchant tokenization and EMV® Secure Remote Commerce
 
Seamless 3-D Secure e-commerce experience
Seamless 3-D Secure e-commerce experienceSeamless 3-D Secure e-commerce experience
Seamless 3-D Secure e-commerce experience
 
Augmenting Health Care
Augmenting Health CareAugmenting Health Care
Augmenting Health Care
 
Driving transactional growth with 3-D Secure
Driving transactional growth with 3-D SecureDriving transactional growth with 3-D Secure
Driving transactional growth with 3-D Secure
 
Digital Payment Quo Vadis
Digital Payment Quo VadisDigital Payment Quo Vadis
Digital Payment Quo Vadis
 
EMV® Secure Remote Commerce
EMV® Secure Remote CommerceEMV® Secure Remote Commerce
EMV® Secure Remote Commerce
 
Context: The missing ingredient in multilingual software translation
Context: The missing ingredient in multilingual software translationContext: The missing ingredient in multilingual software translation
Context: The missing ingredient in multilingual software translation
 
Digital Payments - Netcetera Innovation Summit 2018
Digital Payments - Netcetera Innovation Summit 2018Digital Payments - Netcetera Innovation Summit 2018
Digital Payments - Netcetera Innovation Summit 2018
 
"Whats up and new at Netcetera?" - Netcetera Innovation Summit 2018
"Whats up and new at Netcetera?" - Netcetera Innovation Summit 2018"Whats up and new at Netcetera?" - Netcetera Innovation Summit 2018
"Whats up and new at Netcetera?" - Netcetera Innovation Summit 2018
 

Dernier

Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
panagenda
 

Dernier (20)

Portal Kombat : extension du réseau de propagande russe
Portal Kombat : extension du réseau de propagande russePortal Kombat : extension du réseau de propagande russe
Portal Kombat : extension du réseau de propagande russe
 
ADP Passwordless Journey Case Study.pptx
ADP Passwordless Journey Case Study.pptxADP Passwordless Journey Case Study.pptx
ADP Passwordless Journey Case Study.pptx
 
How we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdfHow we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdf
 
Collecting & Temporal Analysis of Behavioral Web Data - Tales From The Inside
Collecting & Temporal Analysis of Behavioral Web Data - Tales From The InsideCollecting & Temporal Analysis of Behavioral Web Data - Tales From The Inside
Collecting & Temporal Analysis of Behavioral Web Data - Tales From The Inside
 
Using IESVE for Room Loads Analysis - UK & Ireland
Using IESVE for Room Loads Analysis - UK & IrelandUsing IESVE for Room Loads Analysis - UK & Ireland
Using IESVE for Room Loads Analysis - UK & Ireland
 
ERP Contender Series: Acumatica vs. Sage Intacct
ERP Contender Series: Acumatica vs. Sage IntacctERP Contender Series: Acumatica vs. Sage Intacct
ERP Contender Series: Acumatica vs. Sage Intacct
 
UiPath manufacturing technology benefits and AI overview
UiPath manufacturing technology benefits and AI overviewUiPath manufacturing technology benefits and AI overview
UiPath manufacturing technology benefits and AI overview
 
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdfHow Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
 
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
 
The Metaverse: Are We There Yet?
The  Metaverse:    Are   We  There  Yet?The  Metaverse:    Are   We  There  Yet?
The Metaverse: Are We There Yet?
 
Event-Driven Architecture Masterclass: Challenges in Stream Processing
Event-Driven Architecture Masterclass: Challenges in Stream ProcessingEvent-Driven Architecture Masterclass: Challenges in Stream Processing
Event-Driven Architecture Masterclass: Challenges in Stream Processing
 
Continuing Bonds Through AI: A Hermeneutic Reflection on Thanabots
Continuing Bonds Through AI: A Hermeneutic Reflection on ThanabotsContinuing Bonds Through AI: A Hermeneutic Reflection on Thanabots
Continuing Bonds Through AI: A Hermeneutic Reflection on Thanabots
 
Generative AI Use Cases and Applications.pdf
Generative AI Use Cases and Applications.pdfGenerative AI Use Cases and Applications.pdf
Generative AI Use Cases and Applications.pdf
 
Google I/O Extended 2024 Warsaw
Google I/O Extended 2024 WarsawGoogle I/O Extended 2024 Warsaw
Google I/O Extended 2024 Warsaw
 
Vector Search @ sw2con for slideshare.pptx
Vector Search @ sw2con for slideshare.pptxVector Search @ sw2con for slideshare.pptx
Vector Search @ sw2con for slideshare.pptx
 
WebAssembly is Key to Better LLM Performance
WebAssembly is Key to Better LLM PerformanceWebAssembly is Key to Better LLM Performance
WebAssembly is Key to Better LLM Performance
 
State of the Smart Building Startup Landscape 2024!
State of the Smart Building Startup Landscape 2024!State of the Smart Building Startup Landscape 2024!
State of the Smart Building Startup Landscape 2024!
 
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdfLinux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
 
Simplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdf
Simplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdfSimplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdf
Simplified FDO Manufacturing Flow with TPMs _ Liam at Infineon.pdf
 
Secure Zero Touch enabled Edge compute with Dell NativeEdge via FDO _ Brad at...
Secure Zero Touch enabled Edge compute with Dell NativeEdge via FDO _ Brad at...Secure Zero Touch enabled Edge compute with Dell NativeEdge via FDO _ Brad at...
Secure Zero Touch enabled Edge compute with Dell NativeEdge via FDO _ Brad at...
 

Jazoon12 355 aleksandra_gavrilovska-1

  • 2. AGENDA >  iOS App Distribution Process >  Practices of Continuous Integration >  Jenkins –  How to configure slave –  How to configure job >  Build system at Netcetera –  Overview of rake tasks –  Benefits –  Improvements 2
  • 4. Practices of Continuous Integration >  Maintain a code repository >  Automate the build >  Make the build self-testing >  Everyone commits to the baseline every day >  Every commit (to baseline) should be built >  Keep the build fast >  Test in a clone of the production environment >  Make it easy to get the latest deliverables >  Everyone can see the results of the latest build >  Automate deployment 4
  • 5. overview >  Open source continuous integration service provider >  Runs in servlet container such as Apache Tomcat >  iOS Projects MUST be build on Mac >  Jenkins instances as slaves 5
  • 7. Create New Job >  Properties that must be set 7
  • 8. Custom build system >  Implemented in Ruby >  Rake wrapper around xcodebuild –  Rakefile –  Several Ruby scripts –  Included in our xCode project templates 8
  • 9. Rakefile xcode_project :"___PROJECTNAME___" do! # The artifact_id is a alias for the main Xcode target! artifact_id "___ARTIFACT_ID___”! project_id "___PROJECT_ID___"! group_id "___GROUP_ID___"! svn "___SVN___"! ! release_destination "http://buildfs.group.nca/dav/projects/___PROJECTNAME___/ release/"! snapshot_destination "http://buildfs.group.nca/dav/projects/___PROJECTNAME___/ snapshots/"! ! itunes_artwork "src/main/resources/iTunesArtwork”! ! adhoc_package "NetceteraAdhoc" do! identity "iPhone Distribution: Netcetera AG"! # by default the provisioning profile used will be src/packaging/ ADHOC_PACKAGE_NAME.mobileprovision! # you can override by using! # provisioning_profile "path to provisioning profile"! end! end! 9
  • 10. Rake tasks agavrilo-2:agavrilo$ rake –tasks! rake build # Invokes xcode build to compile the project! rake ci # Invoked by the CI system! rake clean # Cleans the project! rake package # Creates the packages! rake release # Performs a release! rake release:rollback # [TBD]! rake report # Reports to techISR.! rake symbolicate # Symbolicates the crash report provided under the REPORT variable.! rake test # Invokes The tests! rake uitest # Run Cucumber features! ! ! task "ci" => "deliver-snapshot”! task "deliver-snapshot" => "package” ! task "package" => ["appstore-package", "adhoc-packages"]! ! ! 10
  • 11. Test execution >  rake test! >  GHUnit as testing framework >  Jenkins can run GHUnit tests –  http://gabriel.github.com/gh-unit/docs/appledoc_include/guide_ci.html! >  UnitTest target should Run Script >  Tests are executed on Simulator >  JUnit test result report is created (XML file) >  Reports to internal reporting tool 11
  • 12. Packaging >  rake package! >  ‘Release’ configuration must exist in project scheme! >  Creates app store package >  .dSYM file is stored >  Creates adhoc packages by resigning the app store packages –  Decreases the build time –  App store and adhoc application are both identical! 12
  • 13. Deployment >  rake delivery! >  Deploys all artifacts to snapshot_destination! –  All provisioning profiles –  App store build –  .dSYM package –  *.ipa packages >  Ready to be fetched for testing or submission in iTunes Connect 13
  • 14. Debugging: Symbolicate crash >  rake symbolicate REPORT=path_to_report! –  REPORT can be a path to directory >  Extract the uuid from the crash report lines = File.readlines(report).map {|line| line.tr("rn", '')}! ! line = lines[lines.index("Binary Images:") + 1]! ! line.match(/armv[67] +<[0-9a-z]+>/)[0].split(' ').map {|entry| entry.tr("<>", '')}! >  find the appropriate (matching) build on the DAV server "No snapshot can be found that matches uuid: #{uuid}, for architecture: #{arch}”! >  download it >  unpack it >  symbolicate it 14
  • 15. Conclusion >  Benefits –  Not dependent on xCode version –  Control of the build process –  Control of the project state –  Applications are always ready to be tested –  Debugging –  Scalable and configurable build system • build of workspace • Installation of pods >  Improvements –  Installation of certificates in keychain –  Check for code duplicates –  Check style 15
  • 16. Questions 16