Skip to content

Instantly share code, notes, and snippets.

View jessebutryn's full-sized avatar

Jesse_b jessebutryn

View GitHub Profile
[root@JBCLAMP001 ~]# array+=('three')
[root@JBCLAMP001 ~]# echo ${array[@]}
zero one two three
[root@JBCLAMP001 ~]# array+='four'
[root@JBCLAMP001 ~]# echo ${array[@]}
zerofour one two three
@jessebutryn
jessebutryn / convert
Created October 14, 2017 23:55
TimeZone Converter
#! /bin/bash -
#set -x
#
# Copyright (c) 2017 Joyent Inc.
#
# This script will convert times from one timezone to another.
#
# Author: Jesse Butryn <jesse.butryn@joyent.com>
#
# 10/14/2017 - Initial draft.
@jessebutryn
jessebutryn / blackjack.sh
Last active September 10, 2017 13:14
Blackjack game
#! /usr/local/bin/bash -
#
TXT_BLD=$(tput bold)
TXT_YLW=$(tput setaf 3)
TXT_RED=$(tput setaf 1)
TXT_GRN=$(tput setaf 2)
TXT_WARN="${TXT_BLD}${TXT_YLW}"
TXT_ERR="${TXT_BLD}${TXT_RED}"
TXT_OKAY="${TXT_BLD}${TXT_GRN}"
TXT_RST=$(tput sgr0)