Instalando ZSH y Oh My Zsh en Mac y Linux
Vamos a potenciar tu terminal con ZSH y Oh My Zsh. Así se instalan en macOS y distribuciones Linux populares.
¿Qué son ZSH y Oh My Zsh?
- ZSH (Z Shell): un shell potente y extensible
- Oh My Zsh: framework para gestionar la configuración de ZSH (temas, plugins, etc.)
Instalando ZSH
En macOS
zsh --version
brew install zsh
En Linux
# Ubuntu/Debian
sudo apt update && sudo apt install zsh
# Fedora
sudo dnf install zsh
# Arch Linux
sudo pacman -S zsh
# CentOS/RHEL
sudo yum update && sudo yum install zsh
Definir ZSH como shell por defecto
chsh -s $(which zsh)
Instalar Oh My Zsh
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
o con wget:
sh -c "$(wget https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh -O -)"
Personalización
Tema
nano ~/.zshrc
ZSH_THEME="agnoster"
Plugins
plugins=(git docker composer npm sudo web-search)
(Opcional) Powerlevel10k
git clone --depth=1 https://github.com/romkatv/powerlevel10k.git ${ZSH_CUSTOM:-$HOME/.oh-my-zsh/custom}/themes/powerlevel10k
Y en .zshrc:
ZSH_THEME="powerlevel10k/powerlevel10k"
Con eso tendrás un terminal más rápido y productivo. Prueba distintos temas y plugins.