Skip to content

Commit

Permalink
Added support for symlinks
Browse files Browse the repository at this point in the history
  • Loading branch information
glutanimate committed Dec 23, 2014
1 parent 70234fa commit 96aa3fc
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions moodyrain
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@ GuiTxtReset="Reset all volume sliders to 0"
arg_compile_sounds(){
unset Sounds SoundID File
while IFS= read -r -d '' File; do
if [[ ! "$(file -ib "$File")" == *application/ogg* ]]; then
echo "$File"
if [[ ! "$(file -Lib "$File")" == *application/ogg* ]]; then
echo "Error: '$File' is not an ogg file. Ignoring."
continue
fi
Expand All @@ -48,7 +49,7 @@ arg_compile_sounds(){
Artists[SoundID]="?"
fi
((SoundID++))
done < <(find "$SoundDir" -type f -name '*.ogg' -print0 | sort -z --version-sort)
done < <(find -L "$SoundDir" -type f -name '*.ogg' -print0 | sort -z --version-sort)
}

arg_compose_gui(){
Expand Down

0 comments on commit 96aa3fc

Please sign in to comment.