Updated extensions, winter remix
This commit is contained in:
parent
5fe04fd471
commit
75ab8fe6ad
4 changed files with 12 additions and 12 deletions
|
@ -2,7 +2,7 @@
|
|||
// Bundle extension, https://github.com/datenstrom/yellow-extensions/tree/master/source/bundle
|
||||
|
||||
class YellowBundle {
|
||||
const VERSION = "0.8.20";
|
||||
const VERSION = "0.8.21";
|
||||
public $yellow; // access to API
|
||||
|
||||
// Handle initialisation
|
||||
|
@ -177,7 +177,7 @@ class YellowBundle {
|
|||
public function isBundleRequired($fileName) {
|
||||
list($dummy, $fileNames, $modified) = $this->getBundleInformation($fileName);
|
||||
$idExpected = $idCurrent = $this->getBundleId($fileNames, $modified);
|
||||
if (preg_match("/^bundle-(.*)\.min/", $fileName, $matches)) $idCurrent = $matches[1];
|
||||
if (preg_match("/^bundle-(.*)\.min/", basename($fileName), $matches)) $idCurrent = $matches[1];
|
||||
return $idExpected==$idCurrent && !defined("DEBUG");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
# Datenstrom Yellow update settings
|
||||
|
||||
Extension: Bundle
|
||||
Version: 0.8.20
|
||||
Version: 0.8.21
|
||||
Description: Bundle website files.
|
||||
HelpUrl: https://github.com/datenstrom/yellow-extensions/tree/master/source/bundle
|
||||
DownloadUrl: https://github.com/datenstrom/yellow-extensions/raw/master/zip/bundle.zip
|
||||
Published: 2020-11-28 14:15:46
|
||||
Published: 2021-01-15 17:13:02
|
||||
Developer: Datenstrom
|
||||
Tag: feature
|
||||
system/extensions/bundle.php: bundle.php, create, update
|
||||
|
@ -89,11 +89,11 @@ system/themes/stockholm-opensans-light.woff: stockholm-opensans-light.woff, crea
|
|||
system/themes/stockholm-opensans-regular.woff: stockholm-opensans-regular.woff, create, update, careful
|
||||
|
||||
Extension: Update
|
||||
Version: 0.8.47
|
||||
Version: 0.8.48
|
||||
Description: Keep your website up to date.
|
||||
HelpUrl: https://github.com/datenstrom/yellow-extensions/tree/master/source/update
|
||||
DownloadUrl: https://github.com/datenstrom/yellow-extensions/raw/master/zip/update.zip
|
||||
Published: 2020-12-09 17:27:33
|
||||
Published: 2021-01-15 17:31:05
|
||||
Developer: Datenstrom
|
||||
Tag: feature
|
||||
system/extensions/update.php: update.php, create, update
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
// Update extension, https://github.com/datenstrom/yellow-extensions/tree/master/source/update
|
||||
|
||||
class YellowUpdate {
|
||||
const VERSION = "0.8.47";
|
||||
const VERSION = "0.8.48";
|
||||
const PRIORITY = "2";
|
||||
public $yellow; // access to API
|
||||
public $updates; // number of updates
|
||||
|
@ -16,7 +16,7 @@ class YellowUpdate {
|
|||
$this->yellow->system->setDefault("updateCurrentFile", "update-current.ini");
|
||||
$this->yellow->system->setDefault("updateCurrentRelease", "0");
|
||||
$this->yellow->system->setDefault("updateTrashTimeout", "7776660");
|
||||
$this->yellow->system->setDefault("updateTimestamp", "0");
|
||||
$this->yellow->system->setDefault("updateDailyTimestamp", "0");
|
||||
$this->yellow->system->setDefault("updateNotification", "none");
|
||||
}
|
||||
|
||||
|
@ -378,12 +378,12 @@ class YellowUpdate {
|
|||
$this->updateSystemSettings();
|
||||
$this->updateLanguageSettings();
|
||||
}
|
||||
if ($this->yellow->system->get("updateTimestamp")<=time()) {
|
||||
if ($this->yellow->system->get("updateDailyTimestamp")<=time()) {
|
||||
foreach ($this->yellow->extension->data as $key=>$value) {
|
||||
if (method_exists($value["object"], "onUpdate")) $value["object"]->onUpdate("daily");
|
||||
}
|
||||
$fileName = $this->yellow->system->get("coreExtensionDirectory").$this->yellow->system->get("coreSystemFile");
|
||||
if (!$this->yellow->system->save($fileName, array("updateTimestamp" => $this->getTimestampDaily()))) {
|
||||
if (!$this->yellow->system->save($fileName, array("updateDailyTimestamp" => $this->getDailyTimestamp()))) {
|
||||
$this->yellow->log("error", "Can't write file '$fileName'!");
|
||||
}
|
||||
}
|
||||
|
@ -835,7 +835,7 @@ class YellowUpdate {
|
|||
}
|
||||
|
||||
// Return time of next daily update
|
||||
public function getTimestampDaily() {
|
||||
public function getDailyTimestamp() {
|
||||
$timeOffset = 0;
|
||||
foreach (str_split($this->yellow->system->get("sitename")) as $char) {
|
||||
$timeOffset = ($timeOffset+ord($char)) % 60;
|
||||
|
|
|
@ -43,7 +43,7 @@ UpdateLatestFile: update-latest.ini
|
|||
UpdateCurrentFile: update-current.ini
|
||||
UpdateCurrentRelease: 0
|
||||
UpdateTrashTimeout: 7776660
|
||||
UpdateTimestamp: 0
|
||||
UpdateDailyTimestamp: 0
|
||||
UpdateNotification: none
|
||||
CommandStaticBuildDirectory: public/
|
||||
CommandStaticDefaultFile: index.html
|
||||
|
|
Loading…
Add table
Reference in a new issue