Skip to content

Commit 5e6ecd0

Browse files
committed
sbin/makepkg: resolve failure when source is git url with suffix
Due to the change in 5abefe3, the protocol is not judged as git anymore, which results in ==> Retrieving sources... -> Source is https://github.com/axboe/fio.git#tag=fio-3.40 -> Downloading fio.git#tag=fio-3.40... ==> /tmp/stderr <== % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 162 100 162 0 0 152 0 0:00:01 0:00:01 --:--:-- 152 100 507k 0 507k 0 0 181k 0 --:--:-- 0:00:02 --:--:-- 658k The expected behavior is ==> Retrieving sources... -> Source is https://github.com/axboe/fio.git#tag=fio-3.38 -> Cloning fio git repo... Fixes: 5abefe3 ("Fix Git URL parsing in get_protocol (#520)") Signed-off-by: Philip Li <philip.li@intel.com>
1 parent ffce904 commit 5e6ecd0

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

sbin/makepkg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -274,7 +274,7 @@ get_url() {
274274

275275
# extract the protocol from a source entry - return "local" for local sources
276276
get_protocol() {
277-
if [[ $1 =~ \.git$ ]]; then
277+
if [[ $1 =~ \.git$ || $1 =~ \.git# ]]; then
278278
printf "%s\n" "git"
279279
elif [[ $1 = *://* ]]; then
280280
# strip leading filename

0 commit comments

Comments
 (0)