public function testStaticFileWriter()
 {
     try {
         FileSystem::getFileWriter(__DIR__);
     } catch (\Exception $E) {
         $this->assertInstanceOf('MOC\\V\\Core\\FileSystem\\Component\\Exception\\Repository\\TypeFileException', $E);
     }
     try {
         FileSystem::getFileWriter(__FILE__);
     } catch (\Exception $E) {
     }
 }
Esempio n. 2
0
 /**
  * @param string                $Project
  * @param string                $Title
  * @param DirectoryParameter    $Source
  * @param DirectoryParameter    $Destination
  * @param null|ExcludeParameter $Exclude
  */
 public function __construct($Project, $Title, DirectoryParameter $Source, DirectoryParameter $Destination, ExcludeParameter $Exclude = null)
 {
     AutoLoader::getNamespaceAutoLoader('ApiGen', __DIR__ . '/../../../Vendor/ApiGen');
     AutoLoader::getNamespaceAutoLoader('TokenReflection', __DIR__ . '/../../../Vendor/ApiGen/libs/TokenReflection');
     AutoLoader::getNamespaceAutoLoader('FSHL', __DIR__ . '/../../../Vendor/ApiGen/libs/FSHL');
     $this->Project = $Project;
     $this->Title = $Title;
     $this->Source = $Source;
     $this->Destination = $Destination;
     $this->Exclude = $Exclude;
     set_time_limit(0);
     $Config = $this->getConfig();
     require_once __DIR__ . '/../../../Vendor/ApiGen/libs/Nette/Nette/loader.php';
     $Neon = new NeonAdapter();
     $File = FileSystem::getFileWriter(__DIR__ . '/ApiGen.config');
     file_put_contents($File->getLocation(), $Neon->dump($Config));
     $_SERVER['argv'] = array('DUMMY-SHELL-ARGS', '--config', $File->getLocation());
     include __DIR__ . '/../../../Vendor/ApiGen/apigen.php';
 }
Esempio n. 3
0
//$Less->parse( '@breadcrumb-color: @link-color;' );
//$Less->parse( '@breadcrumb-active-color: @link-hover-color;' );
//$Less->parse( '@breadcrumb-padding-vertical: 2px;' );
//$Less->parse( '@breadcrumb-padding-horizontal: 0;' );
//
//$Less->parse( '@table-cell-padding: 6px;' );
//$Less->parse( '@table-condensed-cell-padding: 5px;' );
// Panel
$Less->parse('@panel-heading-padding: 7px 10px;');
$Less->parse('@panel-body-padding: 5px 10px;');
// Thumbnail
$Less->parse('@thumbnail-padding: 6px;');
$Less->parse('@thumbnail-caption-padding: 9px;');
//$Less->parse( '@thumbnail-border: @gray-dark;' );
//$Less->parse( '@thumbnail-border-radius: 0;' );
// Component
$Less->parse('@padding-base-vertical: 4px;');
$Less->parse('@padding-base-horizontal: 10px;');
$Less->parse('@padding-large-vertical: 8px;');
$Less->parse('@padding-large-horizontal: 14px;');
$Less->parse('@padding-small-vertical: 3px;');
$Less->parse('@padding-small-horizontal: 8px;');
$Less->parse('@padding-xs-vertical: 1px;');
$Less->parse('@padding-xs-horizontal: 3px;');
$Less->parse('@border-radius-base: 3px;');
$Less->parse('@border-radius-large: 5px;');
$Less->parse('@border-radius-small: 2px;');
$Less->parse('@form-group-margin-bottom: 10px;');
$Style = FileSystem::getFileWriter(__DIR__ . '/Bootstrap.css')->getLocation();
file_put_contents($Style, $Less->getCss());
(new Extension())->getDebugger()->screenDump($Less->AllParsedFiles());