From c60eb20614aade74edd7773b87688c1825750100 Mon Sep 17 00:00:00 2001 From: phenonymous <29523105+phenonymous@users.noreply.github.com> Date: Tue, 13 Nov 2018 18:51:25 +0100 Subject: [PATCH] Major update with tilix support --- apply-colors.sh | 40 ++- gogh.sh | 146 ++++++----- test/print-themes.sh | 295 +++++++++++++++++++++++ themes/3024-day.sh | 34 +-- themes/3024-night.sh | 34 +-- themes/_base.sh | 30 +-- themes/aci.sh | 34 +-- themes/aco.sh | 34 +-- themes/adventuretime.sh | 34 +-- themes/afterglow.sh | 34 +-- themes/alien-blood.sh | 34 +-- themes/argonaut.sh | 34 +-- themes/arthur.sh | 34 +-- themes/atom.sh | 34 +-- themes/azu.sh | 34 +-- themes/belafonte-day.sh | 34 +-- themes/belafonte-night.sh | 34 +-- themes/bim.sh | 34 +-- themes/birds-of-paradise.sh | 34 +-- themes/blazer.sh | 34 +-- themes/borland.sh | 34 +-- themes/broadcast.sh | 34 +-- themes/brogrammer.sh | 34 +-- themes/c64.sh | 34 +-- themes/cai.sh | 34 +-- themes/chalk.sh | 34 +-- themes/chalkboard.sh | 34 +-- themes/ciapre.sh | 34 +-- themes/clone-of-ubuntu.sh | 30 +-- themes/clrs.sh | 34 +-- themes/cobalt-neon.sh | 34 +-- themes/cobalt2.sh | 34 +-- themes/crayon-pony-fish.sh | 34 +-- themes/dark-pastel.sh | 34 +-- themes/darkside.sh | 34 +-- themes/desert.sh | 34 +-- themes/dimmed-monokai.sh | 34 +-- themes/dracula.sh | 34 +-- themes/earthsong.sh | 34 +-- themes/elemental.sh | 34 +-- themes/elementary.sh | 34 +-- themes/elic.sh | 34 +-- themes/elio.sh | 34 +-- themes/espresso-libre.sh | 34 +-- themes/espresso.sh | 34 +-- themes/fishtank.sh | 34 +-- themes/flat.sh | 34 +-- themes/flatland.sh | 34 +-- themes/foxnightly.sh | 34 +-- themes/freya.sh | 34 +-- themes/frontend-delight.sh | 34 +-- themes/frontend-fun-forrest.sh | 34 +-- themes/frontend-galaxy.sh | 34 +-- themes/github.sh | 34 +-- themes/gooey.sh | 30 +-- themes/google-dark.sh | 30 +-- themes/google-light.sh | 30 +-- themes/grape.sh | 34 +-- themes/grass.sh | 34 +-- themes/gruvbox-dark.sh | 34 +-- themes/gruvbox.sh | 34 +-- themes/hardcore.sh | 34 +-- themes/harper.sh | 34 +-- themes/hemisu-dark.sh | 34 +-- themes/hemisu-light.sh | 34 +-- themes/highway.sh | 34 +-- themes/hipster-green.sh | 34 +-- themes/homebrew.sh | 34 +-- themes/hurtado.sh | 34 +-- themes/hybrid.sh | 34 +-- themes/ic-green-ppl.sh | 34 +-- themes/ic-orange-ppl.sh | 34 +-- themes/idle-toes.sh | 34 +-- themes/ir-black.sh | 34 +-- themes/jackie-brown.sh | 34 +-- themes/japanesque.sh | 34 +-- themes/jellybeans.sh | 34 +-- themes/jup.sh | 34 +-- themes/kibble.sh | 34 +-- themes/later-this-evening.sh | 34 +-- themes/lavandula.sh | 34 +-- themes/liquid-carbon-transparent.sh | 34 +-- themes/liquid-carbon.sh | 34 +-- themes/man-page.sh | 34 +-- themes/mar.sh | 34 +-- themes/material.sh | 34 +-- themes/mathias.sh | 34 +-- themes/medallion.sh | 34 +-- themes/misterioso.sh | 34 +-- themes/miu.sh | 34 +-- themes/molokai.sh | 34 +-- themes/mona-lisa.sh | 34 +-- themes/monokai-dark.sh | 34 +-- themes/monokai-soda.sh | 34 +-- themes/n0tch2k.sh | 34 +-- themes/neopolitan.sh | 34 +-- themes/nep.sh | 34 +-- themes/neutron.sh | 34 +-- themes/nightlion-v1.sh | 34 +-- themes/nightlion-v2.sh | 34 +-- themes/nighty.sh | 30 +-- themes/nord-light.sh | 34 +-- themes/nord.sh | 34 +-- themes/novel.sh | 34 +-- themes/obsidian.sh | 34 +-- themes/ocean-dark.sh | 34 +-- themes/ocean.sh | 34 +-- themes/oceanic-next.sh | 34 +-- themes/ollie.sh | 34 +-- themes/one-dark.sh | 34 +-- themes/one-half-black.sh | 34 +-- themes/one-light.sh | 34 +-- themes/pali.sh | 34 +-- themes/paraiso-dark.sh | 34 +-- themes/paul-millr.sh | 34 +-- themes/pencil-dark.sh | 34 +-- themes/pencil-light.sh | 34 +-- themes/peppermint.sh | 34 +-- themes/pnevma.sh | 34 +-- themes/pro.sh | 34 +-- themes/red-alert.sh | 34 +-- themes/red-sands.sh | 34 +-- themes/rippedcasts.sh | 34 +-- themes/royal.sh | 34 +-- themes/sat.sh | 34 +-- themes/sea-shells.sh | 34 +-- themes/seafoam-pastel.sh | 34 +-- themes/seti.sh | 34 +-- themes/shaman.sh | 34 +-- themes/shel.sh | 34 +-- themes/slate.sh | 34 +-- themes/smyck.sh | 34 +-- themes/snazzy.sh | 34 +-- themes/soft-server.sh | 34 +-- themes/solarized-darcula.sh | 34 +-- themes/solarized-dark-higher-contrast.sh | 34 +-- themes/solarized-dark.sh | 35 +-- themes/solarized-light.sh | 35 +-- themes/spacedust.sh | 34 +-- themes/spacegray-eighties-dull.sh | 34 +-- themes/spacegray-eighties.sh | 34 +-- themes/spacegray.sh | 34 +-- themes/spring.sh | 34 +-- themes/square.sh | 34 +-- themes/srcery.sh | 34 +-- themes/sundried.sh | 34 +-- themes/symphonic.sh | 34 +-- themes/teerb.sh | 34 +-- themes/terminal-basic.sh | 34 +-- themes/terminix-dark.sh | 34 +-- themes/thayer-bright.sh | 34 +-- themes/tin.sh | 34 +-- themes/tomorrow-night-blue.sh | 34 +-- themes/tomorrow-night-bright.sh | 34 +-- themes/tomorrow-night-eighties.sh | 34 +-- themes/tomorrow-night.sh | 34 +-- themes/tomorrow.sh | 34 +-- themes/toy-chest.sh | 34 +-- themes/treehouse.sh | 34 +-- themes/twilight.sh | 34 +-- themes/ura.sh | 34 +-- themes/urple.sh | 34 +-- themes/vag.sh | 34 +-- themes/vaughn.sh | 34 +-- themes/vibrant-ink.sh | 34 +-- themes/warm-neon.sh | 34 +-- themes/wez.sh | 34 +-- themes/wild-cherry.sh | 34 +-- themes/wombat.sh | 34 +-- themes/wryan.sh | 34 +-- themes/zenburn.sh | 34 +-- 171 files changed, 2372 insertions(+), 3799 deletions(-) create mode 100644 test/print-themes.sh mode change 100644 => 100755 themes/google-dark.sh mode change 100644 => 100755 themes/google-light.sh mode change 100644 => 100755 themes/nighty.sh mode change 100644 => 100755 themes/snazzy.sh diff --git a/apply-colors.sh b/apply-colors.sh index e85f076..2190acc 100755 --- a/apply-colors.sh +++ b/apply-colors.sh @@ -106,14 +106,44 @@ set_theme() { dset use-theme-background "false" } +# | +# | If terminal supports truecolor then we can show theme colors without applying the theme +# | =========================================== +if [[ "${COLORTERM:-}" == "truecolor" ]] || [[ "${COLORTERM:-}" == "24bit" ]]; then + # gogh_colors have been moved here to avoid multiple definitions + function gogh_colors () { + echo + # Note: {01..16} does not work on OSX + for c in $(seq -s " " -w 16); do + local color="COLOR_$c" + set -- $(hexRGBtoDecRGB "${!color}") + echo -ne "\033[38;2;${1};${2};${3}m█████$(tput sgr0)" + [[ ${GOGH_DRY_RUN:-0} -eq 1 ]] && declare -g DEMO_COLOR_${c}="\033[38;2;${1};${2};${3}m" + [[ "$c" == "08" ]] && echo # new line + done + echo -e "\n\n" + } +else + function gogh_colors () { + echo + for c in {0..15}; do + echo -n "$(tput setaf $c)█████$(tput sgr0)" + [[ $c == 7 ]] && echo # new line + done + echo -e "\n\n" + } +fi + + # | # | Print theme colors # | =========================================== -if command -v gogh_truecolor > /dev/null; then - gogh_truecolor -else - gogh_colors -fi +gogh_colors +[[ ${GOGH_DRY_RUN:-0} -eq 1 ]] && color + +# End here if dry run was initiated +[[ ${GOGH_DRY_RUN:-0} -eq 1 ]] && return 0 + # | # | Apply color scheme to terminal diff --git a/gogh.sh b/gogh.sh index 5ce6125..dc991e8 100755 --- a/gogh.sh +++ b/gogh.sh @@ -170,20 +170,8 @@ declare -a THEMES=( 'zenburn.sh' ) - -cleanup() { - echo - echo "Cleaning up" - rm -rf "$scratchdir" - unset TERMINAL LOOP OPTLENGTH - echo "Done..." - exit 0 -} - -scratchdir=$(mktemp -d -t tmp.XXXXXXXX) -export scratchdir -trap 'cleanup; trap - EXIT' EXIT HUP INT QUIT PIPE TERM - +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} capitalize() { local ARGUMENT=$1 @@ -201,53 +189,72 @@ capitalize() { echo "${RES_NO_TRAIL_SPACE}" } -curlsource() { - local F - F=$(mktemp -t curlsource) - curl -o "$F" -s -L "$1" - source "$F" - rm -f "$F" -} set_gogh() { string=$1 string_r="${string%???}" string_s=${string_r//\./_} result=$(capitalize "${string_s}") - url="https://raw.githubusercontent.com/Mayccoll/Gogh/master/themes/$1" + url="${BASE_URL}/themes/$1" export {PROFILE_NAME,PROFILE_SLUG}="$result" # Evaluate if Gogh was called from local source - i.e cloned repo SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" if [ -e "$SCRIPT_PATH/themes/$1" ]; then - bash "$SCRIPT_PATH/themes/$1" + eval "$SCRIPT_PATH/themes/$1" else if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl - # Note: sourcing directly from curl does not work - curlsource "${url}" + eval "$(curl -so- "${url}")" else - bash <(wget -O - "${url}") + eval "$(wget -qO- "${url}")" fi fi } + remove_file_extension (){ echo "${1%.*}" } + ### Get length of an array ARRAYLENGTH=${#THEMES[@]} NUM=1 + # | -# | ::::::: Print Colors +# | ::::::: Print logo # | -echo -e " -Gogh\n -\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m -\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" +tput clear +if [[ ${COLUMNS:-$(tput cols)} -ge 80 ]]; then + echo " " + echo " █████████ █████ " + echo " ███ ███ ███ " + echo " ███ ██████ ███████ ███████ " + echo " ███ ███ ███ ███ ███ ███ ███ " + echo " ███ █████ ███ ███ ███ ███ ███ ███ " + echo " ███ ███ ███ ███ ███ ███ ███ ███ " + echo " █████████ ██████ ███████ ████ █████ " + echo " $(tput setaf 0)█████████$(tput setaf 1)█████████$(tput setaf 2)█████████$(tput setaf 3)█████████$(tput setaf 4)█████$(tput sgr 0)███$(tput setaf 4)█$(tput setaf 5)█████████$(tput setaf 6)█████████$(tput setaf 7)█████████ " + echo " $(tput setaf 0)█████████$(tput setaf 1)█████████$(tput setaf 2)█████████$(tput setaf 3)█████████$(tput sgr 0)███$(tput setaf 4)██$(tput sgr 0)███$(tput setaf 4)█$(tput setaf 5)█████████$(tput setaf 6)█████████$(tput setaf 7)█████████ " + echo " $(tput setaf 0)█████████$(tput setaf 1)█████████$(tput setaf 2)█████████$(tput setaf 3)█████████$(tput setaf 4)█$(tput sgr0)██████$(tput setaf 4)██$(tput setaf 5)█████████$(tput setaf 6)█████████$(tput setaf 7)█████████ " + echo " $(tput setaf 8)█████████$(tput setaf 9)█████████$(tput setaf 10)█████████$(tput setaf 11)█████████$(tput setaf 12)█████████$(tput setaf 13)█████████$(tput setaf 14)█████████$(tput setaf 15)█████████$(tput sgr 0) " + echo " $(tput setaf 8)█████████$(tput setaf 9)█████████$(tput setaf 10)█████████$(tput setaf 11)█████████$(tput setaf 12)█████████$(tput setaf 13)█████████$(tput setaf 14)█████████$(tput setaf 15)█████████$(tput sgr 0) " + echo " $(tput setaf 8)█████████$(tput setaf 9)█████████$(tput setaf 10)█████████$(tput setaf 11)█████████$(tput setaf 12)█████████$(tput setaf 13)█████████$(tput setaf 14)█████████$(tput setaf 15)█████████$(tput sgr 0) " + echo " " + + sleep 2.5 +else + echo -e "\nGogh\n" + for c in {0..15}; do + echo -n "$(tput setaf $c)█████$(tput sgr0)" + [[ $c == 7 ]] && echo # new line + done + echo +fi + # | # | ::::::: Print Themes @@ -260,19 +267,22 @@ for TH in "${THEMES[@]}"; do FILENAME=${TH::$((${#TH}-3))} FILENAME_SPACE=${FILENAME//-/ } - echo -e " (\\033[0m\033[0;34m $KEY \\033[0m\033[0m) $(capitalize "${FILENAME_SPACE}")" + echo -e " ($(tput setaf 4) $KEY $(tput sgr0)) $(capitalize "${FILENAME_SPACE}")" ((NUM++)) done + echo -e " ($(tput setaf 4) ALL $(tput sgr0)) All themes" # | # | ::::::: Select Option # | -echo -e "\nUsage : Enter Desired Themes Numbers (\\033[0m\033[0;34mOPTIONS\\033[0m\033[0m) Separated By A Blank Space" -echo -e " Press \033[0;34mENTER\\033[0m without options to Exit\n" +echo -e "\nUsage : Enter Desired Themes Numbers ($(tput setaf 4)OPTIONS$(tput sgr0)) Separated By A Blank Space" +echo -e " Press $(tput setaf 4)ENTER$(tput sgr0) without options to Exit\n" read -r -p 'Enter OPTION(S) : ' -a OPTION +# Automagically generate options if user opts for all themes +[[ "$OPTION" == ALL ]] && OPTION=($(seq -s " " $ARRAYLENGTH)) # | # | ::::::: Get terminal @@ -280,7 +290,7 @@ read -r -p 'Enter OPTION(S) : ' -a OPTION # | # | Check for the terminal name (depening on os) # | =========================================== -OS=$(uname) +OS="$(uname)" if [ "$OS" = "Darwin" ]; then # | # | Check for the terminal name and decide how to apply @@ -301,34 +311,49 @@ else done fi + +# | +# | ::::::: Fancy progressbar for lengthy operations +# | +if [[ ${#OPTION[@]} -gt 5 ]]; then + if [ "$(uname)" = "Darwin" ]; then + eval "$(curl -sLo- "https://git.io/progressbar")" 2> /dev/null + else + eval "$(wget -qO- "https://git.io/progressbar")" 2> /dev/null + fi +fi + + # | # | Tilix supports fg/bg in color schemes - ask wether user wants to go that route # | This is to avoid creating multiple profiles just for colors # | =========================================== -if [[ "$TERMINAL" = "tilix" ]]; then +if [[ "$TERMINAL" = "tilix" ]] && [[ ${#OPTION[@]} -gt 0 ]]; then echo read -r -p "Tilix detected - use color schemes instead of profiles? [y/N] " -n 1 TILIX_RES echo + + # | + # | When selecting multiple themes and user opts for color schemes, we save all themes + # | in a tmpdir and copy the files once all themes has been processed.. If a user + # | desides to abort before all themes has been processed this section will cleanup the tmpdir + # | ======================================= + if [[ ${TILIX_RES::1} =~ ^(y|Y)$ ]]; then + cleanup() { + echo + echo "Cleaning up" + rm -rf "$scratchdir" + unset LOOP OPTLENGTH + echo "Done..." + exit 0 + } + + scratchdir=$(mktemp -d -t tmp.XXXXXXXX) + export scratchdir + trap 'cleanup; trap - EXIT' EXIT HUP INT QUIT PIPE TERM + fi fi -# | -# | If terminal supports truecolor then we can show theme colors without applying the theme -# | =========================================== -if [[ "${COLORTERM:-}" == "truecolor" ]] || [[ "${COLORTERM:-}" == "24bit" ]]; then - # This function gets called in apply-colors.sh instead of gogh_colors - # Calls to gogh_colors has also been move to apply-colors.sh to avoid printing twice - function gogh_truecolor () { - # Note: {01..16} does not work on OSX - for c in $(seq -s " " -w 16); do - local color="COLOR_$c" - set -- $(hexRGBtoDecRGB "${!color}") - echo -ne "\033[38;2;${1};${2};${3}m█████\033[0m" - [[ "$c" == "08" ]] && echo # new line - done - echo -e "\n\n" - } - export -f gogh_truecolor -fi # | # | ::::::: Export one-off variables @@ -336,6 +361,7 @@ fi [[ -n "${TILIX_RES:-}" ]] && export TILIX_RES export TERMINAL LOOP OPTLENGTH=${#OPTION[@]} + # | # | ::::::: Apply Theme # | @@ -344,19 +370,27 @@ export TERMINAL LOOP OPTLENGTH=${#OPTION[@]} # Constants with a leading 0 are interpreted as octal numbers # Hence option 08 and 09 will not work # Solution is to remove the leading 0 from the parsed options +bar::start 2> /dev/null for OP in "${OPTION[@]#0}"; do # See Tilix section in apply-colors.sh for usage of LOOP LOOP=$((${LOOP:-0}+1)) + bar::status_changed $LOOP ${#OPTION[@]} 2> /dev/null if [[ OP -le ARRAYLENGTH && OP -gt 0 ]]; then FILENAME=$(remove_file_extension "${THEMES[((OP-1))]}") FILENAME_SPACE="${FILENAME//-/ }" - echo -e "\nTheme: $(capitalize "${FILENAME_SPACE}")\n\033[0;30m•\\033[0m\033[0;31m•\\033[0m\033[0;32m•\\033[0m\033[0;33m•\\033[0m\033[0;34m•\\033[0m\033[0;35m•\\033[0m\033[0;36m•\\033[0m\033[0;37m•\\033[0m \033[0;37m•\\033[0m\033[0;36m•\\033[0m\033[0;35m•\\033[0m\033[0;34m•\\033[0m\033[0;33m•\\033[0m\033[0;32m•\\033[0m\033[0;31m•\\033[0m\033[0;30m•\\033[0m\n" + echo -e "\nTheme: $(capitalize "${FILENAME_SPACE}")" + for c in {0..15}; do + echo -n "$(tput setaf $c)•$(tput sgr0)" + [[ $c == 7 ]] && echo -n " " + done + echo SET_THEME="${THEMES[((OP-1))]}" set_gogh "${SET_THEME}" else - echo -e "\\033[0m\033[0;31m ~ INVALID OPTION! ~\\033[0m\033[0m" + echo -e "$(tput setaf 1) ~ INVALID OPTION! ~$(tput sgr0)" exit 1 fi done +bar::stop 2> /dev/null \ No newline at end of file diff --git a/test/print-themes.sh b/test/print-themes.sh new file mode 100644 index 0000000..d75b2ec --- /dev/null +++ b/test/print-themes.sh @@ -0,0 +1,295 @@ +#!/usr/bin/env bash + +if [[ "${COLORTERM:-}" != "truecolor" ]] && [[ "${COLORTERM:-}" != "24bit" ]]; then + echo "TrueColor support is needed for this to function" + echo "You can try to manually set COLORTERM to truecolor" + exit 1 +fi + +# Reset color +RS="$(tput sgr0)" + +# Print all themes without applying, this variable gets checked in apply-colors.sh +export GOGH_DRY_RUN=1 + +color () { + # echo "" + #black + echo -e "${DEMO_COLOR_01} ███ *** AaBbCs --- ███ ${RS} ---> Color 01 'tput setaf 0'" + #red + echo -e "${DEMO_COLOR_02} ███ *** AaBbCs --- ███ ${RS} ---> Color 02 'tput setaf 1'" + #green + echo -e "${DEMO_COLOR_03} ███ *** AaBbCs --- ███ ${RS} ---> Color 03 'tput setaf 2'" + #yellow + echo -e "${DEMO_COLOR_04} ███ *** AaBbCs --- ███ ${RS} ---> Color 04 'tput setaf 3'" + #blue + echo -e "${DEMO_COLOR_05} ███ *** AaBbCs --- ███ ${RS} ---> Color 05 'tput setaf 4'" + #purple + echo -e "${DEMO_COLOR_06} ███ *** AaBbCs --- ███ ${RS} ---> Color 06 'tput setaf 5'" + #cyan + echo -e "${DEMO_COLOR_07} ███ *** AaBbCs --- ███ ${RS} ---> Color 07 'tput setaf 6'" + #white + echo -e "${DEMO_COLOR_08} ███ *** AaBbCs --- ███ ${RS} ---> Color 08 'tput setaf 7'" + echo "" + #black + echo -e "${DEMO_COLOR_09} ███ *** AaBbCs --- ███ ${RS} ---> Color 09 'tput setaf 8'" + #red + echo -e "${DEMO_COLOR_10} ███ *** AaBbCs --- ███ ${RS} ---> Color 10 'tput setaf 9'" + #green + echo -e "${DEMO_COLOR_11} ███ *** AaBbCs --- ███ ${RS} ---> Color 11 'tput setaf 10'" + #yellow + echo -e "${DEMO_COLOR_12} ███ *** AaBbCs --- ███ ${RS} ---> Color 12 'tput setaf 11'" + #blue + echo -e "${DEMO_COLOR_13} ███ *** AaBbCs --- ███ ${RS} ---> Color 13 'tput setaf 12'" + #purple + echo -e "${DEMO_COLOR_14} ███ *** AaBbCs --- ███ ${RS} ---> Color 14 'tput setaf 13'" + #cyan + echo -e "${DEMO_COLOR_15} ███ *** AaBbCs --- ███ ${RS} ---> Color 15 'tput setaf 14'" + #white + echo -e "${DEMO_COLOR_16} ███ *** AaBbCs --- ███ ${RS} ---> Color 16 'tput setaf 15'" + echo "" +} + +export -f color + +declare -a THEMES=( + '3024-day.sh' + '3024-night.sh' + 'aci.sh' + 'aco.sh' + 'adventuretime.sh' + 'afterglow.sh' + 'alien-blood.sh' + 'argonaut.sh' + 'arthur.sh' + 'atom.sh' + 'azu.sh' + 'belafonte-day.sh' + 'belafonte-night.sh' + 'bim.sh' + 'birds-of-paradise.sh' + 'blazer.sh' + 'borland.sh' + 'broadcast.sh' + 'brogrammer.sh' + 'c64.sh' + 'cai.sh' + 'chalk.sh' + 'chalkboard.sh' + 'ciapre.sh' + 'clone-of-ubuntu.sh' + 'clrs.sh' + 'cobalt-neon.sh' + 'cobalt2.sh' + 'crayon-pony-fish.sh' + 'dark-pastel.sh' + 'darkside.sh' + 'desert.sh' + 'dimmed-monokai.sh' + 'dracula.sh' + 'earthsong.sh' + 'elemental.sh' + 'elementary.sh' + 'elic.sh' + 'elio.sh' + 'espresso-libre.sh' + 'espresso.sh' + 'fishtank.sh' + 'flat.sh' + 'flatland.sh' + 'foxnightly.sh' + 'freya.sh' + 'frontend-delight.sh' + 'frontend-fun-forrest.sh' + 'frontend-galaxy.sh' + 'github.sh' + 'google-dark.sh' + 'google-light.sh' + 'gooey.sh' + 'grape.sh' + 'grass.sh' + 'gruvbox-dark.sh' + 'gruvbox.sh' + 'hardcore.sh' + 'harper.sh' + 'hemisu-dark.sh' + 'hemisu-light.sh' + 'highway.sh' + 'hipster-green.sh' + 'homebrew.sh' + 'hurtado.sh' + 'hybrid.sh' + 'ic-green-ppl.sh' + 'ic-orange-ppl.sh' + 'idle-toes.sh' + 'ir-black.sh' + 'jackie-brown.sh' + 'japanesque.sh' + 'jellybeans.sh' + 'jup.sh' + 'kibble.sh' + 'later-this-evening.sh' + 'lavandula.sh' + 'liquid-carbon-transparent.sh' + 'liquid-carbon.sh' + 'man-page.sh' + 'mar.sh' + 'material.sh' + 'mathias.sh' + 'medallion.sh' + 'misterioso.sh' + 'miu.sh' + 'molokai.sh' + 'mona-lisa.sh' + 'monokai-dark.sh' + 'monokai-soda.sh' + 'n0tch2k.sh' + 'neopolitan.sh' + 'nep.sh' + 'neutron.sh' + 'nightlion-v1.sh' + 'nightlion-v2.sh' + 'nighty.sh' + 'nord-light.sh' + 'nord.sh' + 'novel.sh' + 'obsidian.sh' + 'ocean-dark.sh' + 'ocean.sh' + 'oceanic-next.sh' + 'ollie.sh' + 'one-dark.sh' + 'one-half-black.sh' + 'one-light.sh' + 'pali.sh' + 'paraiso-dark.sh' + 'paul-millr.sh' + 'pencil-dark.sh' + 'pencil-light.sh' + 'peppermint.sh' + 'pnevma.sh' + 'pro.sh' + 'red-alert.sh' + 'red-sands.sh' + 'rippedcasts.sh' + 'royal.sh' + 'sat.sh' + 'sea-shells.sh' + 'seafoam-pastel.sh' + 'seti.sh' + 'shaman.sh' + 'shel.sh' + 'slate.sh' + 'smyck.sh' + 'snazzy.sh' + 'soft-server.sh' + 'solarized-darcula.sh' + 'solarized-dark-higher-contrast.sh' + 'solarized-dark.sh' + 'solarized-light.sh' + 'spacedust.sh' + 'spacegray-eighties-dull.sh' + 'spacegray-eighties.sh' + 'spacegray.sh' + 'spring.sh' + 'square.sh' + 'srcery.sh' + 'sundried.sh' + 'symphonic.sh' + 'teerb.sh' + 'terminal-basic.sh' + 'terminix-dark.sh' + 'thayer-bright.sh' + 'tin.sh' + 'tomorrow-night-blue.sh' + 'tomorrow-night-bright.sh' + 'tomorrow-night-eighties.sh' + 'tomorrow-night.sh' + 'tomorrow.sh' + 'toy-chest.sh' + 'treehouse.sh' + 'twilight.sh' + 'ura.sh' + 'urple.sh' + 'vag.sh' + 'vaughn.sh' + 'vibrant-ink.sh' + 'warm-neon.sh' + 'wez.sh' + 'wild-cherry.sh' + 'wombat.sh' + 'wryan.sh' + 'zenburn.sh' +) + +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +capitalize() { + local ARGUMENT=$1 + local RES="" + local STR="" + local RES_NO_TRAIL_SPACE="" + + for CHAR in $ARGUMENT + do + STR=$(echo "${CHAR:0:1}" | tr "[:lower:]" "[:upper:]")"${CHAR:1} " + RES="${RES}${STR}" + RES_NO_TRAIL_SPACE="$(echo -e "${RES}" | sed -e 's/[[:space:]]*$//')" + done + + echo "${RES_NO_TRAIL_SPACE}" +} + +set_gogh() { + url="https://raw.githubusercontent.com/Mayccoll/Gogh/master/themes/$1" + + # Evaluate if Gogh was called from local source - i.e cloned repo + SCRIPT_PATH="$( cd "../$( dirname "${BASH_SOURCE[0]}" )" && pwd )" + if [ -e "$SCRIPT_PATH/themes/$1" ]; then + eval "$SCRIPT_PATH/themes/$1" + else + if [ "$(uname)" = "Darwin" ]; then + # OSX ships with curl + eval "$(curl -so- "${url}")" + else + eval "$(wget -qO- "${url}")" + fi + fi +} + +remove_file_extension (){ + echo "${1%.*}" +} + +# Fancy progress bar +if [ "$(uname)" = "Darwin" ]; then + # OSX ships with curl + eval "$(curl -sLo- "https://git.io/progressbar")" 2> /dev/null +else + eval "$(wget -qO- "https://git.io/progressbar")" 2> /dev/null +fi + +bar::start 2> /dev/null + +for THEME in "${THEMES[@]}"; do + LOOP=$((${LOOP:-(-1)}+1)) + bar::status_changed $LOOP ${#THEMES[@]} 2> /dev/null + + FILENAME=$(remove_file_extension "${THEME}") + FILENAME_SPACE="${FILENAME//-/ }" + echo -e "\nTheme: $(capitalize "${FILENAME_SPACE}")" + for c in {0..15}; do + echo -n "$(tput setaf $c)•$(tput sgr0)" + [[ $c == 7 ]] && echo -n " " + done + echo + set_gogh "${THEME}" +done + +LOOP=$((${LOOP:-(-1)}+1)) +bar::status_changed $LOOP ${#THEMES[@]} 2> /dev/null + +bar::stop 2> /dev/null + +unset GOGH_DRY_RUN \ No newline at end of file diff --git a/themes/3024-day.sh b/themes/3024-day.sh index 0e6ed27..c150c4d 100755 --- a/themes/3024-day.sh +++ b/themes/3024-day.sh @@ -34,32 +34,22 @@ PROFILE_NAME="3024 Day" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/3024-night.sh b/themes/3024-night.sh index 7d3f89d..3b6a2b8 100755 --- a/themes/3024-night.sh +++ b/themes/3024-night.sh @@ -34,32 +34,22 @@ PROFILE_NAME="3024 Night" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/_base.sh b/themes/_base.sh index b75e2b4..62c2152 100755 --- a/themes/_base.sh +++ b/themes/_base.sh @@ -34,34 +34,22 @@ PROFILE_NAME="_base" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} -if [ -e $PARENT_PATH"/apply-colors.sh" ] + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] then - source $PARENT_PATH"/apply-colors.sh" + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/aci.sh b/themes/aci.sh index 429e5c7..455c21c 100755 --- a/themes/aci.sh +++ b/themes/aci.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Aci" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/aco.sh b/themes/aco.sh index 40bd595..71228d3 100755 --- a/themes/aco.sh +++ b/themes/aco.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Aco" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/adventuretime.sh b/themes/adventuretime.sh index 15c6bcc..85f74bd 100755 --- a/themes/adventuretime.sh +++ b/themes/adventuretime.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Adventure Time" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/afterglow.sh b/themes/afterglow.sh index 8657336..0175668 100755 --- a/themes/afterglow.sh +++ b/themes/afterglow.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Afterglow" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/alien-blood.sh b/themes/alien-blood.sh index e997fa0..d032939 100755 --- a/themes/alien-blood.sh +++ b/themes/alien-blood.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Alien Blood" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/argonaut.sh b/themes/argonaut.sh index 78f4cf4..a89853a 100755 --- a/themes/argonaut.sh +++ b/themes/argonaut.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Argonaut" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/arthur.sh b/themes/arthur.sh index 39c3ef0..c66bb9f 100755 --- a/themes/arthur.sh +++ b/themes/arthur.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Arthur" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/atom.sh b/themes/atom.sh index 0889cfa..2a30ddc 100755 --- a/themes/atom.sh +++ b/themes/atom.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Atom" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/azu.sh b/themes/azu.sh index 759a294..d608ff8 100755 --- a/themes/azu.sh +++ b/themes/azu.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Azu" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/belafonte-day.sh b/themes/belafonte-day.sh index ffc1355..900aba5 100755 --- a/themes/belafonte-day.sh +++ b/themes/belafonte-day.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Belafonte Day" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/belafonte-night.sh b/themes/belafonte-night.sh index 5facaaa..b0f31bc 100755 --- a/themes/belafonte-night.sh +++ b/themes/belafonte-night.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Belafonte Night" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/bim.sh b/themes/bim.sh index b0bf219..9ab3ac9 100755 --- a/themes/bim.sh +++ b/themes/bim.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Bim" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/birds-of-paradise.sh b/themes/birds-of-paradise.sh index ceb1538..8c4def3 100755 --- a/themes/birds-of-paradise.sh +++ b/themes/birds-of-paradise.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Birds Of Paradise" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/blazer.sh b/themes/blazer.sh index 379968f..7b47137 100755 --- a/themes/blazer.sh +++ b/themes/blazer.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Blazer" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/borland.sh b/themes/borland.sh index a9ab2df..98f1943 100755 --- a/themes/borland.sh +++ b/themes/borland.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Borland" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/broadcast.sh b/themes/broadcast.sh index c400767..7f20c1e 100755 --- a/themes/broadcast.sh +++ b/themes/broadcast.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Broadcast" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/brogrammer.sh b/themes/brogrammer.sh index 83e7a5f..0ed208d 100755 --- a/themes/brogrammer.sh +++ b/themes/brogrammer.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Brogrammer" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/c64.sh b/themes/c64.sh index 81c1fd5..7746d05 100755 --- a/themes/c64.sh +++ b/themes/c64.sh @@ -34,32 +34,22 @@ PROFILE_NAME="C64" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/cai.sh b/themes/cai.sh index e095dd6..da31077 100755 --- a/themes/cai.sh +++ b/themes/cai.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Cai" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/chalk.sh b/themes/chalk.sh index b45b10f..51d9173 100755 --- a/themes/chalk.sh +++ b/themes/chalk.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Chalk" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/chalkboard.sh b/themes/chalkboard.sh index cac0472..a3159bf 100755 --- a/themes/chalkboard.sh +++ b/themes/chalkboard.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Chalkboard" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/ciapre.sh b/themes/ciapre.sh index 0b664cc..abf5700 100755 --- a/themes/ciapre.sh +++ b/themes/ciapre.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Ciapre" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/clone-of-ubuntu.sh b/themes/clone-of-ubuntu.sh index 21f83af..4c2afd2 100755 --- a/themes/clone-of-ubuntu.sh +++ b/themes/clone-of-ubuntu.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Clone of Ubuntu" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} -if [ -e $PARENT_PATH"/apply-colors.sh" ] + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] then - source $PARENT_PATH"/apply-colors.sh" + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/clrs.sh b/themes/clrs.sh index fb01cba..08a065c 100755 --- a/themes/clrs.sh +++ b/themes/clrs.sh @@ -34,32 +34,22 @@ PROFILE_NAME="CLRS" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/cobalt-neon.sh b/themes/cobalt-neon.sh index 828436f..d1f9521 100755 --- a/themes/cobalt-neon.sh +++ b/themes/cobalt-neon.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Cobalt Neon" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/cobalt2.sh b/themes/cobalt2.sh index cc20fb6..58b4f9d 100755 --- a/themes/cobalt2.sh +++ b/themes/cobalt2.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Cobalt 2" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/crayon-pony-fish.sh b/themes/crayon-pony-fish.sh index 87e30c4..a088a10 100755 --- a/themes/crayon-pony-fish.sh +++ b/themes/crayon-pony-fish.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Crayon Pony Fish" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/dark-pastel.sh b/themes/dark-pastel.sh index b665617..c13e80b 100755 --- a/themes/dark-pastel.sh +++ b/themes/dark-pastel.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Dark Pastel" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/darkside.sh b/themes/darkside.sh index b0b1986..8235198 100755 --- a/themes/darkside.sh +++ b/themes/darkside.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Darkside" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/desert.sh b/themes/desert.sh index b51ca6c..bb4c235 100755 --- a/themes/desert.sh +++ b/themes/desert.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Desert" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/dimmed-monokai.sh b/themes/dimmed-monokai.sh index fe1e592..ed4b09e 100755 --- a/themes/dimmed-monokai.sh +++ b/themes/dimmed-monokai.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Dimmed Monokai" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/dracula.sh b/themes/dracula.sh index 85a2476..16a6a54 100755 --- a/themes/dracula.sh +++ b/themes/dracula.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Dracula" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/earthsong.sh b/themes/earthsong.sh index fa831d8..ac4cc6d 100755 --- a/themes/earthsong.sh +++ b/themes/earthsong.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Earthsong" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/elemental.sh b/themes/elemental.sh index f6f7a2d..fd91ac4 100755 --- a/themes/elemental.sh +++ b/themes/elemental.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Elemental" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/elementary.sh b/themes/elementary.sh index dce129e..59cbe04 100755 --- a/themes/elementary.sh +++ b/themes/elementary.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Elementary" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/elic.sh b/themes/elic.sh index e165f5f..2749ae1 100755 --- a/themes/elic.sh +++ b/themes/elic.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Elic" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/elio.sh b/themes/elio.sh index 145dcd6..9d47285 100755 --- a/themes/elio.sh +++ b/themes/elio.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Elio" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/espresso-libre.sh b/themes/espresso-libre.sh index 33fd34d..4361e67 100755 --- a/themes/espresso-libre.sh +++ b/themes/espresso-libre.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Espresso Libre" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/espresso.sh b/themes/espresso.sh index 95904a9..3ae9d3c 100755 --- a/themes/espresso.sh +++ b/themes/espresso.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Espresso" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/fishtank.sh b/themes/fishtank.sh index 26158c5..0fcbb2f 100755 --- a/themes/fishtank.sh +++ b/themes/fishtank.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Fishtank" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/flat.sh b/themes/flat.sh index a8812e3..95f1798 100755 --- a/themes/flat.sh +++ b/themes/flat.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Flat" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/flatland.sh b/themes/flatland.sh index 867b04b..a7bcd1b 100755 --- a/themes/flatland.sh +++ b/themes/flatland.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Flatland" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/foxnightly.sh b/themes/foxnightly.sh index 1f18201..1542f41 100755 --- a/themes/foxnightly.sh +++ b/themes/foxnightly.sh @@ -35,34 +35,22 @@ PROFILE_NAME="Foxnightly" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/freya.sh b/themes/freya.sh index d22f9fb..866c771 100755 --- a/themes/freya.sh +++ b/themes/freya.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Freya" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/frontend-delight.sh b/themes/frontend-delight.sh index d20b571..c23cb88 100755 --- a/themes/frontend-delight.sh +++ b/themes/frontend-delight.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Frontend Delight" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/frontend-fun-forrest.sh b/themes/frontend-fun-forrest.sh index 1b6cccf..703f79e 100755 --- a/themes/frontend-fun-forrest.sh +++ b/themes/frontend-fun-forrest.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Frontend Fun Forrest" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/frontend-galaxy.sh b/themes/frontend-galaxy.sh index 77a358b..b12ee52 100755 --- a/themes/frontend-galaxy.sh +++ b/themes/frontend-galaxy.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Frontend Galaxy" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/github.sh b/themes/github.sh index 652f979..c697366 100755 --- a/themes/github.sh +++ b/themes/github.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Github" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/gooey.sh b/themes/gooey.sh index 2cc613b..ba56f00 100755 --- a/themes/gooey.sh +++ b/themes/gooey.sh @@ -34,34 +34,22 @@ PROFILE_NAME="gooey" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} -if [ -e $PARENT_PATH"/apply-colors.sh" ] + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] then - source $PARENT_PATH"/apply-colors.sh" + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/google-dark.sh b/themes/google-dark.sh old mode 100644 new mode 100755 index b0f954c..bba92a8 --- a/themes/google-dark.sh +++ b/themes/google-dark.sh @@ -34,34 +34,22 @@ PROFILE_NAME="base16: Google (dark)" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} -if [ -e $PARENT_PATH"/apply-colors.sh" ] + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] then - source $PARENT_PATH"/apply-colors.sh" + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/google-light.sh b/themes/google-light.sh old mode 100644 new mode 100755 index 0b85064..47d04f3 --- a/themes/google-light.sh +++ b/themes/google-light.sh @@ -34,34 +34,22 @@ PROFILE_NAME="base16: Google (light)" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} -if [ -e $PARENT_PATH"/apply-colors.sh" ] + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] then - source $PARENT_PATH"/apply-colors.sh" + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/grape.sh b/themes/grape.sh index 981da1a..a5679f5 100755 --- a/themes/grape.sh +++ b/themes/grape.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Grape" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/grass.sh b/themes/grass.sh index d44f0e9..3f291bd 100755 --- a/themes/grass.sh +++ b/themes/grass.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Grass" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/gruvbox-dark.sh b/themes/gruvbox-dark.sh index 8c01c61..12369cc 100755 --- a/themes/gruvbox-dark.sh +++ b/themes/gruvbox-dark.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Gruvbox Dark" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/gruvbox.sh b/themes/gruvbox.sh index e4a22a4..8328aa3 100755 --- a/themes/gruvbox.sh +++ b/themes/gruvbox.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Gruvbox" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/hardcore.sh b/themes/hardcore.sh index 0d32f79..1f3a374 100755 --- a/themes/hardcore.sh +++ b/themes/hardcore.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Hardcore" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/harper.sh b/themes/harper.sh index 7cddb38..fe11ed7 100755 --- a/themes/harper.sh +++ b/themes/harper.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Harper" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/hemisu-dark.sh b/themes/hemisu-dark.sh index 36c7fd5..5abc7f6 100755 --- a/themes/hemisu-dark.sh +++ b/themes/hemisu-dark.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Hemisu Dark" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/hemisu-light.sh b/themes/hemisu-light.sh index 3a7db60..d78a17e 100755 --- a/themes/hemisu-light.sh +++ b/themes/hemisu-light.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Hemisu Light" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/highway.sh b/themes/highway.sh index a550e6c..2fce8ba 100755 --- a/themes/highway.sh +++ b/themes/highway.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Highway" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/hipster-green.sh b/themes/hipster-green.sh index 67cfec1..f78d101 100755 --- a/themes/hipster-green.sh +++ b/themes/hipster-green.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Hipster Green" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/homebrew.sh b/themes/homebrew.sh index caa73e9..b70c634 100755 --- a/themes/homebrew.sh +++ b/themes/homebrew.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Homebrew" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/hurtado.sh b/themes/hurtado.sh index 43be000..bab3484 100755 --- a/themes/hurtado.sh +++ b/themes/hurtado.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Hurtado" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/hybrid.sh b/themes/hybrid.sh index 36b4050..6a071f1 100755 --- a/themes/hybrid.sh +++ b/themes/hybrid.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Hybrid" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/ic-green-ppl.sh b/themes/ic-green-ppl.sh index ef80277..bbda401 100755 --- a/themes/ic-green-ppl.sh +++ b/themes/ic-green-ppl.sh @@ -34,32 +34,22 @@ PROFILE_NAME="IC Green PPL" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/ic-orange-ppl.sh b/themes/ic-orange-ppl.sh index 3194e98..08571aa 100755 --- a/themes/ic-orange-ppl.sh +++ b/themes/ic-orange-ppl.sh @@ -34,32 +34,22 @@ PROFILE_NAME="IC Orange PPL" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/idle-toes.sh b/themes/idle-toes.sh index 2710a47..2d84b8a 100755 --- a/themes/idle-toes.sh +++ b/themes/idle-toes.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Idle Toes" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/ir-black.sh b/themes/ir-black.sh index 6940fba..f9ee7e9 100755 --- a/themes/ir-black.sh +++ b/themes/ir-black.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Ir Black" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/jackie-brown.sh b/themes/jackie-brown.sh index 14f8775..d1cf8a6 100755 --- a/themes/jackie-brown.sh +++ b/themes/jackie-brown.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Jackie Brown" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/japanesque.sh b/themes/japanesque.sh index 567c2eb..e3d54f3 100755 --- a/themes/japanesque.sh +++ b/themes/japanesque.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Japanesque" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/jellybeans.sh b/themes/jellybeans.sh index da1c34a..7cbbd6e 100755 --- a/themes/jellybeans.sh +++ b/themes/jellybeans.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Jellybeans" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/jup.sh b/themes/jup.sh index c23bd2b..0a6ed93 100755 --- a/themes/jup.sh +++ b/themes/jup.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Jup" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/kibble.sh b/themes/kibble.sh index 76bac53..2ed310b 100755 --- a/themes/kibble.sh +++ b/themes/kibble.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Kibble" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/later-this-evening.sh b/themes/later-this-evening.sh index 3d56718..ebd4cba 100755 --- a/themes/later-this-evening.sh +++ b/themes/later-this-evening.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Later This Evening" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/lavandula.sh b/themes/lavandula.sh index 3ac6e85..707c04f 100755 --- a/themes/lavandula.sh +++ b/themes/lavandula.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Lavandula" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/liquid-carbon-transparent.sh b/themes/liquid-carbon-transparent.sh index f1a284e..0761488 100755 --- a/themes/liquid-carbon-transparent.sh +++ b/themes/liquid-carbon-transparent.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Liquid Carbon Transparent" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/liquid-carbon.sh b/themes/liquid-carbon.sh index c276d57..f15703a 100755 --- a/themes/liquid-carbon.sh +++ b/themes/liquid-carbon.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Liquid Carbon" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/man-page.sh b/themes/man-page.sh index fa9fd84..6ce9163 100755 --- a/themes/man-page.sh +++ b/themes/man-page.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Man Page" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/mar.sh b/themes/mar.sh index 1ce28db..dea826f 100755 --- a/themes/mar.sh +++ b/themes/mar.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Mar" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/material.sh b/themes/material.sh index dc78dd1..07ce668 100755 --- a/themes/material.sh +++ b/themes/material.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Material" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/mathias.sh b/themes/mathias.sh index dd0c1b8..3ce1f2e 100755 --- a/themes/mathias.sh +++ b/themes/mathias.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Mathias" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/medallion.sh b/themes/medallion.sh index aba6369..1a91410 100755 --- a/themes/medallion.sh +++ b/themes/medallion.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Medallion" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/misterioso.sh b/themes/misterioso.sh index b36a968..d251104 100755 --- a/themes/misterioso.sh +++ b/themes/misterioso.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Misterioso" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/miu.sh b/themes/miu.sh index e24ec4e..83e0a81 100755 --- a/themes/miu.sh +++ b/themes/miu.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Miu" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/molokai.sh b/themes/molokai.sh index 9d6dbe6..555d4aa 100755 --- a/themes/molokai.sh +++ b/themes/molokai.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Molokai" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/mona-lisa.sh b/themes/mona-lisa.sh index fa8ff43..1913a95 100755 --- a/themes/mona-lisa.sh +++ b/themes/mona-lisa.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Mona Lisa" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/monokai-dark.sh b/themes/monokai-dark.sh index b72b651..d91560c 100755 --- a/themes/monokai-dark.sh +++ b/themes/monokai-dark.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Monokai Dark" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/monokai-soda.sh b/themes/monokai-soda.sh index f36dc11..e6ea323 100755 --- a/themes/monokai-soda.sh +++ b/themes/monokai-soda.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Monokai Soda" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/n0tch2k.sh b/themes/n0tch2k.sh index 47214df..8adeb18 100755 --- a/themes/n0tch2k.sh +++ b/themes/n0tch2k.sh @@ -34,32 +34,22 @@ PROFILE_NAME="N0tch2k" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/neopolitan.sh b/themes/neopolitan.sh index de410fc..82ddc9a 100755 --- a/themes/neopolitan.sh +++ b/themes/neopolitan.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Neopolitan" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/nep.sh b/themes/nep.sh index 48c0da8..58a8b1f 100755 --- a/themes/nep.sh +++ b/themes/nep.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Nep" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/neutron.sh b/themes/neutron.sh index b580d62..4fe8419 100755 --- a/themes/neutron.sh +++ b/themes/neutron.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Neutron" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/nightlion-v1.sh b/themes/nightlion-v1.sh index cfb27ad..e6fd2da 100755 --- a/themes/nightlion-v1.sh +++ b/themes/nightlion-v1.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Nightlion V1" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/nightlion-v2.sh b/themes/nightlion-v2.sh index 79aae5f..c2923dd 100755 --- a/themes/nightlion-v2.sh +++ b/themes/nightlion-v2.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Nightlion V2" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/nighty.sh b/themes/nighty.sh old mode 100644 new mode 100755 index 9457724..08c60aa --- a/themes/nighty.sh +++ b/themes/nighty.sh @@ -34,34 +34,22 @@ PROFILE_NAME="nighty" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} -if [ -e $PARENT_PATH"/apply-colors.sh" ] + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] then - source $PARENT_PATH"/apply-colors.sh" + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/nord-light.sh b/themes/nord-light.sh index 215e478..fc11d49 100755 --- a/themes/nord-light.sh +++ b/themes/nord-light.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Nord Light" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/nord.sh b/themes/nord.sh index d8be983..839f9fc 100755 --- a/themes/nord.sh +++ b/themes/nord.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Nord" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/novel.sh b/themes/novel.sh index 4188e89..faac7b1 100755 --- a/themes/novel.sh +++ b/themes/novel.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Novel" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/obsidian.sh b/themes/obsidian.sh index 368f54b..089aa13 100755 --- a/themes/obsidian.sh +++ b/themes/obsidian.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Obsidian" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/ocean-dark.sh b/themes/ocean-dark.sh index 6dce0cc..e0892ea 100755 --- a/themes/ocean-dark.sh +++ b/themes/ocean-dark.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Ocean Dark" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/ocean.sh b/themes/ocean.sh index 38f8475..4f10d52 100755 --- a/themes/ocean.sh +++ b/themes/ocean.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Ocean" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/oceanic-next.sh b/themes/oceanic-next.sh index 01065d5..c319a25 100755 --- a/themes/oceanic-next.sh +++ b/themes/oceanic-next.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Oceanic Next" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/ollie.sh b/themes/ollie.sh index 245cc43..2b920e2 100755 --- a/themes/ollie.sh +++ b/themes/ollie.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Ollie" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/one-dark.sh b/themes/one-dark.sh index 7819ac5..05d78ab 100755 --- a/themes/one-dark.sh +++ b/themes/one-dark.sh @@ -34,34 +34,22 @@ PROFILE_NAME="One Dark" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/one-half-black.sh b/themes/one-half-black.sh index d0b4be5..0815b23 100755 --- a/themes/one-half-black.sh +++ b/themes/one-half-black.sh @@ -36,34 +36,22 @@ PROFILE_NAME="One Half Black" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/one-light.sh b/themes/one-light.sh index a610627..4cc57ed 100755 --- a/themes/one-light.sh +++ b/themes/one-light.sh @@ -34,34 +34,22 @@ PROFILE_NAME="One Light" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/pali.sh b/themes/pali.sh index 43655ed..45e0ca3 100755 --- a/themes/pali.sh +++ b/themes/pali.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Pali" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/paraiso-dark.sh b/themes/paraiso-dark.sh index 53a56aa..8102ac5 100755 --- a/themes/paraiso-dark.sh +++ b/themes/paraiso-dark.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Paraiso Dark" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/paul-millr.sh b/themes/paul-millr.sh index 24956ff..a00da67 100755 --- a/themes/paul-millr.sh +++ b/themes/paul-millr.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Paul Millr" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/pencil-dark.sh b/themes/pencil-dark.sh index 2ab876f..d4c0116 100755 --- a/themes/pencil-dark.sh +++ b/themes/pencil-dark.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Pencil Dark" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/pencil-light.sh b/themes/pencil-light.sh index d4411d4..c0304fc 100755 --- a/themes/pencil-light.sh +++ b/themes/pencil-light.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Pencil Light" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/peppermint.sh b/themes/peppermint.sh index 87b5a47..78a8a3b 100755 --- a/themes/peppermint.sh +++ b/themes/peppermint.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Peppermint" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/pnevma.sh b/themes/pnevma.sh index 8a12bbb..0ee80e1 100755 --- a/themes/pnevma.sh +++ b/themes/pnevma.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Pnevma" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/pro.sh b/themes/pro.sh index 59d2362..e5fe983 100755 --- a/themes/pro.sh +++ b/themes/pro.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Pro" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/red-alert.sh b/themes/red-alert.sh index 0dd8e97..e244104 100755 --- a/themes/red-alert.sh +++ b/themes/red-alert.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Red Alert" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/red-sands.sh b/themes/red-sands.sh index 0008c12..70ed85c 100755 --- a/themes/red-sands.sh +++ b/themes/red-sands.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Red Sands" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/rippedcasts.sh b/themes/rippedcasts.sh index 52c25c5..b1b141a 100755 --- a/themes/rippedcasts.sh +++ b/themes/rippedcasts.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Rippedcasts" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/royal.sh b/themes/royal.sh index 824e88b..901374d 100755 --- a/themes/royal.sh +++ b/themes/royal.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Royal" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/sat.sh b/themes/sat.sh index 3305de5..0097242 100755 --- a/themes/sat.sh +++ b/themes/sat.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Sat" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/sea-shells.sh b/themes/sea-shells.sh index 9b7bb10..151afe3 100755 --- a/themes/sea-shells.sh +++ b/themes/sea-shells.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Sea Shells" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/seafoam-pastel.sh b/themes/seafoam-pastel.sh index 8a31caf..3d697cb 100755 --- a/themes/seafoam-pastel.sh +++ b/themes/seafoam-pastel.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Seafoam Pastel" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/seti.sh b/themes/seti.sh index ce6b286..aae9229 100755 --- a/themes/seti.sh +++ b/themes/seti.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Seti" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/shaman.sh b/themes/shaman.sh index 14d7bfe..8b613eb 100755 --- a/themes/shaman.sh +++ b/themes/shaman.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Shaman" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/shel.sh b/themes/shel.sh index 6aa1062..7cb7d58 100755 --- a/themes/shel.sh +++ b/themes/shel.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Shel" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/slate.sh b/themes/slate.sh index 807b526..5d0222f 100755 --- a/themes/slate.sh +++ b/themes/slate.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Slate" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/smyck.sh b/themes/smyck.sh index 17901f7..dea28e9 100755 --- a/themes/smyck.sh +++ b/themes/smyck.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Smyck" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/snazzy.sh b/themes/snazzy.sh old mode 100644 new mode 100755 index d2ed513..a18fb2e --- a/themes/snazzy.sh +++ b/themes/snazzy.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Snazzy" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/soft-server.sh b/themes/soft-server.sh index 58e21dc..62ac75e 100755 --- a/themes/soft-server.sh +++ b/themes/soft-server.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Soft Server" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/solarized-darcula.sh b/themes/solarized-darcula.sh index ead8e03..a039d8d 100755 --- a/themes/solarized-darcula.sh +++ b/themes/solarized-darcula.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Solarized Darcula" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/solarized-dark-higher-contrast.sh b/themes/solarized-dark-higher-contrast.sh index b7fa431..813bb18 100755 --- a/themes/solarized-dark-higher-contrast.sh +++ b/themes/solarized-dark-higher-contrast.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Solarized Dark Higher Contrast" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/solarized-dark.sh b/themes/solarized-dark.sh index 8e5e091..911ed3d 100755 --- a/themes/solarized-dark.sh +++ b/themes/solarized-dark.sh @@ -31,38 +31,25 @@ PROFILE_NAME="Solarized Dark" - # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/solarized-light.sh b/themes/solarized-light.sh index cf7e530..26ab38d 100755 --- a/themes/solarized-light.sh +++ b/themes/solarized-light.sh @@ -31,38 +31,25 @@ PROFILE_NAME="Solarized Light" - # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/spacedust.sh b/themes/spacedust.sh index 75ff498..608ec02 100755 --- a/themes/spacedust.sh +++ b/themes/spacedust.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Spacedust" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/spacegray-eighties-dull.sh b/themes/spacegray-eighties-dull.sh index e40cbe1..9b2b08c 100755 --- a/themes/spacegray-eighties-dull.sh +++ b/themes/spacegray-eighties-dull.sh @@ -34,32 +34,22 @@ PROFILE_NAME="SpaceGray Eighties Dull" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/spacegray-eighties.sh b/themes/spacegray-eighties.sh index 3e8d0ae..2f7da18 100755 --- a/themes/spacegray-eighties.sh +++ b/themes/spacegray-eighties.sh @@ -34,32 +34,22 @@ PROFILE_NAME="SpaceGray Eighties" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/spacegray.sh b/themes/spacegray.sh index b23885e..0e6187e 100755 --- a/themes/spacegray.sh +++ b/themes/spacegray.sh @@ -34,32 +34,22 @@ PROFILE_NAME="SpaceGray" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/spring.sh b/themes/spring.sh index 265230f..7715709 100755 --- a/themes/spring.sh +++ b/themes/spring.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Spring" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/square.sh b/themes/square.sh index 41e6e82..4c1daa5 100755 --- a/themes/square.sh +++ b/themes/square.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Square" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/srcery.sh b/themes/srcery.sh index 3002354..01848e1 100755 --- a/themes/srcery.sh +++ b/themes/srcery.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Srcery" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/sundried.sh b/themes/sundried.sh index 4e3222c..4aaacb5 100755 --- a/themes/sundried.sh +++ b/themes/sundried.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Sundried" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/symphonic.sh b/themes/symphonic.sh index 0b70fef..7e5a21a 100755 --- a/themes/symphonic.sh +++ b/themes/symphonic.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Symphonic" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/teerb.sh b/themes/teerb.sh index 2bf31ea..60508bb 100755 --- a/themes/teerb.sh +++ b/themes/teerb.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Teerb" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/terminal-basic.sh b/themes/terminal-basic.sh index a92e3b6..6bfb7fb 100755 --- a/themes/terminal-basic.sh +++ b/themes/terminal-basic.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Terminal Basic" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/terminix-dark.sh b/themes/terminix-dark.sh index 958cc58..84fedb5 100755 --- a/themes/terminix-dark.sh +++ b/themes/terminix-dark.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Terminix Dark" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/thayer-bright.sh b/themes/thayer-bright.sh index 3ca1d5f..16e5321 100755 --- a/themes/thayer-bright.sh +++ b/themes/thayer-bright.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Thayer Bright" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/tin.sh b/themes/tin.sh index ba3d584..299acfe 100755 --- a/themes/tin.sh +++ b/themes/tin.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Tin" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/tomorrow-night-blue.sh b/themes/tomorrow-night-blue.sh index 53fcbee..21f755a 100755 --- a/themes/tomorrow-night-blue.sh +++ b/themes/tomorrow-night-blue.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Tomorrow Night Blue" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/tomorrow-night-bright.sh b/themes/tomorrow-night-bright.sh index 6822362..e3a56b1 100755 --- a/themes/tomorrow-night-bright.sh +++ b/themes/tomorrow-night-bright.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Tomorrow Night Bright" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/tomorrow-night-eighties.sh b/themes/tomorrow-night-eighties.sh index 25d4e6c..bfbd15c 100755 --- a/themes/tomorrow-night-eighties.sh +++ b/themes/tomorrow-night-eighties.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Tomorrow Night Eighties" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/tomorrow-night.sh b/themes/tomorrow-night.sh index 20831c6..23dfaef 100755 --- a/themes/tomorrow-night.sh +++ b/themes/tomorrow-night.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Tomorrow Night" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/tomorrow.sh b/themes/tomorrow.sh index 18d22c3..66181ec 100755 --- a/themes/tomorrow.sh +++ b/themes/tomorrow.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Tomorrow" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/toy-chest.sh b/themes/toy-chest.sh index 305ccfb..0d7cd04 100755 --- a/themes/toy-chest.sh +++ b/themes/toy-chest.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Toy Chest" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/treehouse.sh b/themes/treehouse.sh index 4fdebd9..cf2772d 100755 --- a/themes/treehouse.sh +++ b/themes/treehouse.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Treehouse" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/twilight.sh b/themes/twilight.sh index e0d2976..465e4d9 100755 --- a/themes/twilight.sh +++ b/themes/twilight.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Twilight" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/ura.sh b/themes/ura.sh index 2c46b02..7b75190 100755 --- a/themes/ura.sh +++ b/themes/ura.sh @@ -34,34 +34,22 @@ PROFILE_NAME="Ura" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ] -then -source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/urple.sh b/themes/urple.sh index 142d4e9..c55eacd 100755 --- a/themes/urple.sh +++ b/themes/urple.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Urple" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/vag.sh b/themes/vag.sh index 1ff49af..4009fde 100755 --- a/themes/vag.sh +++ b/themes/vag.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Vag" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/vaughn.sh b/themes/vaughn.sh index e538378..286ddc7 100755 --- a/themes/vaughn.sh +++ b/themes/vaughn.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Vaughn" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/vibrant-ink.sh b/themes/vibrant-ink.sh index e1b1df5..77a8b69 100755 --- a/themes/vibrant-ink.sh +++ b/themes/vibrant-ink.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Vibrant Ink" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/warm-neon.sh b/themes/warm-neon.sh index 2922b62..ef367fd 100755 --- a/themes/warm-neon.sh +++ b/themes/warm-neon.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Warm Neon" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/wez.sh b/themes/wez.sh index 7958362..9eb6ab3 100755 --- a/themes/wez.sh +++ b/themes/wez.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Wez" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/wild-cherry.sh b/themes/wild-cherry.sh index 35499f9..e62cad3 100755 --- a/themes/wild-cherry.sh +++ b/themes/wild-cherry.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Wild Cherry" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/wombat.sh b/themes/wombat.sh index 543e65e..4886c10 100755 --- a/themes/wombat.sh +++ b/themes/wombat.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Wombat" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/wryan.sh b/themes/wryan.sh index f08093c..3097e14 100755 --- a/themes/wryan.sh +++ b/themes/wryan.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Wryan" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file diff --git a/themes/zenburn.sh b/themes/zenburn.sh index a9ca5e3..bb3290a 100755 --- a/themes/zenburn.sh +++ b/themes/zenburn.sh @@ -34,32 +34,22 @@ PROFILE_NAME="Zenburn" # =============================================================== # # | Apply Colors # ===============================================================|# -function gogh_colors () { - echo "" - echo -e "\033[0;30m█████\\033[0m\033[0;31m█████\\033[0m\033[0;32m█████\\033[0m\033[0;33m█████\\033[0m\033[0;34m█████\\033[0m\033[0;35m█████\\033[0m\033[0;36m█████\\033[0m\033[0;37m█████\\033[0m" - echo -e "\033[0m\033[1;30m█████\\033[0m\033[1;31m█████\\033[0m\033[1;32m█████\\033[0m\033[1;33m█████\\033[0m\033[1;34m█████\\033[0m\033[1;35m█████\\033[0m\033[1;36m█████\\033[0m\033[1;37m█████\\033[0m" - echo "" -} - -function curlsource() { - f=$(mktemp -t curlsource) - curl -o "$f" -s -L "$1" - source "$f" - rm -f "$f" -} - -SCRIPT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PARENT_PATH="$(dirname "$SCRIPT_PATH")" -if [ -e $PARENT_PATH"/apply-colors.sh" ]; then - source $PARENT_PATH"/apply-colors.sh" +# Allow developer to change url to forked url for easier testing +BASE_URL=${BASE_URL:-"https://raw.githubusercontent.com/Mayccoll/Gogh/master"} + + +if [ -e "${PARENT_PATH}/apply-colors.sh" ] +then + source "${PARENT_PATH}/apply-colors.sh" else - if [ $(uname) = "Darwin" ]; then + if [ "$(uname)" = "Darwin" ]; then # OSX ships with curl and ancient bash - # Note: here, sourcing directly from curl does not work - curlsource https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh + eval "$(curl -so- "${BASE_URL}/apply-colors.sh")" else # Linux ships with wget - source <(wget -O - https://raw.githubusercontent.com/Mayccoll/Gogh/master/apply-colors.sh) + eval "$(wget -qO- "${BASE_URL}/apply-colors.sh")" fi -fi +fi \ No newline at end of file