Laravel Artisan Tinker: The optimize Command
Laravel Artisan Tinker: The optimize Command
December 7, 2016 Laravel
JOHN KOSTER
The optimize
command optimizes various aspects to improve the performance of the Laravel application. The command provides two flags. The --force
flag can be set to indicate that the compiled class file should be written (by default the compiled class is not written when the application is in debug mode). The --psr
flag can be set to indicate that Composer should not create an optimized class map loader (class maps are generally better for performance reasons).
The compiled files cache will be written to the bootstrap/cache/compiled.php
cache file. The files that are compiled and written to the cache any files that meet the following criteria:
- Any files specified in the
compile.files
configuration entry; - Any files that are specified by any service providers listed in the
compile.providers
configuration entry; - Any framework files listed in the
src/Illuminate/Foundation/Console/Optimize/config.php
file.
The following examples demonstrate how to use the optimize
command:
# Generate a compiled class file with default options.
optimize
# Generate a compiled class file without optimizing the Composer
# autoload file.
optimize --psr
# Generate a compiled class file on a development or debug machine.
optimize --force
This command performs the same action as the php artisan optimize
command.
Laravel Artisan Tinker: The optimize Command的更多相关文章
- laravel使用使用 Php Artisan Tinker 实现模型的增删改查
tinker命令: php artisan tinker 查阅数据库数据: App\User::count(); App\User::where('username', 'samuel')->f ...
- 使用 Php Artisan Tinker 来调试你的 Laravel
Posted on 2016年6月19日 by ichou 本文翻译自:Tinker with the Data in Your Laravel Apps with Php Artisan Tinke ...
- laravel artisan 命令工具
//全局相关 php artisan:显示详细的命令行帮助信息,同 php artisan list php artisan –help:显示帮助命令的使用格式,同 php artisan help ...
- Laravel artisan commands
使用php artisan list 可以看到artisan的所有命令以及选项. 当然你也可以在此基础上扩展自己的命令. 1. key 1.1 key:generate 这是一个加密秘钥,用于保证安全 ...
- laravel artisan 命令列表
5.4版本新增 命令 说明 备注 php artisan make:resource ? 创建api返回格式化资源 >=5.4版本可用 php artisan make:rule ? 创建val ...
- laravel5.1学习(2)-- artisan tinker命令
例如:为users表创建20条测试输入 G:\wamp\www\hcmf>php artisan tinker >>> namespace App; => null &g ...
- laravel artisan 工具心得
介绍一些非常好用的命令: 1.创建一个Eloquent模型:顺便创建一个对应的数据库表 php artisan make:model --migration Models/Admin/test 2.将 ...
- Laravel artisan 命令
获取命令列表 php artisan Laravel Framework 7.26.0 Usage: command [options] [arguments] Options: -h, --help ...
- SpringBoot Laravel(artisan serve) MIXPHP简单性能测试
测试条件: CPU: 2C 4T 2.8GHZ MEM: 8G DISK: 512GB SSD OS: OS X 10.11.6 测试指令 ab -n 2000 -c 10 测试表现 MIXPHP R ...
随机推荐
- flask数据库迁移
实际操作顺序:1.python 文件 db init2.python 文件 db migrate -m"版本名(注释)"3.python 文件 db upgrade 然后观察表结构 ...
- Postgresql explain的analyze和buffers选项
sql查询分析: 原文地址:https://blog.csdn.net/qq_28893679/article/details/78316283
- Jmeter之Dummy Sampler
Dummy Sampler(Dummy取样器) Dummy Sampler就像是一个模拟器,需要自己填入请求和响应的信息.(原理类似mock服务) 在没有服务的情况下,测试人员依据Dummy Samp ...
- 版本管理工具svn(转)
这种操作类的文章就不自己再写了,感觉浪费时间. 找了一个写的不错的文章转载. 文中流程有些变动,但是问题不大,可能是版本原因. SVN服务器的本地搭建和使用 http://www.2cto.com/o ...
- 7.bash作业控制
7.作业控制本节讨论作业控制是什么.它怎么工作.以及 Bash 里面怎么使用这些功能7.1 作业控制基础作业控制是指有选择的停止(暂停)并在后来继续(恢复)执行某个进程的能力.通常,用户通过 Bash ...
- Scala学习十二——高阶函数
一.本章要点 在Scala中函数是”头等公民“(可以作为参数,返回值,赋值给其他); 可以创建匿名函数,通常还会交给其他函数; 函数参数可以给出需要稍后执行的行为; 许多集合方法都接受函数参数,将函数 ...
- 进阶Java编程(2)线程常用操作方法
线程常用操作方法 多线程的主要操作方法都在Thread类中定义的. 1,线程的命名和取得 多线程的运行状态是不确定的,那么在程序的开发之中为了可以获取到一些需要使用到的线程就只能依靠线程的名字来进行操 ...
- word、ppt转换为pdf
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.T ...
- prototype,__proto__,constructor理解
prototype: 任何函数(箭头函数除外)都具有一个 prototype属性,该属性是一个对象.一般情况下只有声明function的变量才会有(自动生成)prototype这个属性,而functi ...
- 宝塔控制面板+wordpress搭建个人网站
上个月买了服务器和域名之后就搁置了,今天有空闲就来配合教程尝试一下搭建个人网站,下面是网站搭建的详细过程以及中间的一些细节问题,写这篇文章的目的就是希望能够帮到一些小伙伴,或者为以后搭建网站做一些参考 ...