Skip to content

Instantly share code, notes, and snippets.

View mikezone's full-sized avatar
🎯
Focusing

Mike mikezone

🎯
Focusing
  • Galaxy.Inc
  • China
View GitHub Profile
@mikezone
mikezone / install-oh-my-zsh.sh
Created April 16, 2021 08:30 — forked from hewerthomn/install-oh-my-zsh.sh
Offline install of oh-my-zsh on Ubuntu
main() {
# Use colors, but only if connected to a terminal, and that terminal
# supports them.
if which tput >/dev/null 2>&1; then
ncolors=$(tput colors)
fi
if [ -t 1 ] && [ -n "$ncolors" ] && [ "$ncolors" -ge 8 ]; then
RED="$(tput setaf 1)"
GREEN="$(tput setaf 2)"
YELLOW="$(tput setaf 3)"