Skip to content

Instantly share code, notes, and snippets.

View nkoporec's full-sized avatar

nkoporec nkoporec

  • Slovenia
View GitHub Profile
@nkoporec
nkoporec / iterm2-solarized.md
Created February 5, 2019 18:47 — forked from kevin-smets/iterm2-solarized.md
iTerm2 + Oh My Zsh + Solarized color scheme + Meslo powerline font + [Powerlevel9k] - (macOS)

Default

Default

Powerlevel9k

Powerlevel9k

@nkoporec
nkoporec / git-revert-file-permissions-changes.sh
Last active January 23, 2019 13:59 — forked from jtdp/gist:5443498
Revert file permission changes in local git repository.
git diff -p \
| grep -E '^(diff|old mode|new mode)' \
| sed -e 's/^old/NEW/;s/^new/old/;s/^NEW/new/' \
| git apply
@nkoporec
nkoporec / docker4drupal_mac.md
Last active January 23, 2019 13:59 — forked from ralphschindler/README.md
Docker For Mac Host Address Alias To Enable PHP XDebug (10.254.254.254 Trick)

Docker (Mac) De-facto Standard Host Address Alias

This launchd script will ensure that your Docker environment on your Mac will have 10.254.254.254 as an alias on your loopback device (127.0.0.1). The command being run is ifconfig lo0 alias 10.254.254.254.

Once your machine has a well known IP address, your PHP container will then be able to connect to it, specifically XDebug can connect to it at the configured xdebug.remote_host.

Installation Of IP Alias (This survives reboot)

Copy/Paste the following in terminal with sudo (must be root as the target directory is owned by root)...