It was decided to start from 2018-05-01 and fully migrate to Mac for development. Why? Is Mac really more convenient than Windows to code? There is no such experience yet, but if you don't use this mac notebook, you will buy it for nothing.
Copy the bits and pieces of the mac familiarity learning to the blog:
iwork three-piece set: pages number keynote
Restart the Apache service on the mac:
Stop the service: sudo /usr/sbin/apachectl stop
Start the service: sudo /usr/sbin/apachectl start
Restart the service: sudo /usr/sbin/apachectl restart
Check the native apache version: sudo apachectl -v
The path of the pace configuration file is: /etc/apache2/httpd.conf
Lock screen: ctrl+shift+Power
First attach how to enter the specified directory folder home folder: command+shift+G
OS X has two directories by default to run your web programs directly, one is the system-level web root directory, and the other is the user-level root directory /Library/WebServer/Documents ==> http://localhost ~/Sites ==> http://localhost/~shaodq
After creating the site folder, check whether there is a "shaodq.conf" file under the /etc/ folder,
/etc/apache2/users/shaodq.conf
[Mac common commands——http://m.baidu.com/paw/c/s/m.douban.com/mip/note/75797151/]
[Install Homebrew: ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" ]
/usr/libexec/apache2 There is a php version installed in the system under /usr/libexec/apache2
Mac is pre-installed with php, but many extensions are not installed, especially when the system is updated, Mac will reset your php configuration, causing unnecessary trouble, so it is best to install php yourself. Enter the following statement on the command line:
brew tap homebrew/dupes
brew tap homebrew/php
brew install --without-apache --with-fpm --with-mysql php56
When Homebrew installs php, there will be many versions to choose from. You can use the brew search php command to see what version can be installed. The installation I chose here is php5.6. This php installation is relatively slow, and you need to wait patiently....
Mac terminal clear screen command: command + k