getpiddir.php uses commandline.inc

This commit is contained in:
Evan Prodromou 2009-06-22 16:54:21 -07:00
parent 5b5da5154d
commit eced917d79

View File

@ -18,15 +18,13 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>. * along with this program. If not, see <http://www.gnu.org/licenses/>.
*/ */
# Abort if called from a web server
if (isset($_SERVER) && array_key_exists('REQUEST_METHOD', $_SERVER)) {
print "This script must be run from the command line\n";
exit();
}
define('INSTALLDIR', realpath(dirname(__FILE__) . '/..')); define('INSTALLDIR', realpath(dirname(__FILE__) . '/..'));
define('LACONICA', true);
require_once(INSTALLDIR . '/lib/common.php'); $helptext = <<<ENDOFHELP
getpiddir.php - print out the currently configured PID directory
echo common_config('daemon','piddir'); ENDOFHELP;
require_once INSTALLDIR.'/scripts/commandline.inc';
echo common_config('daemon', 'piddir');