Fix module loading logic
Modules are located on the `modules` folder on the project. By default, kickstart will put itself on the `compile/modules/kickstart` before any folder is linked there as well. This give the possibility of overriding which kickstart project will be deployed with you. Kickstart is treated as an special folder, given that the projects requires its functions. So, it is loaded before all of the modules, and skiped looping over the `modules` folder.
This commit is contained in:
parent
e08395a0ea
commit
e60e0bbebf
@ -2,10 +2,16 @@
|
||||
|
||||
module_loading=$(cat <<MODULE
|
||||
current_dir=\$(pwd)
|
||||
cd modules/kickstart
|
||||
source install.sh
|
||||
cd \$current_dir
|
||||
|
||||
for module in modules/*; do
|
||||
cd \$module
|
||||
source install.sh
|
||||
cd \$current_dir
|
||||
if [ ! \$module = module/kickstart ]; then
|
||||
cd \$module
|
||||
source install.sh
|
||||
cd \$current_dir
|
||||
fi
|
||||
done
|
||||
MODULE
|
||||
)
|
||||
@ -26,7 +32,7 @@ link_modules() {
|
||||
|
||||
if [ -d modules ]; then
|
||||
for module in modules/*; do
|
||||
ln -s ../../modules/$module compile/modules/$module
|
||||
ln -s `pwd`/$module compile/$module
|
||||
done
|
||||
fi
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user