diff options
author | Daniel Friesel <derf@derf.homelinux.org> | 2009-03-12 23:44:06 +0100 |
---|---|---|
committer | Daniel Friesel <derf@derf.homelinux.org> | 2009-03-12 23:44:06 +0100 |
commit | cc432943b3de181509cd957dd0fbdb1611aa508a (patch) | |
tree | 294db344f5c198a1241bfcd04b27999d0492db26 /bin | |
parent | 9a00ba48425f2a5eb3e091eed860c9cfa32e0ed1 (diff) |
pkg refresh: Forcefully fix git remote origin
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/pkg | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -253,7 +253,8 @@ function vcs_status { # Set the correct origin function vcs_fix_origin { - if [[ ! -r .git/remotes/origin && ! -r .git/refs/remotes/origin ]] { + [[ $1 == rewrite ]] && git remote rm origin + if [[ ! -r .git/remotes/origin && ! -r .git/refs/remotes/origin/HEAD ]] { fgrep '[remote "origin"]' .git/config &> /dev/null || git remote add origin $PKG_ROOT/$1 } @@ -694,6 +695,7 @@ function pkg_refresh { info "Cleaning build diroctery\n" make clean } + vcs_fix_origin rewrite global_hook $1 post-update } |