# checkout every submodule
$GIT submodule update --remote --rebase || echo "error during checkout of submodules" >> $ERROR_LOG
+# return to main directory
+cd $CWD
+
# we grab the module's version numbers before deleting everything git related
sh ${CWD}/GRAB_VERSION.sh $SRCDIR
# we are done with git, so let's cleanup from all the unwanted git folders and files
-find . -name '.git*' -mindepth 1 -exec rm -rfv '{}' \; || echo "error during removal of git files from source" >> $ERROR_LOG
+find $SRCDIR -name '.git*' -mindepth 1 -exec rm -rfv '{}' \; || echo "error during removal of git files from source" >> $ERROR_LOG
# ALL DONE
FILES=$(/bin/ls $CWD)
for f in $FILES; do
if [ "$(grep -Poc $f ../modules.txt)" -lt 1 ]; then
- if [[ $f != "CHECK_SLACKDESC.sh" && $f != "make_slack-desc.sh" ]]; then
+ if [[ $f != "CHECK_SLACKDESC.sh" && $f != "make_slack-desc.sh" && != "libfm-extra" ]]; then
rm $f
fi
fi