Save 37% off PRO during our Black Friday Sale! »

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.

Fe1782174fa3f0a2d07011df414a1267?s=128

Florian Harr

October 21, 2016
Tweet

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].

  3. 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
  4. 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.
  5. @stablekernel

  6. @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.
  7. @stablekernel \kən-ˈtin-yü-əs\ \ˌin-tə-ˈgrā-shən\ Continuous Integration

  8. @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
  9. @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
  10. @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.
  11. Commit Code Let CI do it’s thing ?? Profit

  12. @stablekernel

  13. @stablekernel

  14. @stablekernel git commit git push service hook issues build(s) runs

    build(s) notifies CI Layer Git Layer
  15. @stablekernel

  16. @stablekernel

  17. @stablekernel Free for public GitHub repositories Paid for GitHub hosted

    private repositories
  18. @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
  19. @stablekernel Configured through .travis.yml file

  20. @stablekernel Configured through .travis.yml file .travis.yml language: objective-c osx_image: xcode8

    xcode_project: FizzBuzz.xcodeproj xcode_scheme: FizzBuzz
  21. @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:
  22. @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:
  23. @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:)
  24. @stablekernel From Zero To Hero in 45 Minutes ….

  25. @stablekernel

  26. @stablekernel

  27. @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. fastlane@krausefx.com): harr.florian@gmx.de [23:20:08]: Verifying if app is available on the Apple Developer Portal and iTunes Connect... [23:20:08]: Starting login with user 'harr.florian@gmx.de' 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 | harr.florian@gmx.de | | 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
  28. @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. fastlane@krausefx.com): harr.florian@gmx.de [23:20:08]: Verifying if app is available on the Apple Developer Portal and iTunes Connect...
  29. @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. fastlane@krausefx.com): harr.florian@gmx.de [23:20:08]: Verifying if app is available on the Apple Developer Portal and iTunes Connect...
  30. @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. fastlane@krausefx.com): harr.florian@gmx.de [23:20:08]: Verifying if app is available on the Apple Developer Portal and iTunes Connect...
  31. @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. fastlane@krausefx.com): harr.florian@gmx.de [23:20:08]: Verifying if app is available on the Apple Developer Portal and iTunes Connect...
  32. @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. fastlane@krausefx.com): harr.florian@gmx.de [23:20:08]: Verifying if app is available on the Apple Developer Portal and iTunes Connect...
  33. @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. fastlane@krausefx.com): harr.florian@gmx.de [23:20:08]: Verifying if app is available on the Apple Developer Portal and iTunes Connect...
  34. @stablekernel

  35. @stablekernel Sometimes builds fail ….

  36. @stablekernel Sometimes builds fail ….

  37. None
  38. @stablekernel Sometimes builds fail …. Search the logs

  39. @stablekernel Sometimes builds fail …. Search the logs SSH into

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

    the VM
  41. @stablekernel Sometimes builds fail …. Search the logs SSH into

    the VM
  42. @stablekernel Sometimes builds fail …. Search the logs SSH into

    the VM
  43. @stablekernel Sometimes builds fail …. Search the logs SSH into

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

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

    the VM https://gist.github.com/jedi4ever/ Replicate your VM Environment
  46. @stablekernel Extensions of CI

  47. @stablekernel Extensions of CI Fabric Lint UI Testing Code Coverage

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

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

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

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

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

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

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

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

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

    Snapshots AppStore Submission Beta Builds Changelogs PivotalTracker Matrix Builds Watermarks codecov.io
  57. @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
  58. @stablekernel Other CI Solutions

  59. @stablekernel Other CI Solutions

  60. @stablekernel • Similar to a managed full stack Travis CI

    Setup • Includes TestFlight like beta environment • Compatible with: • BitBucket • GitHub • GitLab Other CI Solutions
  61. @stablekernel Other CI Solutions

  62. @stablekernel • Continuous Integration + Deployment Platform • Configuration through

    circle.yml • Integrates with: • GitHub • Bitbucket • GitHub Enterprise Other CI Solutions
  63. @stablekernel Other CI Solutions

  64. @stablekernel Xcode Server: • Self Hosted • Has been problematic

    in the past • Integration with GitHub problematic Other CI Solutions
  65. @stablekernel Other CI Solutions

  66. @stablekernel • Self Hosted • Not always up to date

    • Relying on single open source project?! Other CI Solutions
  67. @stablekernel Conclusion

  68. @stablekernel Conclusion Why do we do all of this?

  69. @stablekernel Conclusion Why do we do all of this?

  70. @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 ….
  71. @stablekernel Conclusion And if that’s not reason enough ….

  72. Questions? Business Inquiries: Sarah Woodward Director of Business Development sarah.woodward@stablekernel.com

    Florian Harr @caffeineflo florian.harr@stablekernel.com blog.stablekernel.com @stablekernel