Modules and functions have return values

Modules can now use return values with the exit_module function.
Some return values are predefined, use them by passing special string
to the function.

Most of the functions also switched from a echo "true" to return 0
scheme, which means that every test involving theses functions was
rewritten.

No more need for the reset_vars function, as modules are run in
subshells, thus providing a new scope level.

The case when no modules is specified is better handled, a LÖVE file is
created by default.
This commit is contained in:
Antonin Décimo
2015-06-16 17:06:30 +02:00
parent 6e58597f36
commit 2c588118af
6 changed files with 82 additions and 94 deletions

View File

@@ -1,7 +1,5 @@
# Mac OS X
if [[ $(execute_module "osx") == false ]]; then
return
fi
execute_module "osx"
init_module "Mac OS X"