Akt is a project mainly written in PHP and SHELL, based on the BSD-3-Clause license.
Automation tool written in php with php syntax
Akt is a small and flexible automatization tool written in php with php syntax.
Yep, you're absolutely right. Another automatization tool.
There are a lot of such scripts written in different languages for different platforms.
And here is another one...
I have tried some of similar tools:
Ant - great, powerful, popular, but java and xml
Phing - ant clone in php, therefore we have the same xml syntax
Make - no comments
Rake - this is in ruby...
Capistrano - this is in ruby...
Fabric - this is in python...
I don't really know. Yeah, i have reviewed pake, phake, weploy, phpdeploy and more more more
Good tools, good job guys. But this is not what I really need.
So this is my attempt to make perfect php automatization tool... :)
Let's go!
$buildDir = '/home/build/production/';
$devDir = '/home/dev/site/';
function task_default()
{
depends('clean', 'copySource');
task('minify', array('path' => $buildDir));
$production = new Connection('ssh', array(
'host' => 'production.com',
'username' => 'root'
));
$production->sync('/home/site/', $buildDir);
}
function task_clean()
{
dir::recreate($buildDir);
}
function task_copySource()
{
$source = new Fileset($devDir);
$source->include('**');
$source->exclude('**/.git/**');
$source->copy($buildDir);
}
class MinifyTask extends Akt_Task
{
public function execute()
{
// Minify operations here...
$phpFiles = new Fileset($buildDir);
$phpFiles->include('**/*.php');
task('strip_php_comments', $phpFiles);
}
}