phpstudy thinkphp6

0311lc.com说:

window10 下 phpstudy2018

nginx  模式下 配置

是双杠

root “G:\\myapp\\tp\\public”;

 

完整

server {
listen 80;
server_name myapp.cc ;
root “G:\\myapp\\tp\\public”;
index index.php index.html index.htm;
location / {
#autoindex on;
if (!-e $request_filename) {
rewrite ^/(.*)$ /index.php/$1 last;
break;
}
}

location ~ \.php(.*)$ {
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_split_path_info ^((?U).+\.php)(/?.+)$;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
include fastcgi_params;
}
}


compser phpstudy

0311lc.com说:
查看composer版本
1.查询位置在compser安装目录下执行
E:phpstudy_proExtensionsphpphp7.1.9ntsphp.exe composer.phar -V 显示版本号则为正常

2.composer默认是国外的镜像,如果想使用国内镜像 https://packagist.phpcomposer.com 还需要配置一下E:phpstudy_proExtensionsphpphp7.1.9ntsphp.exe composer.phar config -g repo.packagist composer httpp://packagist.phpcomposer.com

 

 

https://packagist.phpcomposer.com
快速设置windows 国内镜像

在windows 黑窗口 操作 > composer config -g repo.packagist composer https://packagist.phpcomposer.com

composer config -g repo.packagist composer https://mirrors.aliyun.com/composer/

查看全局配置:

composer config -l -g

 

安装laravel v6.18.3版本 composer create-project laravel/laravel laravel6.8 v6.18.3

 

 

===================================================

出现的错误:
[InvalidArgumentException]
Could not find package topthink/think with stability stable.

解决方案:
删除之前的镜像:composer config -g –unset repos.packagist