From ff21aa1138773da002e146f9d2a9849623db4580 Mon Sep 17 00:00:00 2001 From: mid-kid Date: Sun, 19 Mar 2017 02:04:41 +0100 Subject: [PATCH] Support extrafiles from the same dir as satellite if extrafiles dir doesn't exist --- astronaut/astronaut | 5 ++++- astronaut/extrafiles/astronaut | 1 - 2 files changed, 4 insertions(+), 2 deletions(-) delete mode 120000 astronaut/extrafiles/astronaut diff --git a/astronaut/astronaut b/astronaut/astronaut index 401bff3..66a684a 100755 --- a/astronaut/astronaut +++ b/astronaut/astronaut @@ -192,7 +192,10 @@ getfile() { } extrafile() { - cp -a "$(dirname "$_satellite")/extrafiles/$name/$1" "./$1" + local dir="$(dirname "$_satellite")" + [ -d "$dir/extrafiles" ] && local dir="$dir/extrafiles/$name" + + cp -a "$dir/$1" "./$1" } dlextract() { diff --git a/astronaut/extrafiles/astronaut b/astronaut/extrafiles/astronaut deleted file mode 120000 index a96aa0e..0000000 --- a/astronaut/extrafiles/astronaut +++ /dev/null @@ -1 +0,0 @@ -.. \ No newline at end of file