@@ -2,30 +2,35 @@ LARAVEL PATCHER
2
2
--
3
3
* A (migration like) patcher for a smoldering production update.* <br >
4
4
5
- [ ![ Total Downloads] ( https://img.shields.io/packagist/dt/jalameta/jps -patcher.svg?style=flat-square )] ( https://packagist.org/packages/jalameta/jps-patcher )
6
- ![ GitHub Workflow Status] ( https://img.shields.io/github/workflow/status/jalameta/ laravel-patcher/tests?label=tests )
5
+ [ ![ Total Downloads] ( https://poser.pugx.org/dentro/laravel -patcher/downloads )] ( https://packagist.org/packages/dentro/yalr )
6
+ ![ GitHub Workflow Status] ( https://github.com/digital-entropy/ laravel-patcher/workflows/ tests/badge.svg )
7
7
8
- Already tested on:
9
- * Laravel: 6.* | 7.\* | 8.\*
8
+ #### Requirements:
9
+ * PHP : 8.\*
10
+ * Laravel: 9.\*
10
11
11
12
##### Background :
12
- Our team has been made a stupid thing that affect database in our project .
13
+ Once upon a time, our team do a stupid thing that affect our production database .
13
14
It was happens many times, and we are usually go tinkering or direct edit on a
14
- database to fix those problems. The problem is we need to record those change,
15
- so we made this package. Besides, we sometime need to doing
16
- bulk insert user for our application, so *** patch*** will be the best solution.
15
+ database to fix those problems.
16
+ Then, our team leader [ Rifki Alhuraibi] ( https://github.com/veelasky/ ) comes up with
17
+ the idea about the package that handle history change of our patch activity (like the
18
+ one in database migration), so we made this package.
19
+ Also, we commonly need to bulk insert data to our application, this package also help
20
+ us in those activity.
17
21
18
22
### INSTALLATION
19
23
do either of this methods below.
20
24
* via shell
21
25
``` shell script
22
- composer require jalameta/jps -patcher
26
+ composer require dentro/laravel -patcher
23
27
```
24
- * adding ` "jalameta/jps -patcher": "^2 .0" ` to ` composer.json `
28
+ * adding ` "dentro/laravel -patcher": "^1 .0" ` to ` composer.json `
25
29
``` json
26
30
{
27
31
"require" : {
28
- "jalameta/jps-patcher" : " ^2.0"
32
+ ...
33
+ "dentro/laravel-patcher" : " ^1.0"
29
34
}
30
35
}
31
36
```
@@ -51,9 +56,6 @@ for creating new patch you just need to run these following command
51
56
` ` ` shell script
52
57
php artisan make:patch what_do_you_want_to_patch
53
58
` ` `
54
- > wait, do you feels familiar huh? , we do too.
55
- The truth is, this package is extending laravel migration.< br>
56
- >
57
59
after run those command, you will see new file in ` patches` folder.
58
60
Those file will be like:
59
61
` ` ` php
@@ -76,7 +78,7 @@ class WhatDoYouWantToPatch extends Patch
76
78
}
77
79
` ` `
78
80
Method ` patch` on these file will be filled with your logic.
79
- in ` ` ` Jalameta \P atcher\P atch` ` ` there is some useful properties
81
+ in ` ` ` Dentro \P atcher\P atch` ` ` there is some useful properties
80
82
that you can use for supporting your patch such as:
81
83
1. ` $container : \I lluminate\C ontainer\C ontainer`
82
84
2. ` $command : \I lluminate\C onsole\C ommand`
@@ -87,7 +89,7 @@ that you can use for supporting your patch such as:
87
89
> $this->command->warn(' i patch something danger! ' );
88
90
> $this->command->confirm(' do you wish to continue? ' );
89
91
> ```
90
- > you can learn more about `\Illuminate\Console\Command` [here](https://laravel.com/api/8 .x/Illuminate/Console/Command.html).
92
+ > you can learn more about `\Illuminate\Console\Command` [here](https://laravel.com/api/9 .x/Illuminate/Console/Command.html).
91
93
92
94
3. `$logger: \Illuminate\Log\Logger`
93
95
@@ -109,7 +111,6 @@ php artisan patcher:status
109
111
```
110
112
Example:
111
113
```shell script
112
- my_project on master [$!] via ⬢ v14.14.0 via 🐘 v7.4.11 on 🐳 v19.03.13
113
114
➜ php artisan patcher:status
114
115
+------+---------------------------------------+-------+
115
116
| Ran? | Patch | Batch |
@@ -125,7 +126,6 @@ php artisan patcher:run
125
126
```
126
127
Example:
127
128
```shell script
128
- my_project on master [$!] via ⬢ v14.14.0 via 🐘 v7.4.11 on 🐳 v19.03.13
129
129
➜ php artisan patcher:status
130
130
Patches table created successfully.
131
131
Patching: 2020_09_29_190531_fix_double_sections
0 commit comments