diff options
author | mattab <matthieu.aubry@gmail.com> | 2013-11-18 14:52:47 +0400 |
---|---|---|
committer | mattab <matthieu.aubry@gmail.com> | 2013-11-18 14:52:47 +0400 |
commit | 23208b79bf25f2c0ce065953c62f155c3b96ad7e (patch) | |
tree | 1b9ffb4eb4b1f930dfd652d944ad3698a2ebf8ae /core/Filechecks.php | |
parent | 97974b06269734b186bca7f894adf4948347709b (diff) |
Error messages friendly to CLI output (no html, spaces displayed correctly...). Factoring out class CronArchive from archive.php.
Diffstat (limited to 'core/Filechecks.php')
-rw-r--r-- | core/Filechecks.php | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/core/Filechecks.php b/core/Filechecks.php index 0ab5e79334..69fe7a412a 100644 --- a/core/Filechecks.php +++ b/core/Filechecks.php @@ -87,12 +87,13 @@ class Filechecks // Also give the chown since the chmod is only 755 if (!SettingsServer::isWindows()) { $realpath = Filesystem::realpath(PIWIK_INCLUDE_PATH . '/'); - $directoryList = "<code>chown -R www-data:www-data " . $realpath . "</code><br/>" . $directoryList; + $directoryList = "<code>chown -R www-data:www-data " . $realpath . "</code><br />" . $directoryList; } // The error message mentions chmod 777 in case users can't chown - $directoryMessage = "<p><b>Piwik couldn't write to some directories</b>.</p> - <p>Try to Execute the following commands on your server, to allow Write access on these directories:</p>" + + $directoryMessage = "<p><b>Piwik couldn't write to some directories</b>.</p>"; + $directoryMessage .= "<p>Try to Execute the following commands on your server, to allow Write access on these directories:</p>" . "<blockquote>$directoryList</blockquote>" . "<p>If this doesn't work, you can try to create the directories with your FTP software, and set the CHMOD to 0755 (or 0777 if 0755 is not enough). To do so with your FTP software, right click on the directories then click permissions.</p>" . "<p>After applying the modifications, you can <a href='index.php'>refresh the page</a>.</p>" @@ -117,7 +118,10 @@ class Filechecks } if (!class_exists('\\Piwik\\Manifest')) { - $messages[] = Piwik::translate('General_WarningFileIntegrityNoManifest') . " If you are deploying Piwik from Git, this message is normal."; + $git = SettingsPiwik::getCurrentGitBranch(); + if(empty($git)) { + $messages[] = Piwik::translate('General_WarningFileIntegrityNoManifest') . " If you are deploying Piwik from Git, this message is normal."; + } return $messages; } |