Skip to content

Commit

Permalink
condition tput colors
Browse files Browse the repository at this point in the history
  • Loading branch information
eliranm committed Jan 31, 2017
1 parent 57b24d5 commit 23f9dd1
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions gitflux-text
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
#!/usr/bin/env sh


# ansi-based text formatting utilities. use them in strings like:
# "${t_bold}bold text${t_off}, just normal text. ${t_fg_yellow}this text is yellow${t_off}"
# yay!
# ansi-based little text formatters.


t_off=$(tput sgr0)
Expand All @@ -28,3 +26,7 @@ if (( $tput_colors >= 8 )); then
t_fg_darkyellow=$(tput setaf 221)
fi
fi

# uncomment the following line to see what it does:
# "text can be ${t_bold}bold${t_off}, ${t_under}underlined${t_off}, or colored in ${t_fg_yellow}yellow${t_off} or ${t_fg_blue}blue${t_off}"
# yay!

0 comments on commit 23f9dd1

Please sign in to comment.