Slide 1

Slide 1 text

Auto Release TakuSemba CyberAgent.Inc

Slide 2

Slide 2 text

@takusemba https://github.com/TakuSemba

Slide 3

Slide 3 text

Release Step ɾpublish APK for alpha ɾpublish APK for production ɾmake a release note

Slide 4

Slide 4 text

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

Slide 5

Slide 5 text

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

Slide 6

Slide 6 text

gradle-play-publisher

Slide 7

Slide 7 text

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

Slide 8

Slide 8 text

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

Slide 9

Slide 9 text

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'

Slide 10

Slide 10 text

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') }

Slide 11

Slide 11 text

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 }

Slide 12

Slide 12 text

play { track = 'alpha' userFraction = 1 untrackOld = false errorOnSizeLimit = false uploadImages = true } build.gradle

Slide 13

Slide 13 text

./gradlew tasks --all

Slide 14

Slide 14 text

./gradlew app:bootstrapReleasePlayResources

Slide 15

Slide 15 text

./gradlew app:bootstrapReleasePlayResources

Slide 16

Slide 16 text

my app does blah blah blah…

Slide 17

Slide 17 text

my app does blah blah blah… and more blah…

Slide 18

Slide 18 text

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

Slide 19

Slide 19 text

No content

Slide 20

Slide 20 text

this release does something…

Slide 21

Slide 21 text

./gradlew app:publishApkRelease this release does something…

Slide 22

Slide 22 text

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

Slide 23

Slide 23 text

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

Slide 24

Slide 24 text

release note

Slide 25

Slide 25 text

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

Slide 26

Slide 26 text

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 }'

Slide 27

Slide 27 text

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 \

Slide 28

Slide 28 text

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 }'

Slide 29

Slide 29 text

No content

Slide 30

Slide 30 text

with CI

Slide 31

Slide 31 text

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

Slide 32

Slide 32 text

With

Slide 33

Slide 33 text

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