Working on October CMS forks 🍴

In TIL 1 minute 31-03-2021

When using October CMS in combination with Composer, it's easy to work on forks. You can just install clone the repo you want to work on. Checkout a new branch makes it easier when working on multiple features in one repo.

Setup the repo in your project

The composer.json file is the heart of your project. It tells composer what to install. To install the fork in your project, you should add a new repository referencing to the fork you are using.

The best way to do this is to create a repository with the path type. See the example below.

"repositories": [
        "type": "path",
        "url": "~/Developer/Forks/user-plugin"

The only thing that's left to do is to link to the branch you created. See example below.

"require": {
    "rainlab/user-plugin": "dev-feature/add-missing-fields"

Now the fork will be symlinked to the right location in your project.

Sebastiaan Kloos

Hi! I'm the founder and lead programmer of Codecycler. Reach out to me if you have any questions about the article. We're happy to help.