From 5903d20d5ec6fc9ef9b3cb517beefed34907e6f3 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Fri, 16 May 2014 16:22:50 -0400 Subject: [PATCH] Support symlinking git-annex and git-annex-shell from the Linux standalone bundle into PATH. Unless busybox doesn't support readlink -f, then it just uses readlink and symlinking won't work. Also, OSX has no readlink -f so not done there. Thanks, jlebar. --- debian/changelog | 3 +++ standalone/linux/skel/git | 2 +- standalone/linux/skel/git-annex | 2 +- standalone/linux/skel/git-annex-shell | 2 +- standalone/linux/skel/git-annex-webapp | 2 +- standalone/linux/skel/git-receive-pack | 2 +- standalone/linux/skel/git-shell | 2 +- standalone/linux/skel/git-upload-pack | 2 +- 8 files changed, 10 insertions(+), 7 deletions(-) diff --git a/debian/changelog b/debian/changelog index 7d1ec0b87a..37e9bdf064 100644 --- a/debian/changelog +++ b/debian/changelog @@ -16,6 +16,9 @@ git-annex (5.20140422) UNRELEASED; urgency=medium of a repository. * Add remote.$name.annex-shell configuration. Thanks, Fraser Tweedale + * Support symlinking git-annex and git-annex-shell + from the Linux standalone bundle into PATH. + Thanks, jlebar. -- Joey Hess Fri, 02 May 2014 15:28:53 -0300 diff --git a/standalone/linux/skel/git b/standalone/linux/skel/git index f32cf81932..7fbf827153 100755 --- a/standalone/linux/skel/git +++ b/standalone/linux/skel/git @@ -1,5 +1,5 @@ #!/bin/sh -link="$(readlink "$0")" || true +link="$(readlink -f "$0" 2>/dev/null || readlink "$0")" || true if [ -n "$link" ]; then base="$(dirname "$link")" else diff --git a/standalone/linux/skel/git-annex b/standalone/linux/skel/git-annex index 27df466e42..7fc864d87b 100755 --- a/standalone/linux/skel/git-annex +++ b/standalone/linux/skel/git-annex @@ -1,5 +1,5 @@ #!/bin/sh -link="$(readlink "$0")" || true +link="$(readlink -f "$0" 2>/dev/null || readlink "$0")" || true if [ -n "$link" ]; then base="$(dirname "$link")" else diff --git a/standalone/linux/skel/git-annex-shell b/standalone/linux/skel/git-annex-shell index a078955911..37dbca0490 100755 --- a/standalone/linux/skel/git-annex-shell +++ b/standalone/linux/skel/git-annex-shell @@ -1,5 +1,5 @@ #!/bin/sh -link="$(readlink "$0")" || true +link="$(readlink -f "$0" 2>/dev/null || readlink "$0")" || true if [ -n "$link" ]; then base="$(dirname "$link")" else diff --git a/standalone/linux/skel/git-annex-webapp b/standalone/linux/skel/git-annex-webapp index acf2a5135e..24a533969e 100755 --- a/standalone/linux/skel/git-annex-webapp +++ b/standalone/linux/skel/git-annex-webapp @@ -1,5 +1,5 @@ #!/bin/sh -link="$(readlink "$0")" || true +link="$(readlink -f "$0" 2>/dev/null || readlink "$0")" || true if [ -n "$link" ]; then base="$(dirname "$link")" else diff --git a/standalone/linux/skel/git-receive-pack b/standalone/linux/skel/git-receive-pack index 32d166e84e..718541786e 100755 --- a/standalone/linux/skel/git-receive-pack +++ b/standalone/linux/skel/git-receive-pack @@ -1,5 +1,5 @@ #!/bin/sh -link="$(readlink "$0")" || true +link="$(readlink -f "$0" 2>/dev/null || readlink "$0")" || true if [ -n "$link" ]; then base="$(dirname "$link")" else diff --git a/standalone/linux/skel/git-shell b/standalone/linux/skel/git-shell index e3cef0f675..20c184bdf7 100755 --- a/standalone/linux/skel/git-shell +++ b/standalone/linux/skel/git-shell @@ -1,5 +1,5 @@ #!/bin/sh -link="$(readlink "$0")" || true +link="$(readlink -f "$0" 2>/dev/null || readlink "$0")" || true if [ -n "$link" ]; then base="$(dirname "$link")" else diff --git a/standalone/linux/skel/git-upload-pack b/standalone/linux/skel/git-upload-pack index f05aad83ee..1df3f3f6c3 100755 --- a/standalone/linux/skel/git-upload-pack +++ b/standalone/linux/skel/git-upload-pack @@ -1,5 +1,5 @@ #!/bin/sh -link="$(readlink "$0")" || true +link="$(readlink -f "$0" 2>/dev/null || readlink "$0")" || true if [ -n "$link" ]; then base="$(dirname "$link")" else