diff options
author | P. J. McDermott <pjm@nac.net> | 2012-10-24 00:06:29 (EDT) |
---|---|---|
committer | P. J. McDermott <pjm@nac.net> | 2012-10-24 00:06:29 (EDT) |
commit | c20bbe68307a79c5a08ece9cb7b752ff1555c73d (patch) | |
tree | f65f5e5b5ceda2c346a371190eb26ffff4fd6850 /src | |
parent | 43bc4c837f5b47a45efdafceb80b76a1fed41ffb (diff) |
Look both ways before unpacking sources.
Diffstat (limited to 'src')
-rw-r--r-- | src/ob-unpacksource.sh | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/ob-unpacksource.sh b/src/ob-unpacksource.sh index baea705..9954454 100644 --- a/src/ob-unpacksource.sh +++ b/src/ob-unpacksource.sh @@ -37,10 +37,14 @@ main() ob_init_package '..' ob_parse_package_metadata -c '.opkbuild.cache' - if [ -d '../src' ]; then - unpack_native + if [ -d 'src' ]; then + ob_info "$(ob_get_msg 'already_unpacked')" else - unpack_upstream + if [ -d '../src' ]; then + unpack_native + else + unpack_upstream + fi fi } |