techdivision/valet-plus

此包已被废弃,不再维护。没有建议的替代包。

极速 macOS PHP 开发环境

1.7.9 2021-01-05 16:16 UTC

README

Valet+ 是一个针对 macOS 的开发环境。无需 Vagrant、无需 Docker、无需 /etc/hosts 文件。

安装

安装 Homebrew

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew update && brew upgrade

安装先决条件

brew tap henkrehorst/php
brew install composer
brew install valet-php@7.2
brew link --force --overwrite valet-php@7.2

安装 valet-plus

composer global require techdivision/valet-plus
grep -q 'export PATH="$PATH:$HOME/.composer/vendor/bin"' ~/.zshrc || echo 'export PATH="$PATH:$HOME/.composer/vendor/bin"' >> ~/.zshrc

重新打开终端,并继续执行

valet install
valet elasticsearch install
/usr/local/opt/elasticsearch@2.4/libexec/bin/plugin install analysis-phonetic
/usr/local/opt/elasticsearch@2.4/libexec/bin/plugin install analysis-icu
grep -q 'script.inline: on' /usr/local/opt/elasticsearch@2.4/libexec/config/elasticsearch.yml || echo "script.inline: on" >> /usr/local/opt/elasticsearch@2.4/libexec/config/elasticsearch.yml
grep -q 'script.indexed: on' /usr/local/opt/elasticsearch@2.4/libexec/config/elasticsearch.yml || echo "script.indexed: on" >> /usr/local/opt/elasticsearch@2.4/libexec/config/elasticsearch.yml
valet restart elasticsearch

用法

有关进一步文档,请访问 https://github.com/weprovide/valet-plus/blob/master/readme.md