mirror of
https://github.com/torrentpier/torrentpier
synced 2025-08-22 06:13:58 -07:00
Update _release.php
This commit is contained in:
parent
90076497f3
commit
affb488587
1 changed files with 7 additions and 0 deletions
|
@ -57,15 +57,22 @@ if (empty($date)) {
|
|||
out("- Using date: $date", 'info');
|
||||
}
|
||||
|
||||
// Read config file content
|
||||
$content = file_get_contents($configFile);
|
||||
|
||||
// Update version
|
||||
$content = preg_replace(
|
||||
"/\\\$bb_cfg\['tp_version'\]\s*=\s*'[^']*';/",
|
||||
"\$bb_cfg['tp_version'] = '$version';",
|
||||
$content
|
||||
);
|
||||
|
||||
// Update release date
|
||||
$content = preg_replace(
|
||||
"/\\\$bb_cfg\['tp_release_date'\]\s*=\s*'[^']*';/",
|
||||
"\$bb_cfg['tp_release_date'] = '$date';",
|
||||
$content
|
||||
);
|
||||
|
||||
// Save updated config
|
||||
file_put_contents($configFile, $content);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue