friendica / dir

Friendica Global Directory

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Update Version Check, including partical automation

AndyHee opened this issue · comments

Version check in site-health.php needs some attention. Does it work with the new style i.e. 2018-05-dev?

Everything that's not 3.6 or above should be "Somewhat outdated". Capping for deprecated versions should be versions less than 3.3.x (that's code older than four years that had undergone major changes!).

It would be nice to automate the process for "Somewhat outdated" comparing it against the version file of the master branch.

	//Version check.
	if (!empty($version)) {
		$versionParts = explode('.', $version);
		//Older than 3.3.x?
		//Your score can not go above 30 health.
		if (intval($versionParts[1]) < 3) {
			$current = min($current, 30);
		}
		//Older than 3.6.x?
		elseif (intval($versionParts[1] < 6)) {
			$current -= 5; //Somewhat outdated.
		}
		#TODO: See if this needs to be more dynamic.
		#TODO: See if this is a proper indicator of health.
	}

It's already taken care of in MrPetovan/dir:master:
https://github.com/MrPetovan/dir/blob/95ea839fa7f70e34afc667eee1d25e011c676740/include/site-health.php#L332-L349

I'm waiting for conclusive results from the ping adds to merge against friendica/dir.

Duplicate of #13, taken care of in the next version of the directory.