2016-11-02 15:11:30 -04:00
|
|
|
<?php
|
|
|
|
|
/**
|
2024-05-10 09:09:14 -04:00
|
|
|
* SPDX-FileCopyrightText: 2016 Nextcloud GmbH and Nextcloud contributors
|
|
|
|
|
* SPDX-License-Identifier: AGPL-3.0-or-later
|
2016-11-02 15:11:30 -04:00
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Script to check that the main .htaccess file doesn't include some automated
|
|
|
|
|
* changes done by Nextcloud.
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
$htaccess = file_get_contents(__DIR__ . '/../.htaccess');
|
2020-04-10 08:19:56 -04:00
|
|
|
if (strpos($htaccess, 'DO NOT CHANGE ANYTHING') !== false) {
|
2016-11-02 15:11:30 -04:00
|
|
|
echo(".htaccess file has invalid changes!\n");
|
|
|
|
|
exit(1);
|
|
|
|
|
} else {
|
|
|
|
|
exit(0);
|
|
|
|
|
}
|