{"action":"opened","issue":{"url":"https://api.github.com/repos/fastlane/fastlane/issues/1039","labels_url":"https://api.github.com/repos/fastlane/fastlane/issues/1039/labels{/name}","comments_url":"https://api.github.com/repos/fastlane/fastlane/issues/1039/comments","events_url":"https://api.github.com/repos/fastlane/fastlane/issues/1039/events","html_url":"https://github.com/fastlane/fastlane/issues/1039","id":124214950,"number":1039,"title":"Git Last Tag on a shallow clone","user":{"login":"jeeftor","id":6491743,"avatar_url":"https://avatars.githubusercontent.com/u/6491743?v=3","gravatar_id":"","url":"https://api.github.com/users/jeeftor","html_url":"https://github.com/jeeftor","followers_url":"https://api.github.com/users/jeeftor/followers","following_url":"https://api.github.com/users/jeeftor/following{/other_user}","gists_url":"https://api.github.com/users/jeeftor/gists{/gist_id}","starred_url":"https://api.github.com/users/jeeftor/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jeeftor/subscriptions","organizations_url":"https://api.github.com/users/jeeftor/orgs","repos_url":"https://api.github.com/users/jeeftor/repos","events_url":"https://api.github.com/users/jeeftor/events{/privacy}","received_events_url":"https://api.github.com/users/jeeftor/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-12-29T13:58:29Z","updated_at":"2015-12-29T13:58:29Z","closed_at":null,"body":"I have a question about working with the `git_last_tag` command on a shallow clone.  \r\n\r\nI'm using bamboo as my CI server and fastlane.  Bamboo (by default) does a shallow clone which doesn't seem to be pulling tags correctly.  \r\n\r\nI follow that up with a `git fetch --tags` which then pulls in the tags.\r\n\r\nI've noticed in `git_helper.rb` it looks like the last_tag command is doing `git describe --tags --abbrev=0`\r\n\r\n    def self.last_git_tag_name(match_lightweight = true)\r\n      command = ['git describe']\r\n      command << '--tags' if match_lightweight\r\n      command << '--abbrev=0'\r\n      Actions.sh(command.join(' '), log: false).chomp\r\n     rescue\r\n      nil\r\n     end\r\n\r\nThis doesn't *seem* to be working correctly whereas the command:\r\n\r\n    git describe --tags `git rev-list --tags --max-count=1`\r\n\r\ndoes pull the last tag correctly.  Should the code be updated to mirror this behavior?  I guess i'm a little clear what \"last_tag\" means.\r\n\r\n"}}