Full update with new build tool.

This commit is contained in:
Dayle Rees 2014-02-12 21:14:07 +00:00
parent 9bdfe0bf80
commit 48a64fc580
94 changed files with 26 additions and 57 deletions

@ -15,13 +15,6 @@
<!-- Generate themes. -->
<target name="generate" depends="clean">
<exec dir="${basedir}/build" executable="php" failonerror="true">
<arg line="schemes.php"></arg>
</exec>
</target>
<!-- Generate themes. -->
<target name="generate-new" depends="clean">
<exec dir="${basedir}/build/core" executable="php" failonerror="true">
<arg line="run.php raincolour --ansi"></arg>
</exec>

@ -151,6 +151,13 @@ class Presenter
return call_user_func_array([$this->theme, 'first'], $params);
}
/**
* Twig helper for sublime theme RGB values.
*
* @param string $key
* @param integer $amount
* @return string
*/
public function uiHelper($key, $amount = 0)
{
$r = $this->minMax($this->theme->get($key.'_r') + $amount);
@ -160,6 +167,12 @@ class Presenter
return "[{$r}, {$g}, {$b}]";
}
/**
* Helper to ensure RGB values don't wrap.
*
* @param int $value
* @return int
*/
public function minMax($value)
{
if ($value > 255) {

@ -4,8 +4,18 @@ namespace Raincolour\DataTransformers;
class RgbTransformer implements TransformerInterface
{
/**
* Transform theme data.
*
* @param array $data
* @return array
*/
public function transform($data)
{
// All transformers are in here right now.
// Will split them up soon.
// Iterate data.
foreach ($data as $key => $value) {
@ -38,12 +48,15 @@ class RgbTransformer implements TransformerInterface
}
// Set the UI background if it isn't present.
if(!isset($data['ui_bg'])) {
$data['ui_bg'] = $data['background'];
}
// Set the current year for copyrights.
$data['year'] = date('Y');
// Create a UUID for the sublime text themes.
$md5 = md5($data['theme']['name']);
$md5 = substr_replace($md5, '-', 20, 0);
$md5 = substr_replace($md5, '-', 16, 0);

@ -1,10 +0,0 @@
<?php
namespace Raincolor\Exceptions;
use Exception;
class DirectoryNotFoundException extends Exception
{
}

@ -1,10 +0,0 @@
<?php
namespace Raincolor\Exceptions;
use Exception;
class ExtensionNotFoundException extends Exception
{
}

@ -1,10 +0,0 @@
<?php
namespace Raincolor\Exceptions;
use Exception;
class TemplateNotFoundException extends Exception
{
}

@ -1,10 +0,0 @@
<?php
namespace Raincolor\Exceptions;
use Exception;
class TitleNotFoundException extends Exception
{
}

@ -1,10 +0,0 @@
<?php
namespace Raincolor\Exceptions;
use Exception;
class TypeNotFoundException extends Exception
{
}

BIN
screenshots/arstotzka.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

BIN
screenshots/azure.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

BIN
screenshots/bold.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 79 KiB

BIN
screenshots/boxuk.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 84 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

BIN
screenshots/carbonight.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

BIN
screenshots/chocolate.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 84 KiB

BIN
screenshots/crisp.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

BIN
screenshots/darkside.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 81 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 90 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

BIN
screenshots/earthsong.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 86 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 86 KiB

BIN
screenshots/freshcut.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 85 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

BIN
screenshots/frontier.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

BIN
screenshots/github.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 81 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 86 KiB

BIN
screenshots/gloom.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 85 KiB

BIN
screenshots/glowfish.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 81 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 88 KiB

BIN
screenshots/goldfish.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 83 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 88 KiB

BIN
screenshots/grunge.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 83 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 84 KiB

BIN
screenshots/halflife.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 78 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

BIN
screenshots/hyrule.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 89 KiB

BIN
screenshots/iceberg.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

BIN
screenshots/juicy.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 84 KiB

BIN
screenshots/keen.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

BIN
screenshots/kiwi.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 79 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 85 KiB

BIN
screenshots/laravel.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 89 KiB

BIN
screenshots/lavender.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 84 KiB

BIN
screenshots/legacy.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 88 KiB

BIN
screenshots/mellow.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 83 KiB

BIN
screenshots/mintchoc.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 81 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 84 KiB

BIN
screenshots/mud.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 84 KiB

BIN
screenshots/otakon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 85 KiB

BIN
screenshots/pastel.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 79 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 86 KiB

BIN
screenshots/patriot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 81 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

BIN
screenshots/peacock.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 85 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

BIN
screenshots/peel.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

BIN
screenshots/piggy.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

BIN
screenshots/potpourri.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 83 KiB

BIN
screenshots/rainbow.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 84 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 89 KiB

BIN
screenshots/revelation.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 85 KiB

BIN
screenshots/shrek.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

BIN
screenshots/slate.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

BIN
screenshots/slime.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 84 KiB

BIN
screenshots/snappy.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

BIN
screenshots/solarflare.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 84 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 88 KiB

BIN
screenshots/sourlick.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 83 KiB

BIN
screenshots/spearmint.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 85 KiB

BIN
screenshots/stark.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

BIN
screenshots/super.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

BIN
screenshots/tonic.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 79 KiB

BIN
screenshots/tribal.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 84 KiB

BIN
screenshots/tron.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 81 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 89 KiB

BIN
screenshots/turnip.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 84 KiB

BIN
screenshots/userscape.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

BIN
screenshots/yule.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

BIN
screenshots/zacks.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 83 KiB