install.sh: Treat $binpath as target directory.
In case $binpath/$bin is an already existing directory, the command mv "$bin" "$binpath/$bin" would store the binary in the place $binpath/$bin/$bin. I guess this is not the expected behavior. Therefore I used the -t option of `mv' to specify the target directory explicitly. License: MIT Signed-off-by: Stephan Kulla <git.mail@kulla.me>
Stephan Kulla committed
Sep 7, 2016 at 13:29 UTC
28a69eea10c898b7792c6e33123320f1c76b4b8f
1 file changed
+1
-1
cmd/ipfs/dist/install.sh
+1
-1
@@ -9,7 +9,7 @@ binpaths="/usr/local/bin /usr/bin"
9
10
for binpath in $binpaths; do
11
if [ -d "$binpath" ]; then
12
- mv "$bin" "$binpath/$bin"
12
+ mv -t "$binpath" "$bin"
13
echo "installed $binpath/$bin"
14
exit 0
15
fi