This repository has been archived by the owner on Feb 6, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
bundle.stylesheet
- Loading branch information
elnebuloso
committed
Feb 5, 2015
1 parent
4e6a3bd
commit 09ba8f4
Showing
10 changed files
with
207 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
8.0.3 | ||
8.1.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
|
||
|
||
<project default="bundle:help"> | ||
|
||
|
||
<import file="${phing:commons:commons}/targets/bundle/javascript.xml" /> | ||
<import file="${phing:commons:commons}/targets/bundle/stylesheet.xml" /> | ||
|
||
|
||
<target name="bundle:help"> | ||
<echo message="Bundle Targets" /> | ||
<echo message="----------------------------------------------------------------------------------------------------" /> | ||
<echo message="bundle.javascript Bundle your Javascript Files" /> | ||
<echo message="bundle.stylesheet Bundle your Stylesheet Files" /> | ||
</target> | ||
|
||
|
||
</project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
|
||
|
||
<project default="bundle.javascript"> | ||
|
||
|
||
<target name="bundle.javascript:init" hidden="true"> | ||
<property name="bundle.javascript.enabled" value="no" /> | ||
</target> | ||
|
||
|
||
<target name="bundle.javascript:before" hidden="true"> | ||
<echo message="no actions defined" level="debug" /> | ||
</target> | ||
|
||
|
||
<target name="bundle.javascript:main" hidden="true"> | ||
<if> | ||
<istrue value="${bundle.javascript.enabled}" /> | ||
<then> | ||
<commons-bundle-javascript file="${project.root}/.bundler/javascript.php" /> | ||
</then> | ||
<else> | ||
<echo message="bundling of javascript disabled. enable by property bundle.javascript.enabled set to yes" /> | ||
</else> | ||
</if> | ||
</target> | ||
|
||
|
||
<target name="bundle.javascript:after" hidden="true"> | ||
<echo message="no actions defined" level="debug" /> | ||
</target> | ||
|
||
|
||
<target name="bundle.javascript" depends="bundle.javascript:init, bundle.javascript:before, bundle.javascript:main, bundle.javascript:after"> | ||
<echo message="successful" /> | ||
</target> | ||
|
||
|
||
<target name="bundle.javascript:help" depends="bundle.javascript:init"> | ||
<echo message="Property Value" /> | ||
<echo message="----------------------------------------------------------------------------------------------------" /> | ||
<echo message="bundle.javascript.enabled yes|no: ${bundle.javascript.enabled}" /> | ||
</target> | ||
|
||
|
||
</project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
|
||
|
||
<project default="bundle.stylesheet"> | ||
|
||
|
||
<target name="bundle.stylesheet:init" hidden="true"> | ||
<property name="bundle.stylesheet.enabled" value="no" /> | ||
</target> | ||
|
||
|
||
<target name="bundle.stylesheet:before" hidden="true"> | ||
<echo message="no actions defined" level="debug" /> | ||
</target> | ||
|
||
|
||
<target name="bundle.stylesheet:main" hidden="true"> | ||
<if> | ||
<istrue value="${bundle.stylesheet.enabled}" /> | ||
<then> | ||
<commons-bundle-stylesheet file="${project.root}/.bundler/stylesheet.php" /> | ||
</then> | ||
<else> | ||
<echo message="bundling of stylesheet disabled. enable by property bundle.stylesheet.enabled set to yes" /> | ||
</else> | ||
</if> | ||
</target> | ||
|
||
|
||
<target name="bundle.stylesheet:after" hidden="true"> | ||
<echo message="no actions defined" level="debug" /> | ||
</target> | ||
|
||
|
||
<target name="bundle.stylesheet" depends="bundle.stylesheet:init, bundle.stylesheet:before, bundle.stylesheet:main, bundle.stylesheet:after"> | ||
<echo message="successful" /> | ||
</target> | ||
|
||
|
||
<target name="bundle.stylesheet:help" depends="bundle.stylesheet:init"> | ||
<echo message="Property Value" /> | ||
<echo message="----------------------------------------------------------------------------------------------------" /> | ||
<echo message="bundle.stylesheet.enabled yes|no: ${bundle.stylesheet.enabled}" /> | ||
</target> | ||
|
||
|
||
</project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
<?php | ||
namespace Commons\Phing\Task\Bundle; | ||
|
||
use Bundler\JavascriptBundler; | ||
use Zend\Log\Logger; | ||
use Zend\Log\Writer\Stream as StreamWriter; | ||
|
||
/** | ||
* Class JavascriptBundlerTask | ||
* | ||
* @author Jeff Tunessen <jeff.tunessen@gmail.com> | ||
*/ | ||
class JavascriptBundlerTask extends \Task { | ||
|
||
/** | ||
* @var string | ||
*/ | ||
private $file; | ||
|
||
/** | ||
* @param string $file | ||
*/ | ||
public function setFile($file) { | ||
$this->file = $file; | ||
} | ||
|
||
/** | ||
* @throws \BuildException | ||
* @return void | ||
*/ | ||
public function main() { | ||
$writer = new StreamWriter('php://output'); | ||
$logger = new Logger(); | ||
$logger->addWriter($writer); | ||
|
||
$bundler = new JavascriptBundler($this->file); | ||
$bundler->getBundlerLogger()->setLogger($logger); | ||
$bundler->bundle(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
<?php | ||
namespace Commons\Phing\Task\Bundle; | ||
|
||
use Bundler\StylesheetBundler; | ||
use Zend\Log\Logger; | ||
use Zend\Log\Writer\Stream as StreamWriter; | ||
|
||
/** | ||
* Class StylesheetBundlerTask | ||
* | ||
* @author Jeff Tunessen <jeff.tunessen@gmail.com> | ||
*/ | ||
class StylesheetBundlerTask extends \Task { | ||
|
||
/** | ||
* @var string | ||
*/ | ||
private $file; | ||
|
||
/** | ||
* @param string $file | ||
*/ | ||
public function setFile($file) { | ||
$this->file = $file; | ||
} | ||
|
||
/** | ||
* @throws \BuildException | ||
* @return void | ||
*/ | ||
public function main() { | ||
$writer = new StreamWriter('php://output'); | ||
$logger = new Logger(); | ||
$logger->addWriter($writer); | ||
|
||
$bundler = new StylesheetBundler($this->file); | ||
$bundler->getBundlerLogger()->setLogger($logger); | ||
$bundler->bundle(); | ||
} | ||
} |