Auto Release @potatochips#48

A374f41eab3f73c50d8bab0652cb207a?s=47 TakuSemba
February 17, 2018

Auto Release @potatochips#48

A374f41eab3f73c50d8bab0652cb207a?s=128

TakuSemba

February 17, 2018
Tweet

Transcript

  1. Auto Release TakuSemba CyberAgent.Inc

  2. @takusemba https://github.com/TakuSemba

  3. Release Step ɾpublish APK for alpha ɾpublish APK for production

    ɾmake a release note
  4. Release Step ɾpublish APK for alpha (Auto) ɾpublish APK for

    production (Manual) ɾmake a release note (Auto)
  5. Release Step ɾpublish APK for alpha (Auto) ɾpublish APK for

    production (Manual) ɾmake a release note (Auto)
  6. gradle-play-publisher

  7. https://github.com/Triple-T/gradle-play-publisher

  8. apply plugin: ‘com.github.triplet.play' android { playAccountConfigs { defaultAccountConfig { serviceAccountEmail

    = 'your-service-account-email' pk12File = file('key.p12') } } defaultConfig { // ... playAccountConfig = playAccountConfigs.defaultAccountConfig } } build.gradle
  9. apply plugin: ‘com.github.triplet.play' android { playAccountConfigs { defaultAccountConfig { serviceAccountEmail

    = 'your-service-account-email' pk12File = file('key.p12') } } defaultConfig { // ... playAccountConfig = playAccountConfigs.defaultAccountConfig } } build.gradle apply plugin: ‘com.github.triplet.play'
  10. apply plugin: ‘com.github.triplet.play' android { playAccountConfigs { defaultAccountConfig { serviceAccountEmail

    = 'your-service-account-email' pk12File = file('key.p12') } } defaultConfig { // ... playAccountConfig = playAccountConfigs.defaultAccountConfig } } build.gradle defaultAccountConfig { serviceAccountEmail = 'your-service-account-email' pk12File = file('key.p12') }
  11. apply plugin: ‘com.github.triplet.play' android { playAccountConfigs { defaultAccountConfig { serviceAccountEmail

    = 'your-service-account-email' pk12File = file('key.p12') } } defaultConfig { // ... playAccountConfig = playAccountConfigs.defaultAccountConfig } } build.gradle defaultConfig { // ... playAccountConfig = playAccountConfigs.defaultAccountConfig }
  12. play { track = 'alpha' userFraction = 1 untrackOld =

    false errorOnSizeLimit = false uploadImages = true } build.gradle
  13. ./gradlew tasks --all

  14. ./gradlew app:bootstrapReleasePlayResources

  15. ./gradlew app:bootstrapReleasePlayResources

  16. my app does blah blah blah…

  17. my app does blah blah blah… and more blah…

  18. ./gradlew app:publishListingRelease my app does blah blah blah… and more

    blah…
  19. None
  20. this release does something…

  21. ./gradlew app:publishApkRelease this release does something…

  22. Release Step ɾpublish APK for alpha (Auto) ɾpublish APK for

    production (Manual) ɾmake a release note (Auto)
  23. Release Step ɾpublish APK for alpha (Auto) ɾpublish APK for

    production (Manual) ɾmake a release note (Auto)
  24. release note

  25. https://developer.github.com/v3/repos/releases/

  26. curl -X POST \ https://api.github.com/repos/TakuSemba/RepoName/releases \ -H 'Authorization: token abcdefg’

    \ -d '{ "tag_name": "release-3.0.15", "target_commitish": "release", "name": "release-3.0.15", "body": "Description of the release", "draft": true, "prerelease": false }'
  27. curl -X POST \ https://api.github.com/repos/TakuSemba/RepoName/releases \ -H 'Authorization: token abcdefg’

    \ -d '{ "tag_name": "release-3.0.15", "target_commitish": "release", "name": "release-3.0.15", "body": "Description of the release", "draft": true, "prerelease": false }' https://api.github.com/repos/TakuSemba/RepoName/releases \
  28. curl -X POST \ https://api.github.com/repos/TakuSemba/RepoName/releases \ -H 'Authorization: token abcdefg’

    \ -d '{ "tag_name": "release-3.0.15", "target_commitish": "release", "name": "release-3.0.15", "body": "Description of the release", "draft": true, "prerelease": false }' -d '{ "tag_name": "release-3.0.15", "target_commitish": "release", "name": "release-3.0.15", "body": "Description of the release", "draft": true, "prerelease": false }'
  29. None
  30. with CI

  31. When release tag pushed If TAG=$(git describe --exact-match --tags HEAD)

    if echo ${TAG} | grep -v release-; then echo "tag: " ${TAG} echo "failed: tag name does not contain 'release-'." exit 1 fi DIFF=$(git diff origin/release..${TAG}) if [ -n "$DIFF" ]; then echo ${DIFF} echo "failed: between origin/release and " ${TAG} " has diffs" exit 1 fi
  32. With

  33. Auto Release https://github.com/takusemba https://twitter.com/takusemba