Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Level Up Your Game With TravisCI: From Zero To Hero In 45 Minutes

Level Up Your Game With TravisCI: From Zero To Hero In 45 Minutes

TravisCI, Xcode Bots, Fastlane, TestFlight, HockeyApp are only a few of the many tools that are available and highly used to optimize workflows and improve your product. But where do you start? "Level Up Your Game With TravisCI: From Zero To Hero In 45 Minutes" helps you jump start into CI with your iOS projects. No matter if you have never heard about CI before or if you only want to refine your tools.

Florian Harr

October 21, 2016
Tweet

More Decks by Florian Harr

Other Decks in Programming

Transcript

  1. LEVEL UP YOUR GAME WITH TRAVISCI: FROM ZERO TO HERO

    IN 45 MINUTES By: Florian Harr @caffeineflo iOS Engineer stablekernel.com
  2. Hi, I’m [Florian Harr]. • 10/2011 - 10/2014 Bachelors Degree

    in Computer Science, Stuttgart Germany • 10/2014 - 01/2016 iOS Software Engineer @ Big Nerd Ranch, Atlanta, GA • 01/2016 - Today iOS Software Engineer @ Stable|Kernel, Atlanta, GA
  3. We’re stable|kernel. stable|kernel is an Atlanta-based mobile development company 


    to craft smartly-designed mobile applications that connect brands 
 directly with their users. 
 
 Our team of engineers and designers takes clients from 
 strategy through design, development and deployment, 
 ensuring timely delivery of the highest quality applications.
  4. @stablekernel Extreme programming (XP) is a software development methodology which

    is intended to improve software quality and responsiveness to changing customer requirements. As a type of agile software development, it advocates frequent "releases" in short development cycles, which is intended to improve productivity and introduce checkpoints at which new customer requirements can be adopted.
  5. @stablekernel \kən-ˈtin-yü-əs\ \ˌin-tə-ˈgrā-shən\ Continuous Integration Continuous Integration (CI) is a

    development practice that requires developers to integrate code into a shared repository several times a day. • Each check-in is then verified by an automated build, allowing teams to detect problems early. adjective noun
  6. @stablekernel \kən-ˈtin-yü-əs\ \ˌin-tə-ˈgrā-shən\ Continuous Integration Continuous Integration (CI) is a

    development practice that requires developers to integrate code into a shared repository several times a day. • Each check-in is then verified by an automated build, allowing teams to detect problems early. adjective noun
  7. @stablekernel Continuous Integration (CI) is a development practice that requires

    developers to integrate code into a shared repository several times a day. Each check-in is then verified by an automated build allowing teams to detect problems early.
  8. @stablekernel Xcode Versions: • 6.1 • 6.2 • 6.3 •

    6.4 • 7 • 7.1 • 7.2 • 7.3.1 • 8 Simulator: • iPhone 4s - 7 Plus • Apple Watch 38 + 42 mm • Apple TV 1080p SDK: • 7.0 • 7.1 • 8.1 • 8.2 • 8.3 • 8.4 • 9 • 9.1 • 9.2 • 9.3 • 10 • watchOS 2 • watchOS 2.1 • watchOS 2.2 • watchOS 3 • tvOS 9.0 • tvOS 9.1 • tvOS 9.2 • tvOS 10.0
  9. @stablekernel Configured through .travis.yml file before_install: install: before_script: script: after_success:

    (after_failure:) (before_deploy:) (deploy:) (after_deploy:) (after_script:) .travis.yml language:
  10. @stablekernel Configured through .travis.yml file before_install: install: before_script: script: after_success:

    (after_failure:) (before_deploy:) (deploy:) (after_deploy:) (after_script:) You can do everything that you can do in your Terminal(.app)…. .travis.yml language:
  11. @stablekernel Configured through .travis.yml file You can do everything that

    you can do in your Terminal(.app)… …. which is pretty much everything* *exclusions and smaller limitations reserved .travis.yml language: show live demo after this?! Maybe live demo could show app and right afterwards integration results including snapshots before_install: install: before_script: script: after_success: (after_failure:) (before_deploy:) (deploy:) (after_deploy:) (after_script:)
  12. @stablekernel Florians-MacBookPro:FizzBuzz evils$ fastlane init [23:20:03]: Detected iOS/Mac project in

    current directory... [23:20:03]: This setup will help you get up and running in no time. [23:20:03]: fastlane will check what tools you're already using and set up [23:20:03]: the tool automatically for you. Have fun! [23:20:03]: Created new folder './fastlane'. [23:20:03]: $ xcodebuild clean -showBuildSettings -project ./FizzBuzz.xcodeproj Your Apple ID (e.g. [email protected]): [email protected] [23:20:08]: Verifying if app is available on the Apple Developer Portal and iTunes Connect... [23:20:08]: Starting login with user '[email protected]' Multiple teams found on the Developer Portal, please enter the number of the team you want to use: 1) Z6QSU67DFL "FeMoSo Systems GmbH" (Company/Organization) 2) DR3HWS5LMB "Florian Harr" (Individual) 3) CM487E42JY "Rheem Manufacturing Company" (Company/Organization) 4) R9AR4U6NWF "Stable Kernel, LLC" (Company/Organization) 2 +----------------+-------------------------------------------------------+ | Detected Values | +----------------+-------------------------------------------------------+ | Apple ID | [email protected] | | App Name | FizzBuzz | | App Identifier | com.iFlorian.FizzBuzz | | Project | /Users/evils/Repositories/FizzBuzz/FizzBuzz.xcodeproj | +----------------+-------------------------------------------------------+ [23:20:12]: This app identifier doesn't exist on iTunes Connect yet, it will be created for you [23:20:12]: This app identifier doesn't exist on the Apple Developer Portal yet, it will be created for you Please confirm the above values (y/n) y [23:20:22]: Created new file './fastlane/Appfile'. Edit it to manage your preferred app metadata information. [23:20:22]: Creating the app on iTunes Connect and the Apple Developer Portal [23:20:22]: $ xcodebuild clean -showBuildSettings -project ./FizzBuzz.xcodeproj 23:21:24]: Successfully finished setting up fastlane
  13. @stablekernel Florians-MacBookPro:FizzBuzz evils$ fastlane init [23:20:03]: Detected iOS/Mac project in

    current directory... [23:20:03]: This setup will help you get up and running in no time. [23:20:03]: fastlane will check what tools you're already using and set up [23:20:03]: the tool automatically for you. Have fun! [23:20:03]: Created new folder './fastlane'. [23:20:03]: $ xcodebuild clean -showBuildSettings - project ./FizzBuzz.xcodeproj Your Apple ID (e.g. [email protected]): [email protected] [23:20:08]: Verifying if app is available on the Apple Developer Portal and iTunes Connect...
  14. @stablekernel Florians-MacBookPro:FizzBuzz evils$ fastlane init [23:20:03]: Detected iOS/Mac project in

    current directory... [23:20:03]: This setup will help you get up and running in no time. [23:20:03]: fastlane will check what tools you're already using and set up [23:20:03]: the tool automatically for you. Have fun! [23:20:03]: Created new folder './fastlane'. [23:20:03]: $ xcodebuild clean -showBuildSettings - project ./FizzBuzz.xcodeproj Your Apple ID (e.g. [email protected]): [email protected] [23:20:08]: Verifying if app is available on the Apple Developer Portal and iTunes Connect...
  15. @stablekernel Florians-MacBookPro:FizzBuzz evils$ fastlane init [23:20:03]: Detected iOS/Mac project in

    current directory... [23:20:03]: This setup will help you get up and running in no time. [23:20:03]: fastlane will check what tools you're already using and set up [23:20:03]: the tool automatically for you. Have fun! [23:20:03]: Created new folder './fastlane'. [23:20:03]: $ xcodebuild clean -showBuildSettings - project ./FizzBuzz.xcodeproj Your Apple ID (e.g. [email protected]): [email protected] [23:20:08]: Verifying if app is available on the Apple Developer Portal and iTunes Connect...
  16. @stablekernel Florians-MacBookPro:FizzBuzz evils$ fastlane init [23:20:03]: Detected iOS/Mac project in

    current directory... [23:20:03]: This setup will help you get up and running in no time. [23:20:03]: fastlane will check what tools you're already using and set up [23:20:03]: the tool automatically for you. Have fun! [23:20:03]: Created new folder './fastlane'. [23:20:03]: $ xcodebuild clean -showBuildSettings - project ./FizzBuzz.xcodeproj Your Apple ID (e.g. [email protected]): [email protected] [23:20:08]: Verifying if app is available on the Apple Developer Portal and iTunes Connect...
  17. @stablekernel Florians-MacBookPro:FizzBuzz evils$ fastlane init [23:20:03]: Detected iOS/Mac project in

    current directory... [23:20:03]: This setup will help you get up and running in no time. [23:20:03]: fastlane will check what tools you're already using and set up [23:20:03]: the tool automatically for you. Have fun! [23:20:03]: Created new folder './fastlane'. [23:20:03]: $ xcodebuild clean -showBuildSettings - project ./FizzBuzz.xcodeproj Your Apple ID (e.g. [email protected]): [email protected] [23:20:08]: Verifying if app is available on the Apple Developer Portal and iTunes Connect...
  18. @stablekernel Florians-MacBookPro:FizzBuzz evils$ fastlane init [23:20:03]: Detected iOS/Mac project in

    current directory... [23:20:03]: This setup will help you get up and running in no time. [23:20:03]: fastlane will check what tools you're already using and set up [23:20:03]: the tool automatically for you. Have fun! [23:20:03]: Created new folder './fastlane'. [23:20:03]: $ xcodebuild clean -showBuildSettings - project ./FizzBuzz.xcodeproj Your Apple ID (e.g. [email protected]): [email protected] [23:20:08]: Verifying if app is available on the Apple Developer Portal and iTunes Connect...
  19. @stablekernel Sometimes builds fail …. Search the logs SSH into

    the VM https://gist.github.com/jedi4ever/7677d62f1414c28a1a8c
  20. @stablekernel Sometimes builds fail …. Search the logs SSH into

    the VM https://gist.github.com/jedi4ever/ Replicate your VM Environment
  21. @stablekernel Sometimes builds fail …. Search the logs SSH into

    the VM https://gist.github.com/jedi4ever/ Replicate your VM Environment
  22. @stablekernel Sometimes builds fail …. Search the logs SSH into

    the VM https://gist.github.com/jedi4ever/ Replicate your VM Environment
  23. @stablekernel Extensions of CI Fabric Lint UI Testing Code Coverage

    coveralls.io Snapshots AppStore Submission Beta Builds Changelogs PivotalTracker Watermarks Matrix Builds
  24. @stablekernel Extensions of CI Fabric Lint UI Testing Code Coverage

    coveralls.io Snapshots AppStore Submission Beta Builds Changelogs PivotalTracker Watermarks Matrix Builds
  25. @stablekernel Extensions of CI Fabric Lint UI Testing Code Coverage

    codecov.io Snapshots AppStore Submission Beta Builds Changelogs PivotalTracker Watermarks Matrix Builds
  26. @stablekernel Extensions of CI Fabric Lint UI Testing Code Coverage

    codecov.io Snapshots AppStore Submission Beta Builds Changelogs PivotalTracker Watermarks Matrix Builds
  27. @stablekernel Extensions of CI Fabric Lint UI Testing Code Coverage

    Snapshots AppStore Submission Beta Builds Changelogs PivotalTracker Watermarks Matrix Builds codecov.io
  28. @stablekernel Extensions of CI Fabric Lint UI Testing Code Coverage

    Snapshots AppStore Submission Beta Builds Changelogs PivotalTracker Watermarks Matrix Builds codecov.io
  29. @stablekernel Extensions of CI Fabric Lint UI Testing Code Coverage

    Snapshots AppStore Submission Beta Builds Changelogs PivotalTracker Watermarks Matrix Builds codecov.io
  30. @stablekernel Extensions of CI Fabric Lint UI Testing Code Coverage

    Snapshots AppStore Submission Beta Builds Changelogs PivotalTracker Watermarks Matrix Builds codecov.io
  31. @stablekernel Extensions of CI Fabric Lint UI Testing Code Coverage

    Snapshots AppStore Submission Beta Builds Changelogs PivotalTracker Matrix Builds Watermarks codecov.io
  32. @stablekernel Extensions of CI Fabric Lint UI Testing Code Coverage

    Snapshots AppStore Submission Beta Builds Changelogs PivotalTracker Matrix Builds Watermarks codecov.io
  33. @stablekernel Extensions of CI Examples: • https://github.com/fastlane/examples • https://github.com/AFNetworking/AFNetworking •

    https://github.com/danielgindi/Charts Fabric Lint UI Testing Code Coverage codecov.io Snapshots AppStore Submission Beta Builds Changelogs PivotalTracker Watermarks Matrix Builds
  34. @stablekernel • Similar to a managed full stack Travis CI

    Setup • Includes TestFlight like beta environment • Compatible with: • BitBucket • GitHub • GitLab Other CI Solutions
  35. @stablekernel • Continuous Integration + Deployment Platform • Configuration through

    circle.yml • Integrates with: • GitHub • Bitbucket • GitHub Enterprise Other CI Solutions
  36. @stablekernel Xcode Server: • Self Hosted • Has been problematic

    in the past • Integration with GitHub problematic Other CI Solutions
  37. @stablekernel • Self Hosted • Not always up to date

    • Relying on single open source project?! Other CI Solutions
  38. @stablekernel Conclusion Why do we do all of this? •

    Avoid last minute emergencies early on • Ability to ship at any point • Regularly run tests • Save hours and hours of your time through automation https://github.com/evils/FizzBuzz Find Examples and more at ….