diff options
author | Natanael Copa <ncopa@alpinelinux.org> | 2009-12-17 14:52:56 +0000 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2009-12-17 14:52:56 +0000 |
commit | b79a727d20c673153bb4826adb70be5879ab1d1a (patch) | |
tree | ad774dc163cb58a26214e813fbaefb3016958c75 /lbu.in | |
parent | 63f898c17a41acd7d22657209fed005ae3c55fcd (diff) | |
download | alpine-conf-b79a727d20c673153bb4826adb70be5879ab1d1a.zip |
lbu: fix issue with lbu status and links
ref #91
Diffstat (limited to 'lbu.in')
-rw-r--r-- | lbu.in | 11 |
1 files changed, 7 insertions, 4 deletions
@@ -555,7 +555,7 @@ cmd_status() { [ -z "$LBU_MEDIA" ] && usage_status local tmp init_tmpdir tmp - mkdir -p "$tmpdir/a" "$tmp/b" + mkdir -p "$tmp/a" "$tmp/b" # unpack last commited apkovl to tmpdir/a unpack_apkovl "$tmp/a" @@ -567,8 +567,11 @@ cmd_status() { local f ( cd "$tmp"/a && find ) | while read f; do f=${f#./} - [ "$f" = "." ] && continue - [ -e "$tmp/b/$f" ] || echo "D $f" + local b="$tmp/b/$f" + if [ "$f" = "." ] || [ -e "$b" ] || [ -L "$b" ]; then + continue + fi + echo "D $f" done # compare files in b with files in a @@ -577,7 +580,7 @@ cmd_status() { [ "$f" = "." ] && continue local a="$tmp/a/$f" local b="$tmp/b/$f" - if [ ! -e "$a" ]; then + if [ ! -e "$a" ] && [ ! -L "$a" ]; then echo "A $f" elif [ -f "$a" ] && [ -f "$b" ] && [ "$b" -nt "$a" ] \ && ! cmp -s "$a" "$b"; then |