ck 10 - automate all the things 2.0
TRANSCRIPT
github.com/marabesi
twitter.com/MatheusMarabesi
http://vmob.me/DE1Q16THT
HELP
US
Why should I use Phing ?
Build tool ?
“Build tools are programs that automate the creation of executable applications from source code. Building incorporates compiling, linking and packaging the code into a usable or executable form. In small projects, developers will often manually invoke the build process.”
https://www.techopedia.com/definition/16359/build-tool
“Build tools are programs that automate the creation of executable applications from source code.”
https://www.techopedia.com/definition/16359/build-tool
Why should I automate?
<?xml
PROPERTIES
phing build.xml -Drepodir=http://github.com
TARGETS
CORE TASKS
EchoTask
ChmodTaskChownTask
ExecTask
CopyTask
AppendTask
MoveTaskImportTask
OPTIONAL TASKS
GitCloneTask
ZipTask
TarTask
PhpLintTask
PHPUnitTask
PHPDocumentorTask
SvnCheckoutTask
1.
2.
3.
Extending Phing ?
<?php
require_once 'phing/Task.php';
class MarabesiTask{ private $message = null; private $project = null; public function setMessage($str) { $this->message = $str; }
public function init() {}
public function main() { print($this->message); } public function setProject($project) { $this->project = $project; }
}