Last active
June 8, 2019 04:32
-
-
Save codeitlikemiley/d6e1460d97bf9f0def59c3200cac46ad to your computer and use it in GitHub Desktop.
Search And Replace Config File in laravel
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| diff --git a/config/app.php b/config/app.php | |
| index c9960cd..29a3a1c 100644 | |
| --- a/config/app.php | |
| +++ b/config/app.php | |
| @@ -171,7 +171,7 @@ return [ | |
| */ | |
| App\Providers\AppServiceProvider::class, | |
| App\Providers\AuthServiceProvider::class, | |
| - // App\Providers\BroadcastServiceProvider::class, | |
| + App\Providers\BroadcastServiceProvider::class, | |
| App\Providers\EventServiceProvider::class, | |
| App\Providers\RouteServiceProvider::class, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $path_to_file = config_path('app.php'); | |
| $file_contents = file_get_contents($path_to_file); | |
| $file_contents = str_replace("// App\Providers\BroadcastServiceProvider::class," , "App\Providers\BroadcastServiceProvider::class," ,$file_contents); | |
| file_put_contents($path_to_file,$file_contents); | |
| // the following can be used | |
| // tab = \t | |
| // newline = \n | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment