RoboFile.php 810 B

1234567891011121314151617181920212223242526272829303132
  1. <?php
  2. /**
  3. * This is project's console commands configuration for Robo task runner.
  4. *
  5. * @see http://robo.li/
  6. */
  7. class RoboFile extends \Robo\Tasks
  8. {
  9. /**
  10. * Publishes new Verify release
  11. * @param null $newVer
  12. */
  13. public function release($newVer = null)
  14. {
  15. if ($newVer) {
  16. $this->say("version updated to $newVer");
  17. $this->taskWriteToFile(__DIR__.'/VERSION')
  18. ->line($newVer)
  19. ->run();
  20. }
  21. $version = trim(file_get_contents(__DIR__.'/VERSION'));
  22. $this->taskGitStack()
  23. ->tag($version)
  24. ->push('origin','master --tags')
  25. ->run();
  26. $this->taskGitHubRelease($version)
  27. ->uri('Codeception/Verify')
  28. ->askForChanges()
  29. ->run();
  30. }
  31. }