convert image.png -resize 40 txt:-|sed -E 's/://;s/\( ? ?//;s/, ? ?/,/g;s/\)//;s/([0-9]+,[0-9]+,[0-9]+),[0-9]+/\1/g;s/255/254/g;/mage/d'|awk '{print $1,$2}'|sed -E 's/^0,[0-9]+ /print "echo;tput setaf "\;/;s/^[0-9]+,[0-9]+ /print "tput setaf ";/;s/(.+),(.+),(.+)/\1\/42.5*36+\2\/42.5*6+\3\/42.5+16/'|bc|sed 's/$/;echo -n " ";/'|tr '\n' ' '|sed 's/^/tput rev;/;s/; /;/g;s/$/tput sgr0;echo/'|bash
# This program will take swag.csv and create a batch of USPS | |
# shipping labels in one PDF file for easy printing using | |
# the EasyPost simple shipping API. | |
# | |
# If you have any questions about EasyPost or want help | |
# modifying this script for other carriers or a non-US | |
# source address please email us anytime at contact@easypost.com | |
# | |
# Usage: | |
# easypost_batch_from_csv.rb |
FILE SPACING: | |
# double space a file | |
sed G | |
# double space a file which already has blank lines in it. Output file | |
# should contain no more than one blank line between lines of text. | |
sed '/^$/d;G' |
# Images and Icons # | |
#################### | |
*.png | |
*.jpg | |
*.gif | |
*.tiff | |
*.ico | |
# Fonts # | |
######### |
#!/bin/bash | |
# Size at the end is * 2048 where 2048 = 1 MB, so 1572864 = 768 MB | |
#DISK=`/usr/bin/hdiutil attach -nobrowse -nomount ram://1572864` | |
DISK=`/usr/bin/hdiutil attach -nobrowse -nomount ram://2097152` | |
/usr/sbin/diskutil erasevolume HFS+ "RamDiskCache" $DISK | |
CACHEDIR="/Volumes/RamDiskCache/$USER" |
alias airport="/System/Library/PrivateFrameworks/Apple80211.framework/Versions/A/Resources/airport" | |
alias bssid="networksetup -getairportnetwork $(networksetup -listallhardwareports | grep -A 2 'Hardware Port: Wi-Fi' | grep 'Device:' | awk '{print $2}')" | |
alias ssid="bssid" | |
# Use alias below with (on|off) to turn airport card on or off from CL. | |
alias wifi="networksetup -setairportpower $(networksetup -listallhardwareports | grep -A 2 'Hardware Port: Wi-Fi' | grep 'Device:' | awk '{print $2}')" | |
alias wifi-info="networksetup -getinfo Wi-Fi" | |
alias apinfo="airport -I" | |
alias known-networks="networksetup -listpreferrednetworks $(networksetup -listallhardwareports | grep -A 2 'Hardware Port: Wi-Fi' | grep 'Device:' | awk '{print $2}')" | |
alias wifi-disconnect="sudo airport -z" | |
alias wifi-networks="airport -s" |
1Password 5.3 for OSX, 5.2 for iOS, and 4.1.0.538 for Windows support OTP. I've been using Authy for a while now, but the fact is, I haven't really been using 2FA for some time. As mentioned by 1Password in a recent blog post, having the OTP generator and password on the same device is very much not 2FA. It's just an expiring OTP, which can help, but let's not kid ourselves too much.
With that out of the way. One of the things that was interesting to me was moving my OTP out of Authy and into 1Password. I like the control I get with 1Password, but I didn't want to have to reset all my OTP right away, that would suck. So, I got to dissecting the Authy Chrome App to see what I could do.
Run the Authy Chrome app and make sure it's unlocked.
Now, enable Developer mode in Chrome. We'll need this to inspect the background application that stores al
# do it once | |
seq 1 | parallel -n0 "curl -H 'Content-Type: application/json' http://httpbin.org/post -X POST -d '{\"url\":\"http://google.com/\"}'" | |
# do it twice | |
seq 2 | parallel -n0 "curl -H 'Content-Type: application/json' http://httpbin.org/post -X POST -d '{\"url\":\"http://google.com/\"}'" | |
# do it 4 times, but at 2 a time | |
seq 4 | parallel -n0 -j2 "curl -H 'Content-Type: application/json' http://httpbin.org/post -X POST -d '{\"url\":\"http://google.com/\"}'" | |
# you can also put all your commands into a file |