11

I'd like to deploy files using Travis CI and it only works for a tagged commit. When committing to the branch, there is a warning:

Skipping a deployment with the releases provider because this is not a tagged commit.

Is there any way to deploy on branched commit using Travis CI?

To clarify, it works when I tag the commit, but I'd like to deploy files on each commit for the given branch.

030
  • 13,383
  • 17
  • 76
  • 178
kenorb
  • 8,011
  • 14
  • 43
  • 80

2 Answers2

6

Instead of using Travis' deployment features, build the deployment logic in to your normal "test" script(s). For a PaaS this might be as simple as pushing to another git remote if all tests pass, but the sky is the limit.

coderanger
  • 1,197
  • 9
  • 11
4

Travis CI supports deployment on branch release by using the following syntax:

deploy:
  on:
    branch: release

The problem is that GitHub does not support it.

As per GitHub Releases Uploading page at Travis CI:

Please note that deploying GitHub Releases works only for tags, not for branches.

For GitHub the only workaround is to push tags (e.g. git push origin master --tags).

Or solution is to use different supported provider.

kenorb
  • 8,011
  • 14
  • 43
  • 80