标签:fresh ref isa project src 删除 文件 route ble
php artisan 命令在开发laravel项目中非常常用,下面是一些总结
composer config -g repo.packagist composer https://mirrors.aliyun.com/composer/
配置阿里云服务器composer global require "laravel/installer"
安装lara安装器laravel new learn_laravel
新建项目vendor/laravel/framework/src/Illuminate/Foundation/Application.php
lara版本号所在文件composer create-project laravel/laravel my-laravel --prefer-dist "5.5.*"
安装laravel 5.5版本php artisan make:controller HelloController
创建控制器php artisan make:controller HelloResourceController --resource
创建资源控制器php artisan route:list
查看路由列表php artisan make:middleware CheckBirthday
创建中间件php artisan make:model ModelName --migration / -m
创建模型php artisan make::migration migraiton_filename --table=database_tb_name
创建数据库迁移文件php artisan migrate
触发最近的数据库迁移文件类中up()方法php artisan migrate:rollback
触发最近的数据库迁移文件类中down()方法php artisan migrate:reset
回滚所有的迁移php artisan migrate:fresh
删除所有表并运行迁移php artisan migrate:refresh
回滚所有迁移,并重新执行,相当于先 reset 后 migrate标签:fresh ref isa project src 删除 文件 route ble
原文地址:https://www.cnblogs.com/zxcv123/p/11967199.html