Adding a new feature

Adding a new feature to GreenLight is always welcome when the feature itself is considered to be useful for other projects as well. While developing something new, it is recommended to keep the following in mind:

  • Both Devkit and GreenLight use semver, make sure you add features based on the principles it introduces
  • Follow the Git workflow applied by Greenroom while working on the Devkit
  • New features should be approved and released by a GreenLight author to make sure we have a consistent release plan and codebase
  • Laravel comes with a minimum stability of "stable" requirement defined in composer, therefore if you want to test your feature in the same environment that you expect it to work in after release, you have to create a beta release that you can test and discard later (optional, you could keep those releases, however if everything goes well, its content should be identical to the live release, which makes it pointless to keep the beta one)
  • Devkit and GreenLight should have the same version numbers due to their history, keep them synchronized

Adding new functionality to GreenLight should be similar to this:

  1. Code a new feature in the Devkit (feature branch)
  2. Make sure it is tested and works properly in the Devkit environment
  3. Commit and push to Devkit (feature branch)
  4. Commit and push to GreenLight (feature branch)
  5. Create a beta release in GreenLight (from the feature branch)
  6. Test the beta release in a separate Laravel instance (same as the Installation process, with the difference of requiring your beta release, for example: composer require greenroom/greenlight:1.10.2-beta)
  7. If everything works as intended, create a Pull Request in both Devkit and GreenLight
  8. Get approved by a GreenLight author (could include a code review if necessary)
  9. Merge the PR to master in both Devkit and GreenLight (could be done by a code reviewer)
  10. Create a release in Devkit
  11. Create a release in GreenLight (including docs)
  12. Remove the beta release (optional)
  13. Remove the feature branches in both Devkit and GreenLight