summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJames Murty <james@murty.co>2014-05-26 14:04:15 +0100
committerJames Murty <james@murty.co>2014-05-26 14:04:15 +0100
commit3accd13eb809f1c1c809eccd4a7ef06f83ff5401 (patch)
tree444193b7488176d7d6f5f23ee63e74bed7ac7bf3
parent873593803defff42df2635c0df831fe9092febd8 (diff)
downloadgit-fat-3accd13eb809f1c1c809eccd4a7ef06f83ff5401.tar.gz
Use custom fullpath() fn to avoid confusion with realpath vs alternative
* Define and use simple `pwd`-based fullpath() function * Remove misleading comment Confirmed to work on OSX.
-rwxr-xr-xtest-retroactive.sh11
1 files changed, 4 insertions, 7 deletions
diff --git a/test-retroactive.sh b/test-retroactive.sh
index be7011c..51a38ec 100755
--- a/test-retroactive.sh
+++ b/test-retroactive.sh
@@ -1,9 +1,6 @@
#!/bin/sh -ex
-# Use Python's abspath as substitute if realpath isn't available (e.g. on OSX)
-command -v realpath >/dev/null 2>&1 || realpath() {
- echo "`pwd`/$1"
-}
+fullpath() { echo "`pwd`/$1"; }
git init retro
cd retro
@@ -31,7 +28,7 @@ git commit -am'Import big files into git-fat'
git log --stat
git fat find 10000 | awk '{print $1}' > fat-files
-git filter-branch --index-filter "git fat index-filter $(realpath fat-files) --manage-gitattributes" --tag-name-filter cat -- --all
+git filter-branch --index-filter "git fat index-filter $(fullpath fat-files) --manage-gitattributes" --tag-name-filter cat -- --all
git log --stat
git checkout HEAD^
@@ -43,14 +40,14 @@ ls -al
git checkout master
cat > .gitfat <<EOF
[rsync]
-remote = $(realpath ../retro-store)
+remote = $(fullpath ../retro-store)
EOF
git add .gitfat
git commit -m'Add .gitfat for local push'
git fat push
cd ..
-git clone file:///$(realpath retro) retro-clone
+git clone file:///$(fullpath retro) retro-clone
cd retro-clone
git fat init
git fat pull