Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
86 changes: 61 additions & 25 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,33 +1,62 @@
# 👋 Hey there, fellow contributor

> Thank you for being here and considering a contribution to WebifyCMS,
> and together we can make great software.
> Thank you for being here and considering a contribution to WebifyCMS!
> Together we can make great software.

## Let's Set Up for Development
---

## ⚖️ Developer Certificate of Origin (DCO)

To keep WebifyCMS open, secure, and legally clean, we use a **Developer Certificate of Origin (DCO)**
instead of a complex contributor agreement.

By contributing to this project, you certify that you have the right to submit the code
under the project's open-source license.

### How to Sign Your Work
All you need to do is sign off on your git commits.
You can do this automatically by adding the `-s` flag when you commit:

```bash
git commit -s -m "Your meaningful commit message"
```

This automatically appends a line to your commit message like this:
`Signed-off-by: Your Name <your.email@example.com>`

*Note: Pull Requests with unsigned commits cannot be merged. If you forget to sign a commit,
you can fix it using `git commit --amend -s` before pushing.*

---

## 🛠️ Let's Set Up for Development

### Prerequisites

* An environment that can run Docker or Docker Desktop. Please make sure you have installed one.
* An environment capable of running Docker or Docker Desktop.

### Installation
### 1. Installation

Use WebifyCMS [installer](https://github.com/webifycms/installer) package to install WebifyCMS.
Clone the main repository and use the [WebifyCMS Installer](https://github.com/webifycms/installer)
package to initialize the local stack setup.

### Create .env file
### 2. Environment Configuration

Navigate to your application `app` directory and copy the sample environment file:

```bash
cd app && cp .env.sample .env
```

> **NOTE:** The above command will create a `.env` file from the sample file provided
> in the project root and fill the values in the file according to your needs.
> And make sure the `APP_ENVIRONMENT` is set to 'development' and `APP_DEBUG`
> is set to `false`.
Open the newly created `.env` file and adjust the values for your local setup.
Ensure the environment variables are configured for local debugging:

* `APP_ENVIRONMENT='development'`
* `APP_DEBUG=true`

> **NOTE:** There are some other default values, and you can change them as needed.
> Add the configured `APP_BASE_URL` value to the host file.
Add your configured `APP_BASE_URL` value to your local system's host file if you are using a custom local domain.

At this point, the expected folder structure will be like this:
At this stage, your local folder structure should match this layout:

```
.
Expand All @@ -36,29 +65,36 @@ At this point, the expected folder structure will be like this:
│ ├── ...
│ ├── .env
│ ├── .env.sample
│ ├── composer.json
│ ├── composer.lock
│ ├── src/
│ ├── extensions/
│ ├── themes/
│ ├── vendor/
│ └── ...
├── extensions
│ ├── ext-base
├── themes
│ ├── theme-canvas
├── extensions/
│ └── ext-base/
└── themes/
└── theme-canvas/
```

### Install Dependencies
### 3. Install Dependencies

Switch to your working branches inside the `app` and `extensions` directories, then install the PHP packages:

```bash
# first checkout to the local branch in the 'app' and the 'extensions'
php composer install
```

### Run the Application
### 4. Run the Application

You can use PHP's built-in web server:
You can spin up the application quickly using PHP's built-in development web server:

```bash
php -S localhost:8000 -t public/
```

The application is now available at `http://localhost:8000`.
The application will now be available in your browser at `http://localhost:8000`.

> **Note:** The built-in server is single-threaded and intended for development
> only. Use a dedicated web server (Nginx, Caddy, etc.) in production.
> 💡 **Note:** The built-in PHP server is single-threaded and intended strictly for local development.
> Use a dedicated web server like Nginx, Apache, or Caddy for production deployments.
4 changes: 2 additions & 2 deletions .php-cs-fixer.dist.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*
* @see https://webifycms.com
*
* @copyright Copyright (c) 2023 WebifyCMS
* @copyright Copyright (c) 2023 - Present WebifyCMS
* @license https://webifycms.com/license
* @author Mohammed Shifreen <mshifreen@gmail.com>
*/
Expand Down Expand Up @@ -34,7 +34,7 @@

@see https://webifycms.com

@copyright Copyright (c) 2023 WebifyCMS
@copyright Copyright (c) 2023 - Present WebifyCMS
@license https://webifycms.com/license
@author Mohammed Shifreen <mshifreen@gmail.com>
HEADER;
Expand Down
7 changes: 5 additions & 2 deletions LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# WebifyCMS License

Copyright &copy; 2023 WebifyCMS (<https://www.webifycms.com>)
Copyright © 2023–Present WebifyCMS (<https://www.webifycms.com>)

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand All @@ -12,10 +12,13 @@ furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

**"WebifyCMS" is a registered trademark of WebifyCMS. Use of the name
"WebifyCMS" in derivative works requires prior written permission.**

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
SOFTWARE.
12 changes: 5 additions & 7 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,12 @@
"cms",
"cms project",
"php cms",
"yii2 cms",
"ddd cms",
"php ddd",
"app template"
"app template",
"php app template",
"clean architecture",
"php clean architecture"
],
"homepage": "https://www.webifycms.com/",
"type": "project",
Expand All @@ -23,7 +25,7 @@
"prefer-stable": true,
"require": {
"php": ">=8.4",
"webifycms/ext-base": "dev-main",
"webifycms/ext-base": "^0.1.0-alpha",
"oomphinc/composer-installers-extender": "^2.0"
},
"require-dev": {
Expand All @@ -35,10 +37,6 @@
"roave/security-advisories": "dev-latest"
},
"repositories": [
{
"type": "vcs",
"url": "https://github.com/webifycms/ext-base"
},
{
"type": "composer",
"url": "https://asset-packagist.org"
Expand Down
Loading
Loading