代码拉取完成,页面将自动刷新
#!/usr/bin/env php
<?php
// 禁止非 cli 方式运行
if ('cli' !== \PHP_SAPI)
{
exit('are you ok?');
}
$fileName = __DIR__ . '/vendor/autoload.php';
if (is_file($fileName))
{
require_once $fileName;
}
else
{
$fileName = $_SERVER['PWD'] . '/vendor/autoload.php';
if (is_file($fileName))
{
require_once $fileName;
}
}
use Yurun\MdDoc\Args;
use Yurun\MdDoc\Builder;
Args::init();
$markdownPath = Args::get('markdownPath');
if (null === $markdownPath)
{
exit('-markdownPath can not be null');
}
$htmlPath = Args::get('htmlPath');
if (null === $htmlPath)
{
exit('-htmlPath can not be null');
}
$builder = new Builder($markdownPath, $htmlPath);
$templatePath = Args::get('templatePath');
if (null !== $templatePath)
{
$builder->templatePath = $templatePath;
}
$builder->build();
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。