mirror of
https://github.com/danpros/htmly.git
synced 2026-04-20 12:36:23 +05:30
Remove unneeded files
This commit is contained in:
parent
06b4e9a630
commit
8a7559e44b
3 changed files with 0 additions and 48 deletions
|
|
@ -1,7 +1,6 @@
|
||||||
<h3>Updated to<h3>
|
<h3>Updated to<h3>
|
||||||
<h2>[<?php echo $info['tag_name']; ?>] <?php echo $info['name']; ?></h2>
|
<h2>[<?php echo $info['tag_name']; ?>] <?php echo $info['name']; ?></h2>
|
||||||
<p><?php echo \Michelf\MarkdownExtra::defaultTransform($info['body']); ?></p>
|
<p><?php echo \Michelf\MarkdownExtra::defaultTransform($info['body']); ?></p>
|
||||||
<?php require_once "system/upgrade/run.php"; ?>
|
|
||||||
<?php
|
<?php
|
||||||
if (file_exists('install.php')) {
|
if (file_exists('install.php')) {
|
||||||
unlink('install.php');
|
unlink('install.php');
|
||||||
|
|
|
||||||
|
|
@ -1,5 +0,0 @@
|
||||||
<?php
|
|
||||||
define('HTMLY', true);
|
|
||||||
$config_file = 'config/config.ini';
|
|
||||||
require 'system/vendor/autoload.php';
|
|
||||||
require 'system/htmly.php';
|
|
||||||
|
|
@ -1,42 +0,0 @@
|
||||||
<?php
|
|
||||||
config('source', 'config/config.ini');
|
|
||||||
|
|
||||||
$updater = new Kanti\HubUpdater("danpros/htmly");
|
|
||||||
$info = $updater->getCurrentInfo();
|
|
||||||
$versionNumber = substr($info['tag_name'], 1);
|
|
||||||
|
|
||||||
function isGraterThan($string)
|
|
||||||
{
|
|
||||||
global $versionNumber;
|
|
||||||
return (version_compare($versionNumber, $string) > 0);
|
|
||||||
}
|
|
||||||
|
|
||||||
// http://stackoverflow.com/questions/3338123/how-do-i-recursively-delete-a-directory-and-its-entire-contents-files-sub-dir
|
|
||||||
function rrmdir($dir)
|
|
||||||
{
|
|
||||||
if (is_dir($dir)) {
|
|
||||||
$objects = scandir($dir);
|
|
||||||
foreach ($objects as $object) {
|
|
||||||
if ($object != "." && $object != "..") {
|
|
||||||
if (filetype($dir . "/" . $object) == "dir") rrmdir($dir . "/" . $object); else unlink($dir . "/" . $object);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
reset($objects);
|
|
||||||
rmdir($dir);
|
|
||||||
} else if (is_file($dir)) {
|
|
||||||
unlink($dir);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
//run upgrade specific stuff
|
|
||||||
if (isGraterThan("2.3")) {// 2.4, 2.5, ...
|
|
||||||
if (file_exists("vendor/")) {
|
|
||||||
rrmdir("vendor/");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
if (!config("dev")) {
|
|
||||||
file_put_contents("index.php", file_get_contents("system/upgrade/index.php"));
|
|
||||||
rrmdir("system/upgrade/");
|
|
||||||
}
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue