Show current version for a brief moment on /extensions/blueprint
This commit is contained in:
parent
bf37806570
commit
01188912c6
2 changed files with 6 additions and 3 deletions
|
@ -18,12 +18,14 @@ fi;
|
|||
if [[ -d "/var/www/$FOLDER/blueprint" ]]; then mv /var/www/$FOLDER/blueprint /var/www/$FOLDER/.blueprint; fi;
|
||||
|
||||
# BUILT_FROM_SOURCE="y"; # If you downloaded Blueprint from a release instead of building it, this should be "n".
|
||||
if [[ $BUILT_FROM_SOURCE == "y" ]]; then if [[ ! -f "/var/www/$FOLDER/.blueprint/.storage/versionschemefix.flag" ]]; then sed -E -i "s*&bp.version&*source*g" app/Services/Helpers/BlueprintPlaceholderService.php;touch /var/www/$FOLDER/.blueprint/.storage/versionschemefix.flag;fi;VERSION="source";
|
||||
# if [[ $BUILT_FROM_SOURCE == "y" ]]; then if [[ ! -f "/var/www/$FOLDER/.blueprint/.storage/versionschemefix.flag" ]]; then sed -E -i "s*&bp.version&*source*g" app/Services/Helpers/BlueprintPlaceholderService.php;touch /var/www/$FOLDER/.blueprint/.storage/versionschemefix.flag;fi;VERSION="source";
|
||||
|
||||
elif [[ $PM_VERSION == "([(pterodactylmarket""_version)])" ]]; then
|
||||
# This runs when the placeholder has not changed, indicating an issue with PterodactylMarket
|
||||
# or Blueprint being installed from other sources.
|
||||
if [[ ! -f "/var/www/$FOLDER/.blueprint/.storage/versionschemefix.flag" ]]; then
|
||||
sed -E -i "s*&bp.version&*$VER_FALLBACK*g" app/Services/Helpers/BlueprintPlaceholderService.php;
|
||||
sed -E -i "s*@version*$VER_FALLBACK*g" public/extensions/blueprint/index.html;
|
||||
touch /var/www/$FOLDER/.blueprint/.storage/versionschemefix.flag;
|
||||
fi;
|
||||
|
||||
|
@ -33,6 +35,7 @@ elif [[ $PM_VERSION != "([(pterodactylmarket""_version)])" ]]; then
|
|||
# fallback version.
|
||||
if [[ ! -f "/var/www/$FOLDER/.blueprint/.storage/versionschemefix.flag" ]]; then
|
||||
sed -E -i "s*&bp.version&*$PM_VERSION*g" app/Services/Helpers/BlueprintPlaceholderService.php;
|
||||
sed -E -i "s*@version*$PM_VERSION*g" public/extensions/blueprint/index.html;
|
||||
touch /var/www/$FOLDER/.blueprint/.storage/versionschemefix.flag;
|
||||
fi;
|
||||
|
||||
|
|
|
@ -2,5 +2,5 @@
|
|||
<meta http-equiv="refresh" content="0; url=https://ptero.shop/" />
|
||||
</head>
|
||||
<body>
|
||||
<p>◆</p>
|
||||
</body>
|
||||
<p>@version</p>
|
||||
</body>
|
||||
|
|
Loading…
Reference in a new issue