google / sagetv

SageTV is a cross-platform networked DVR and media management system
http://forums.sagetv.com/
Apache License 2.0
267 stars 173 forks source link

added deploy script for auto-deployment to Bintray and github release tagging #307

Closed stuckless closed 7 years ago

stuckless commented 7 years ago

Will read the last git commit message and if that message contains [ci release] then this script will push to Bintray as a release, tagging the release with the VERSION tag.

eg, if the message was "Updated release version [ci release]" then this script will push the release to Bintray AFTER a successful build that is NOT a pull request.

It will then git tag the release with the VERSION tag and then push that tag to github.

Secure Environment Requirements BINTRAY_USER : For releasing BINTRAY_API : For releasing GITHUB_KEY : For tagging (if empty then tagging will not be done) GITHUB_USER : For tagging GITHUB_EMAIL : For tagging

NOTE: Travis has not been updated, yet, to know about the secure variables. If we agree this is something we want, I can update Travis accordingly.

The goal here is to have the releasing to Bintray something that happens automatically based on the commit message, so that we can remove myself from the "build/release" blocking loop.

The flow for this might be something like this... Someone updates the Version.java and CHANGELOG.md files with the release information, and then commits that using the [ci release] message. Travis will do a full build, and then release it.

I didn't want to create a bunch of releases to test this, so I suspect the first couple of releases will fail, and we'll iron out the kinks during that process. But you should review the script for any logical errors that stand out.

Narflex commented 7 years ago

Apparently this is failing after it has been merged. It looks like the path information for the Version.java file is wrong, there's also some BINTRAY environment variables that aren't set.

https://travis-ci.org/google/sagetv/builds/244614314?utm_source=email&utm_medium=notification

stuckless commented 7 years ago

I haven't configured the Travis Variables, yet, but, I see that I put the checks for those before the check to see if we are actually doing a deploy.

I'll fix this up tonight, and do a direct push. I did a pull request for the initial changes, to see if there were any discussions around what I'm attempting to do here.

On Mon, Jun 19, 2017 at 2:04 PM Jeffrey Kardatzke notifications@github.com wrote:

Apparently this is failing after it has been merged. It looks like the path information for the Version.java file is wrong, there's also some BINTRAY environment variables that aren't set.

https://travis-ci.org/google/sagetv/builds/244614314?utm_source=email&utm_medium=notification

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/google/sagetv/pull/307#issuecomment-309519657, or mute the thread https://github.com/notifications/unsubscribe-auth/ABAfKUvynz78RST-oonw1ANfkd8ck38sks5sFrhKgaJpZM4N9OM7 .

--

Sent from Android