summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2015-09-26 15:18:16 +0200
committerMichał Górny <mgorny@gentoo.org>2015-11-29 11:03:17 +0100
commit08aa7c8e5c5add6922816f8354669be87351630c (patch)
tree210fa9d8e2c32c9f6d347bf77222a167f41bdba7 /eclass/git-r3.eclass
parentgit-r3.eclass: Remove unused variable (diff)
downloadgentoo-08aa7c8e5c5add6922816f8354669be87351630c.tar.gz
gentoo-08aa7c8e5c5add6922816f8354669be87351630c.tar.bz2
gentoo-08aa7c8e5c5add6922816f8354669be87351630c.zip
git-r3.eclass: Accept any ref rather than refs/heads/* only
Fixes: https://bugs.gentoo.org/show_bug.cgi?id=556822
Diffstat (limited to 'eclass/git-r3.eclass')
-rw-r--r--eclass/git-r3.eclass6
1 files changed, 3 insertions, 3 deletions
diff --git a/eclass/git-r3.eclass b/eclass/git-r3.eclass
index faee4588f852..8b5ffd531845 100644
--- a/eclass/git-r3.eclass
+++ b/eclass/git-r3.eclass
@@ -581,8 +581,8 @@ git-r3_fetch() {
if [[ ${remote_ref} == HEAD ]]; then
# HEAD
fetch_l=HEAD
- elif [[ ${remote_ref} == refs/heads/* ]]; then
- # regular branch
+ elif [[ ${remote_ref} == refs/* ]]; then
+ # regular branch, tag or some other explicit ref
fetch_l=${remote_ref}
else
# tag or commit id...
@@ -919,7 +919,7 @@ git-r3_peek_remote_ref() {
einfo "Peeking \e[1m${remote_ref}\e[22m on \e[1m${r}\e[22m ..." >&2
local lookup_ref
- if [[ ${remote_ref} == refs/heads/* || ${remote_ref} == HEAD ]]
+ if [[ ${remote_ref} == refs/* || ${remote_ref} == HEAD ]]
then
lookup_ref=${remote_ref}
else