1、安装larval在线调试工具,在项目根目录下安装
composer require barryvdh/laravel-debugbar
composer require barryvdh/laravel-debugbar
2、设置项目git用户名
git config --global user.name "limingxia"
3、设置项目git email
git config --global user.email "lilian1131@163.com"
4、将当前所有文件放入到暂存区
git add .
5、新建一个git分支
git checkout -b "testRoute"
6、查看我在哪个分支,星号是当前分支
git branch
7、larval重定向,开启重定向模块
默认访问路由是
http://vm.demo/index.php/test
若想要访问
http://vm.demo/test
*创建重写的软链接
ln -s /etc/apache2/mods-available/rewrite.load /etc/apache2/mods-enabled/
*配置apache2.conf,修改www下的 AllowOverride,将None改为all
cd /etc/apache2
vi apache2.conf
这是可以直接访问vm.demo/test
8、格式化函数dd,输出并结束函数运行,不安装debug工具也可以使用
9、暂存并提交修改后的git
git commit -a -m "修改路由配置"
10、切换分支
*切换到主分支
git checkout master
11、配置文件 config
cd /config
vi app.php
Barryvdh\Debugbar\ServiceProvider::class,
'Debugbar' => Barryvdn\Debuger\Facade::class,
cd ..
php artisan vendor:publish
生成debug.php
12、修改数据库配置 .env文件
vi .env
13、更新版本库,有新创建的文件
*git add .
*git add --all
git commit -m "debagbar配置"