# Git clone the latest tag with a pattern

**URL:** <https://discuss.bitrise.io/t/git-clone-the-latest-tag-with-a-pattern/12389>\
**Category:** Question & Answer\
**Created:** [March 25, 2020, 10:56am UTC](https://discuss.bitrise.io/t/git-clone-the-latest-tag-with-a-pattern/12389 "2020-03-25T10:56:44Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![bawenang\_r](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.bitrise.io/bawenang_r/32/3568_2.png) [@bawenang\_r](https://discuss.bitrise.io/u/bawenang_r)\
**Post date:** [March 25, 2020, 10:56am UTC](https://discuss.bitrise.io/t/git-clone-the-latest-tag-with-a-pattern/12389/1 "2020-03-25T10:56:44Z")

</div>

Hi,  
This is the first time I use Bitrise and I need help to clone only the latest tag with the prefix “tested-\*”. I’ve already made a workflow that will be scheduled every hour between 9AM-6PM every workday for testing. At the end of the workflow, I’ve added a step to add a tag “tested-{timestamp}” for the latest green build. Right now, I’m trying to do a workflow that will fetch the latest “tested” tag at the end of the day to build and deploy to Testflight. The problem is I can’t seem to fetch the specific tag even though I’ve overridden the `$BITRISE_GIT_TAG` environment variable to `tested-*`. So how do I clone a commit with that specific tag?

Thanks in advance.

PS: I don’t need to trigger it on every tag push so I don’t need a `trigger_map` for this, I think.

---

<div class="post-metadata">

**Author:** ![bawenang\_r](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.bitrise.io/bawenang_r/32/3568_2.png) [@bawenang\_r](https://discuss.bitrise.io/u/bawenang_r)\
**Post date:** [March 29, 2020, 7:34am UTC](https://discuss.bitrise.io/t/git-clone-the-latest-tag-with-a-pattern/12389/2 "2020-03-29T07:34:07Z")

</div>

Nevermind. I guess it’s not possible to do so. I’ve switched to triggering on push commit. Thanks.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex016/uploads/bitrise/original/2X/d/d901cf2aad020f2dd11918afc89ec2089bb87b35.png) [@system](https://discuss.bitrise.io/u/system)\
**Post date:** [April 28, 2020, 7:45am UTC](https://discuss.bitrise.io/t/git-clone-the-latest-tag-with-a-pattern/12389/3 "2020-04-28T07:45:33Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
