# Release on new tag

**URL:** <https://travis-ci.community/t/release-on-new-tag/7032>\
**Category:** Deployment\
**Created:** [January 28, 2020, 3:37pm UTC](https://travis-ci.community/t/release-on-new-tag/7032 "2020-01-28T15:37:30Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![dbu](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/dbu/32/3730_2.png) [@dbu](https://travis-ci.community/u/dbu)\
**Post date:** [January 28, 2020, 3:37pm UTC](https://travis-ci.community/t/release-on-new-tag/7032/1 "2020-01-28T15:37:30Z")

</div>

I try to build an archive and upload it to the release page on github when i push a tag. However, i can’t see any builds for the tag that i pushed at [https://travis-ci.org/rokka-io/rokka-client-php-cli/builds](https://travis-ci.org/rokka-io/rokka-client-php-cli/builds) . I do see the build on master, but i pushed that and some minutes later tagged the last master commit and pushed the tag. In a different repository, i see a build for the tag in the list, and then travis-ci generates the archive and uploads it.

In settings, i have no build types disabled.  
My configuration is [https://github.com/rokka-io/rokka-client-php-cli/blob/master/.travis.yml](https://github.com/rokka-io/rokka-client-php-cli/blob/master/.travis.yml) (i hope that the matrix & jobs parts can be in the config together like this)

---

<div class="post-metadata">

**Author:** ![BanzaiMan](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/banzaiman/32/67_2.png) [@BanzaiMan](https://travis-ci.community/u/BanzaiMan)\
**Post date:** [January 28, 2020, 3:56pm UTC](https://travis-ci.community/t/release-on-new-tag/7032/2 "2020-01-28T15:56:50Z")

</div>

See [https://travis-ci.org/rokka-io/rokka-client-php-cli/requests](https://travis-ci.org/rokka-io/rokka-client-php-cli/requests)

> <https://github.com/rokka-io/rokka-client-php-cli/blob/ab3fa7761b34792716f01497bc474aa480bb9137/.travis.yml#L39-L43>

You are allowing builds on `master` and those matching `/^\d+\.\d+$/`. The tag `1.9.0` does not match it. Maybe you meant `/^\d(\.\d+)+$/` or similar.

---

<div class="post-metadata">

**Author:** ![dbu](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/dbu/32/3730_2.png) [@dbu](https://travis-ci.community/u/dbu)\
**Post date:** [January 28, 2020, 4:14pm UTC](https://travis-ci.community/t/release-on-new-tag/7032/3 "2020-01-28T16:14:21Z")

</div>

thanks a ton! now i feel stupid 🤦‍♂️

---

<div class="post-metadata">

**Author:** ![BanzaiMan](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/banzaiman/32/67_2.png) [@BanzaiMan](https://travis-ci.community/u/BanzaiMan)\
**Post date:** [January 28, 2020, 4:18pm UTC](https://travis-ci.community/t/release-on-new-tag/7032/4 "2020-01-28T16:18:15Z")

</div>

We’ve all done it. It’s good to have a second set of eyes. 🙂

---

<div class="post-metadata">

**Author:** ![dbu](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/dbu/32/3730_2.png) [@dbu](https://travis-ci.community/u/dbu)\
**Post date:** [January 28, 2020, 4:29pm UTC](https://travis-ci.community/t/release-on-new-tag/7032/5 "2020-01-28T16:29:13Z")

</div>

hm, now i get a deploy build, but it does not do the actual release it is supposed to do. [https://travis-ci.org/rokka-io/rokka-client-php-cli/jobs/642965873](https://travis-ci.org/rokka-io/rokka-client-php-cli/jobs/642965873)  
the before\_deploy step seems not being executed.

looking at the parsed configuration at [https://travis-ci.org/rokka-io/rokka-client-php-cli/jobs/642965873/config](https://travis-ci.org/rokka-io/rokka-client-php-cli/jobs/642965873/config) i notice that it says “true”: {“tags”:true} rather than “on”: {“tags”:true}, but i did that as in the documentation - not sure if this config is necessary, as deploy only happens when we have a tag anyways.

---

<div class="post-metadata">

**Author:** ![BanzaiMan](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/banzaiman/32/67_2.png) [@BanzaiMan](https://travis-ci.community/u/BanzaiMan)\
**Post date:** [January 28, 2020, 9:20pm UTC](https://travis-ci.community/t/release-on-new-tag/7032/6 "2020-01-28T21:20:07Z")

</div>

Your definition is not quite right.

```auto
jobs:
  include:
    - stage: deploy
      script: skip
      env: COMPOSER_FLAGS=""
      before_deploy: make dist
      deploy: # <=== this
        provider: releases
        api_key:
          secure: XXXXXXX
        file: dist/rokka-cli.phar
        skip_cleanup: true
        on:
          tags: true

```

There is not `deploy` defined, so there is no `before_deploy`, either.

> **[Travis CI Documentation](https://docs.travis-ci.com/user/deployment/releases)**
>
> GitHub Releases Uploading

---

<div class="post-metadata">

**Author:** ![dbu](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/dbu/32/3730_2.png) [@dbu](https://travis-ci.community/u/dbu)\
**Post date:** [February 4, 2020, 9:00pm UTC](https://travis-ci.community/t/release-on-new-tag/7032/7 "2020-02-04T21:00:42Z")

</div>

finally made it work, thanks for your help!

i needed to merge the matrix and the jobs section for it to actually work, doing an entry to stages for “test” as well, and label all my other things test.
