]> git.e2factory.org Git - e2factory.git/commitdiff
better error handling in case of branches with no remote
authorGordon Hecker <gh@emlix.com>
Wed, 30 Sep 2009 13:04:28 +0000 (15:04 +0200)
committerGordon Hecker <gh@emlix.com>
Fri, 2 Oct 2009 10:40:07 +0000 (12:40 +0200)
Signed-off-by: Gordon Hecker <gh@emlix.com>
local/git.lua

index 1f3d248195439e09d652d2819211e47da3ee1a53..4c220c3dc5a5b72be1327726997fc010041d4eed 100644 (file)
@@ -762,9 +762,8 @@ function git.check_workingcopy(info, sourcename)
        expect = string.format("origin")
        res, re = generic_git.git_config(gitdir, query)
        if not res then
-               return false, e:cat(re)
-       end
-       if res ~= expect then
+               e:append("remote is not configured for branch %s", src.branch)
+       elseif res ~= expect then
                e:append("%s is not \"origin\"", query)
        end
        -- git config remote.origin.url == server:location