Update Robo from 0.7.2 to 1.0.5
This commit is contained in:
39
RoboFile.php
39
RoboFile.php
@ -68,9 +68,9 @@ class RoboFile extends \Robo\Tasks {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function compileAll() {
|
function compileAll() {
|
||||||
$collection = $this->collection();
|
$collection = $this->collectionBuilder();
|
||||||
$collection->add(array($this, 'compileJs'));
|
$collection->addCode(array($this, 'compileJs'));
|
||||||
$collection->add(array($this, 'compileCss'));
|
$collection->addCode(array($this, 'compileCss'));
|
||||||
return $collection->run();
|
return $collection->run();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -164,9 +164,9 @@ class RoboFile extends \Robo\Tasks {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function qa() {
|
function qa() {
|
||||||
$collection = $this->collection();
|
$collection = $this->collectionBuilder();
|
||||||
$collection->add(array($this, 'qaLint'));
|
$collection->addCode(array($this, 'qaLint'));
|
||||||
$collection->add(function() {
|
$collection->addCode(function() {
|
||||||
return $this->qaCodeSniffer('all');
|
return $this->qaCodeSniffer('all');
|
||||||
});
|
});
|
||||||
return $collection->run();
|
return $collection->run();
|
||||||
@ -219,42 +219,38 @@ class RoboFile extends \Robo\Tasks {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
$collection = $this->collection();
|
$collection = $this->collectionBuilder();
|
||||||
|
|
||||||
// Clean up tmp dirs if the previous run was halted
|
// Clean up tmp dirs if the previous run was halted
|
||||||
if(file_exists("$svn_dir/trunk_new") || file_exists("$svn_dir/trunk_old")) {
|
if(file_exists("$svn_dir/trunk_new") || file_exists("$svn_dir/trunk_old")) {
|
||||||
$this->taskFileSystemStack()
|
$collection->taskFileSystemStack()
|
||||||
->stopOnFail()
|
->stopOnFail()
|
||||||
->remove(array("$svn_dir/trunk_new", "$svn_dir/trunk_old"))
|
->remove(array("$svn_dir/trunk_new", "$svn_dir/trunk_old"));
|
||||||
->addToCollection($collection);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Extract the distributable zip to tmp trunk dir
|
// Extract the distributable zip to tmp trunk dir
|
||||||
$this->taskExtract($plugin_dist_file)
|
$collection->taskExtract($plugin_dist_file)
|
||||||
->to("$svn_dir/trunk_new")
|
->to("$svn_dir/trunk_new")
|
||||||
->preserveTopDirectory(false)
|
->preserveTopDirectory(false);
|
||||||
->addToCollection($collection);
|
|
||||||
|
|
||||||
// Rename current trunk
|
// Rename current trunk
|
||||||
if(file_exists("$svn_dir/trunk")) {
|
if(file_exists("$svn_dir/trunk")) {
|
||||||
$this->taskFileSystemStack()
|
$collection->taskFileSystemStack()
|
||||||
->rename("$svn_dir/trunk", "$svn_dir/trunk_old")
|
->rename("$svn_dir/trunk", "$svn_dir/trunk_old");
|
||||||
->addToCollection($collection);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Replace old trunk with a new one
|
// Replace old trunk with a new one
|
||||||
$this->taskFileSystemStack()
|
$collection->taskFileSystemStack()
|
||||||
->stopOnFail()
|
->stopOnFail()
|
||||||
->rename("$svn_dir/trunk_new", "$svn_dir/trunk")
|
->rename("$svn_dir/trunk_new", "$svn_dir/trunk")
|
||||||
->remove("$svn_dir/trunk_old")
|
->remove("$svn_dir/trunk_old");
|
||||||
->addToCollection($collection);
|
|
||||||
|
|
||||||
// Windows compatibility
|
// Windows compatibility
|
||||||
$awkCmd = '{print " --force \""$2"\""}';
|
$awkCmd = '{print " --force \""$2"\""}';
|
||||||
// Mac OS X compatibility
|
// Mac OS X compatibility
|
||||||
$xargsFlag = (stripos(PHP_OS, 'Darwin') !== false) ? '' : '-r';
|
$xargsFlag = (stripos(PHP_OS, 'Darwin') !== false) ? '' : '-r';
|
||||||
|
|
||||||
$this->taskExecStack()
|
$collection->taskExecStack()
|
||||||
->stopOnFail()
|
->stopOnFail()
|
||||||
// Set SVN repo as working directory
|
// Set SVN repo as working directory
|
||||||
->dir($svn_dir)
|
->dir($svn_dir)
|
||||||
@ -263,8 +259,7 @@ class RoboFile extends \Robo\Tasks {
|
|||||||
// Recursively add files to SVN that haven't been added yet
|
// Recursively add files to SVN that haven't been added yet
|
||||||
->exec("svn add --force * --auto-props --parents --depth infinity -q")
|
->exec("svn add --force * --auto-props --parents --depth infinity -q")
|
||||||
// Tag the release
|
// Tag the release
|
||||||
->exec("svn cp trunk tags/$plugin_version")
|
->exec("svn cp trunk tags/$plugin_version");
|
||||||
->addToCollection($collection);
|
|
||||||
|
|
||||||
$result = $collection->run();
|
$result = $collection->run();
|
||||||
|
|
||||||
|
@ -20,7 +20,8 @@
|
|||||||
"require-dev": {
|
"require-dev": {
|
||||||
"codeception/codeception": "*",
|
"codeception/codeception": "*",
|
||||||
"codeception/verify": "*",
|
"codeception/verify": "*",
|
||||||
"codegyre/robo": "*",
|
"consolidation/robo": "*",
|
||||||
|
"henrikbjorn/lurker": "^1.2",
|
||||||
"vlucas/phpdotenv": "*",
|
"vlucas/phpdotenv": "*",
|
||||||
"umpirsky/twig-gettext-extractor": "1.1.*",
|
"umpirsky/twig-gettext-extractor": "1.1.*",
|
||||||
"raveren/kint": "^1.0",
|
"raveren/kint": "^1.0",
|
||||||
|
627
composer.lock
generated
627
composer.lock
generated
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user