Skip to content
Greg Bowler edited this page Feb 28, 2019 · 13 revisions

The PHP.Gt command line interface makes it easy to perform common tasks when starting new projects or deploying them to servers.

All commands are made through the gt command:

  • gt create ProjectDirectory Namespace [Blueprint] - create a new application in the ProjectDirectory directory, using the Namespace provided, based on the optional blueprint. Default blueprint is "Hello-World".
  • gt run - serve the application and run a build watcher on client side files. This command is a combination of gt serve and gt build. Configured through config.ini.
  • gt test [--type UNIT|ACCEPTANCE] - run all unit/acceptance tests, returning with an exit code of 0 on success.
  • gt serve [--port PORT] - serve the application. Default port is 8080.
  • gt build [--watch] - build the client side assets, optionally watching the directory. Configured through build.json.
  • gt cron [--watch] - start any scripts that are scheduled to run now, or keep the script running once per minute using the --watch flag. Configured through [crontab](cron tasks).

Commands that are planned for future release:

  • gt deploy ENVIRONMENT - deploy code to the specified environment, as configured through config.ini.
  • gt auth - setup new authentication tokens.
  • gt cms URL - link to a content management system.
Clone this wiki locally