Skip to content

Commit

Permalink
fixed README.md and versioning
Browse files Browse the repository at this point in the history
  • Loading branch information
Dorsone committed Jan 4, 2025
1 parent 0c48a47 commit 32b0a7f
Showing 1 changed file with 17 additions and 11 deletions.
28 changes: 17 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,24 +1,23 @@
[![Laravel](https://img.shields.io/badge/Laravel-9.x-orange.svg?style=flat-square)](http://laravel.com)
[![Laravel](https://img.shields.io/badge/Laravel-10.x-red.svg?style=flat-square)](http://laravel.com)
[![Laravel](https://img.shields.io/badge/Laravel-11.x-yellow.svg?style=flat-square)](http://laravel.com)
[![License](http://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat-square)](https://tldrlegal.com/license/mit-license)

# Multi Domain for Laravel

An extension for using Laravel in a multi subdomains setting

## Documentation

### Version Compatibility

| Laravel | Package |
|:--------|:---------------------|
| 9.x | 1.x-2.x (deprecated) |
| 10.x | 3.x-4.x |
| 11.x | 5.x |
| Laravel | Package |
|:--------|:-----------------|
| 11.x | 1.x (actual) |
| 11.x | 5.x (deprecated) |

### Installation

To get the latest version of `Mostbyte Multidomain`, simply require the project using [Composer](https://getcomposer.org)
To get the latest version of `Mostbyte Multidomain`, simply require the project
using [Composer](https://getcomposer.org)

```bash
composer require mostbyte/multidomain
Expand All @@ -29,7 +28,7 @@ Instead, you may of course manually update your requirement block and run `compo
```json
{
"require": {
"mostbyte/multidomain": "^5.0"
"mostbyte/multidomain": "^1.0"
}
}
```
Expand All @@ -41,19 +40,24 @@ php artisan vendor:publish --provider="Mostbyte\Multidomain\MultidomainServicePr
```

### Usage
There is a helper `mostbyteDomainManager`, that returns `DomainManager` and you can use all methods which created in it, for example:

There is a helper `mostbyteDomainManager`, that returns `DomainManager` and you can use all methods which created in it,
for example:

```php
$subDomain = mostbyteDomainManager()->getSubDomain();
```

### Console Commands Documentation

1) First of all you need to create new schema with command below

```bash
php artisan mostbyte:schema {schema}
```

2) Then you can run migration with following command and with all flags which exists in default Laravel ```migrate``` command
2) Then you can run migration with following command and with all flags which exists in default Laravel ```migrate```
command

```bash
php mostbyte:migrate {schema}
Expand All @@ -66,6 +70,7 @@ php mostbyte:migrate {schema}
```
3) Or there is the command for refreshing database
```bash
php mostbyte:fresh {schema}
{--realpath : Indicate any provided migration file paths are pre-resolved absolute paths}
Expand All @@ -74,6 +79,7 @@ php mostbyte:fresh {schema}
```
4) If you want to ***DELETE*** the schema ***with all data in***, run this command
```bash
php artisan mostbyte:rollback {schema}
```

0 comments on commit 32b0a7f

Please sign in to comment.