Skip to content

Latest commit

 

History

History
54 lines (34 loc) · 2.26 KB

CONTRIBUTING.md

File metadata and controls

54 lines (34 loc) · 2.26 KB

How to contribute

Contributing to AsgardCMS is fairly straitforward. The easiest way is listed below.

Please note AsgardCMS follows PSR-1 and PSR-2. Please make sure your code follows those standards.

You can use a great tool : PHP-CS-Fixer to make sure everything is following the correct coding style.

Install it globally and run it against the Modules/ directory using php-cs-fixer fix Modules/ --verbose. Or run it individually for one module only, whichever you prefer.

Getting setup

Modules

  • Have an installation of AsgardCMS/Platform
  • Remove .git/ directory
  • Remove all modules from composer.json file
  • cd into the Modules/ folder and clone each Module individually
  • Install AsgardCMS as usual php artisan asgard:install

Themes

This is the same as modules except cd-ing into the Themes/ folder and cloning desired themes in there.

Making changes

Once you have your copy of AsgardCMS installed and configured for contributing purposes, you're ready to make changes.

AsgardCMS follows a workflow similar to Git Flow branching model.

This means:

  • For a new feature:
    • Create a branch feature/your-new-feature-name
    • Add you changes
    • Make sure the test suite for the module still passes
    • Squash commits if necessary to create a nice history
    • Send a pull request to the develop branch of the module/theme your modifying
  • For a hotfix:
    • Create a branch hotfix/your-hotfix-name
    • Add a failing test that reproduces the found bug
    • Add you changes by making the test pass
    • Squash commits if necessary to create a nice history
    • Send a pull request to the develop branch of the module/theme your modifying

Additional Resources