Rewrite -export to make it work correctly.
First thing in the morning, rewrite the -export command. It works now, I tested it before committing changes.
This commit is contained in:
parent
78d9a2041f
commit
898c15872b
1 changed files with 10 additions and 7 deletions
17
blueprint.sh
17
blueprint.sh
|
@ -441,17 +441,20 @@ if [[ ( $2 == "-build" ) || ( $2 == "-test" ) ]]; then
|
||||||
sendTelemetry "BUILD_DEVELOPMENT_EXTENSION" > /dev/null;
|
sendTelemetry "BUILD_DEVELOPMENT_EXTENSION" > /dev/null;
|
||||||
fi;
|
fi;
|
||||||
|
|
||||||
|
# -export
|
||||||
if [[ $2 == "-export" ]]; then
|
if [[ $2 == "-export" ]]; then
|
||||||
log_yellow "[WARNING] This is an experimental feature, proceed with caution.";
|
log_yellow "[WARNING] This is an experimental feature, proceed with caution.";
|
||||||
log_bright "[INFO] Exporting extension files located in '.blueprint/.development'.";
|
log_bright "[INFO] Exporting extension files located in '.blueprint/.development'.";
|
||||||
|
|
||||||
cd .blueprint
|
cd .blueprint
|
||||||
eval $(parse_yaml .development/conf.yml)
|
eval $(parse_yaml .development/conf.yml); identifier=$info_identifier;
|
||||||
mkdir .storage/tmp/$info_identifier
|
cp -R .development/* .storage/tmp/;
|
||||||
mv .development/* .storage/tmp/$info_identifier/
|
cd .storage/tmp;
|
||||||
zip .storage/tmp/blueprint.zip .storage/tmp/$info_identifier
|
zip -r extension.zip *;
|
||||||
mv .storage/tmp/blueprint.zip ../$info_identifier.blueprint;
|
cd /var/www/$FOLDER;
|
||||||
|
cp .blueprint/.storage/tmp/extension.zip $identifier.blueprint;
|
||||||
|
rm -R .blueprint/.storage/tmp;
|
||||||
|
mkdir .blueprint/.storage/tmp;
|
||||||
log_bright "[INFO] Extension files should be exported into your Pterodactyl directory now.";
|
log_bright "[INFO] Extension files should be exported into your Pterodactyl directory now.";
|
||||||
fi;
|
fi;
|
||||||
|
|
||||||
|
@ -485,7 +488,7 @@ if [[ $2 == "-upgrade" ]]; then
|
||||||
else
|
else
|
||||||
bash tools/update.sh /var/www/$FOLDER
|
bash tools/update.sh /var/www/$FOLDER
|
||||||
fi;
|
fi;
|
||||||
rm -R tools/tmp/main;
|
rm -R tools/tmp/*;
|
||||||
log_bright "[INFO] Files have been upgraded, running installation script..";
|
log_bright "[INFO] Files have been upgraded, running installation script..";
|
||||||
chmod +x blueprint.sh;
|
chmod +x blueprint.sh;
|
||||||
bash blueprint.sh --post-upgrade;
|
bash blueprint.sh --post-upgrade;
|
||||||
|
|
Loading…
Reference in a new issue