Skip to content

Instantly share code, notes, and snippets.

@acushlakoncept
Last active September 22, 2021 08:31
Show Gist options
  • Save acushlakoncept/d016c75a97025758c17c910d1825dd41 to your computer and use it in GitHub Desktop.
Save acushlakoncept/d016c75a97025758c17c910d1825dd41 to your computer and use it in GitHub Desktop.
MacOS Brew Installation

You can install Python packages with pip3 install They will install into the site-package directory /usr/local/lib/python3.9/site-packages

tkinter is no longer included with this formula, but it is available separately: brew install [email protected]

See: https://docs.brew.sh/Homebrew-and-Python ==> [email protected] To enable PHP in Apache add the following to httpd.conf and restart Apache: LoadModule php7_module /usr/local/opt/[email protected]/lib/httpd/modules/libphp7.so

<FilesMatch \.php$>
    SetHandler application/x-httpd-php
</FilesMatch>

Finally, check DirectoryIndex includes index.php DirectoryIndex index.php index.html

The php.ini and php-fpm.ini file can be found in: /usr/local/etc/php/7.2/

[email protected] is keg-only, which means it was not symlinked into /usr/local, because this is an alternate version of another formula.

To start [email protected]: brew services start [email protected] Or, if you don't want/need a background service you can just run: /usr/local/opt/[email protected]/sbin/php-fpm --nodaemonize ==> ruby By default, binaries installed by gem will be placed into: /usr/local/lib/ruby/gems/3.0.0/bin

You may want to add this to your PATH.

ruby is keg-only, which means it was not symlinked into /usr/local, because macOS already provides this software and installing another version in parallel can cause all kinds of trouble.

If you need to have ruby first in your PATH, run: echo 'export PATH="/usr/local/opt/ruby/bin:$PATH"' >> /Users/apple/.bash_profile

For compilers to find ruby you may need to set: export LDFLAGS="-L/usr/local/opt/ruby/lib" export CPPFLAGS="-I/usr/local/opt/ruby/include"

For pkg-config to find ruby you may need to set: export PKG_CONFIG_PATH="/usr/local/opt/ruby/lib/pkgconfig"

==> git The Tcl/Tk GUIs (e.g. gitk, git-gui) are now in the git-gui formula.

Bash completion has been installed to: /usr/local/etc/bash_completion.d

Emacs Lisp files have been installed to: /usr/local/share/emacs/site-lisp/git ==> mysql We've installed your MySQL database without a root password. To secure it run: mysql_secure_installation

MySQL is configured to only allow connections from localhost by default

To connect run: mysql -uroot

To start mysql: brew services start mysql Or, if you don't want/need a background service you can just run: /usr/local/opt/mysql/bin/mysqld_safe --datadir=/usr/local/var/mysql ==> postgresql To migrate existing data from a previous major version of PostgreSQL run: brew postgresql-upgrade-database

This formula has created a default database cluster with: initdb --locale=C -E UTF-8 /usr/local/var/postgres For more details, read: https://www.postgresql.org/docs/13/app-initdb.html

To restart postgresql after an upgrade: brew services restart postgresql Or, if you don't want/need a background service you can just run: /usr/local/opt/postgresql/bin/postgres -D /usr/local/var/postgres ==> redis To start redis: brew services start redis Or, if you don't want/need a background service you can just run: /usr/local/opt/redis/bin/redis-server /usr/local/etc/redis.conf

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment