- Patch
/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/vim.rb - Build
brew reinstall --verbose --debug --build-from-source vim
- Locate your dynamic library with
find /Users/bronoric/.pyenv/ -name '*libpython3*.dylib'- It's probably going to contain
darwinin the path.
- It's probably going to contain
Netcat is like a swiss army knife for geeks. It can be used for just about anything involving TCP or UDP. One of its most practical uses is to transfer files. Non *nix people usually don't have SSH setup, and it is much faster to transfer stuff with netcat then setup SSH. netcat is just a single executable, and works across all platforms (Windows,Mac OS X, Linux).
On the receiving (destination) terminal, run:
nc -l -p 1234 > out.file
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| import json, re, sys | |
| for k,v in json.load(sys.stdin)['Credentials'].items(): print("export AWS{}='{}'".format(re.sub('([A-Z])', r'_\1', k).upper(),v)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| #!/usr/bin/env vim | |
| #! This is a bash script that executes itself as a vimscript to do its work | |
| #! vim:ft=vim:ts=2:sts=2:sw=2 | |
| : if 0 | |
| tmpfile=$(mktemp -t vimcat.XXXXXXXX) | |
| exec 9<>"$tmpfile" | |
| rm "$tmpfile" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| convert_text(){ | |
| python3 -c 'import html, sys; [print(html.escape(l), end="") for l in sys.stdin]' | \ | |
| sed -E $' | |
| 1i\\\n<span style="-en-clipboard:true;"><br/></span><div style="-en-codeblock:true;"><div>\n | |
| s, ,\ ,g | |
| s,$,<br/>, | |
| s,^<br/>$,<div><br/></div>, | |
| $a\\\n</div></div>\n |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # only tested on macOS | |
| gtop(){ pattern="${1:-WindowServer}"; top $(ps -haxl | awk '/'"$pattern"'/{print "-pid " $2}'); } | |
| gtop Chrome |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash -eux | |
| function usage(){ | |
| cat<<USAGE | |
| NAME | |
| add_ip_to_ipset - Add a single IP to a WAF IP Set | |
| SYNOPSIS | |
| add_ip_to_ipset IP IP_SET_NAME |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| """Script for toggling my Raspberry Pi NeoPixel chromakey ringlight | |
| Usage: | |
| activate with default power of 64/256: | |
| ./neo | |
| activate full power: | |
| ./neo 64 | |
| deactivate: | |
| ./neo off |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash -eu | |
| aws.setup-credentials(){ | |
| local FILE="${1:--/dev/null}" | |
| local file_paths_to_check=( | |
| "$FILE" | |
| "./accessKeys.csv" | |
| "$HOME/accessKeys.csv" | |
| "$HOME/Downloads/accessKeys.csv" | |
| ) |