diff options
Diffstat (limited to 'debian/roll-tarballs.sh')
-rwxr-xr-x | debian/roll-tarballs.sh | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/debian/roll-tarballs.sh b/debian/roll-tarballs.sh index 0f9568aad..52c2090f0 100755 --- a/debian/roll-tarballs.sh +++ b/debian/roll-tarballs.sh @@ -52,7 +52,7 @@ else fi if [ x"$RELEASE" == "xHEAD" ]; then - CHECKOUT=refs/heads/$(git rev-parse --abbrev-ref HEAD) + CHECKOUT="refs/heads/$(git rev-parse --abbrev-ref HEAD)" fi if ! git rev-parse --verify -q "$CHECKOUT" >/dev/null; then @@ -80,14 +80,14 @@ cd "${TEMP_DIR}/${PROJECT}-${RELEASE}/" # Replace symlinks by copies of the linked target files # Note: We don't have symlinked directories!!! -find . -type l | while read link; do - TARGET=$(readlink "$link") - cd $(dirname "$link") - if [ -f "$TARGET" ]; then - rm -f $(basename "$link") - cp "${TARGET}" $(basename "$link") +find . -type "l" | while read link; do + TARGET="$(readlink "${link}")" + pushd "$(dirname "${link}")" >/dev/null + if [ -f "${TARGET}" ]; then + rm -f "$(basename "${link}")" + cp "${TARGET}" "$(basename "${link}")" fi - cd - 1>/dev/null + popd >/dev/null done mkdir -p "doc/applied-patches" |