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
# 0 is too far from ` ;) | |
set -g base-index 1 | |
# Automatically set window title | |
set-window-option -g automatic-rename on | |
set-option -g set-titles on | |
#set -g default-terminal screen-256color | |
set -g status-keys vi | |
set -g history-limit 10000 |
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
function usps_track() | |
{ | |
local _USER_AGENT_CHROME_76='Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.100 Safari/537.36' | |
local _URL="https://tools.usps.com/go/TrackConfirmAction?tLabels=${1}" | |
local _HEADER_USER_AGENT="User-Agent: ${_USER_AGENT_CHROME_76}" | |
curl --silent --location --header "$_HEADER_USER_AGENT" "$_URL" | pup 'h2 > strong text{}' | |
} |
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 bash | |
function times() | |
{ | |
_in_string="$1" | |
_out_string="" | |
_count=$2 | |
for (( i=0; i < $_count; i++ )) |
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 bash | |
manifest=${1:-manifest} | |
[ ! -f "$manifest" ] && echo "no file \"${manifest}\"" && exit 1 | |
while read line | |
do | |
from=${line%%:*} | |
to=${line##*:} |