This file contains 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
#include <openssl/ssl.h> | |
#include <openssl/bio.h> | |
#include <openssl/err.h> | |
#define HOST "encrypted.google.com" | |
/** | |
* Example SSL client that connects to the HOST defined above, | |
* and prints out the raw response to stdout. | |
*/ |
This file contains 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
ssh() { | |
# grep -w: match command names such as "tmux-2.1" or "tmux: server" | |
if ps -p $$ -o ppid= \ | |
| xargs -i ps -p {} -o comm= \ | |
| grep -qw tmux; then | |
# Note: Options without parameter were hardcoded, | |
# in order to distinguish an option's parameter from the destination. | |
# | |
# s/[[:space:]]*\(\( | spaces before options | |
# \(-[46AaCfGgKkMNnqsTtVvXxYy]\)\| | option without parameter |
This file contains 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 python2.7 | |
""" | |
Extract title from PDF file. | |
Dependencies: | |
pip install --user unidecode pyPDF PDFMiner | |
Usage: | |
find . -name "*.pdf" | xargs -I{} pdftitle -d tmp --rename {} |