composer相关
指定composer使用1.9.0版本
composer self-update 1.9.0
回退1.x版本
composer self-update --1
mac进程相关
ps -ef | grep nginx
ps -lf
brew相关
检查brew
brew doctor
查找包
brew search nginx
安装包
brew install nginx
启动服务
brew services start|stop|restart nginx
nginx -s reload|start|stop
检查nginx配置文件
nginx -t
以某一个配置文件启动nginx
nginx -c /{con_dir}/nginx.conf
brew安装php相关
删除全部php包,重新安装
brew update
brew upgrade
brew cleanup
brew list | grep php
brew uninstall --force php56 php56-apcu php56-opcache php56-xdebug php56-yaml
brew uninstall --force php70 php70-apcu php70-opcache php70-xdebug php70-yaml
brew uninstall --force php71 php71-apcu php71-opcache php71-xdebug php71-yaml
brew uninstall --force php72 php72-apcu php72-opcache php72-xdebug php72-yaml
brew cleanup
rm -Rf /usr/local/etc/php/*
brew tap shivammathur/php
brew install shivammathur/php/php@7.0
brew install shivammathur/php/php@7.1
brew install shivammathur/php/php@7.2
brew install shivammathur/php/php@7.3
brew install shivammathur/php/php@7.4
brew install shivammathur/php/php@8.0
/usr/local/etc/php/7.0/php.ini
/usr/local/etc/php/7.1/php.ini
/usr/local/etc/php/7.2/php.ini
/usr/local/etc/php/7.3/php.ini
/usr/local/etc/php/7.4/php.ini
/usr/local/etc/php/8.0/php.ini
brew unlink php && brew link --overwrite --force php@7.3
php -v
php安装拓展
pecl install redis
pecl install mongodb
pecl install rabbitmq-c
pecl install amqp + rabbitmq-c路径
php查看拓展
php -m
重启php服务
sudo killall php-fpm
sudo php-fpm
开启/关闭PHP服务
sudo killall php-fpm
sudo php-fpm
删除指定文件
find ./ -name ".DS_Store" -exec rm -r "{}" \;
Redis相关
启动redis服务:redis-server
查看端口情况:lsof -i:6379
杀掉已经存在进程:kill pid 6076(进程PID)
zip压缩命令 带密码
zip -rP king java.zip java
修改Mac启动台应用程序图标排列数量
defaults write com.apple.dock springboard-rows -int 7
defaults write com.apple.dock springboard-columns -int 10
defaults write com.apple.dock ResetLaunchPad -bool TRUE;killall Dock
微信多开命令
open -n /Applications/WeChat.app/Contents/MacOS/WeChat
HTML文件 MAC 无法访问
xattr -c filename
xattr -rc directory
发表评论 取消回复