zshell:https://archive.codeplex.com/?p=shellhtml
oh-my-zsh: https://github.com/robbyrussell/oh-my-zshlinux
終極 Shell——Zsh: https://linuxtoy.org/archives/zsh.htmlgit
Linux終極shell-Z Shell--用強大的zsh & oh-my-zsh把Bash換掉: https://blog.csdn.net/gatieme/article/details/52741221github
xinchen@ubuntu:~$ cat /etc/shells # /etc/shells: valid login shells /bin/sh /bin/dash /bin/bash /bin/rbash /usr/bin/tmux /usr/bin/screen
sudo apt-get install zsh
# usermod命令用於修改用戶的基本信息 # # usermod -G staff newuser2 (將newuser2添加到組staff中) # usermod -l newuser1 newuser (修改newuser的用戶名爲newuser1) # usermod -L newuser1 (鎖定帳號newuser1) # usermod -U newuser1 (解除對newuser1的鎖定) sudo usermod -s /bin/ash $USERNAME # or chsh -s /bin/zsh chsh -s `which zsh` # 切換回bash chsh -s /bin/bash
Oh My Zsh is installed by running one of the following commands in your terminal. You can install this via the command-line with either curl
or wget
.shell
# curl sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)" # wget sh -c "$(wget https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh -O -)" # The default location is ~/.oh-my-zsh (hidden in your home directory) export ZSH="$HOME/.dotfiles/oh-my-zsh"; sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
# git clone git clone git://github.com/robbyrussell/oh-my-zsh.git ~/.oh-my-zsh # 備份已有的zshrc, 替換zshrc, 至此可直接使用 cp ~/.zshrc ~/.zshrc.orig cp ~/.oh-my-zsh/templates/zshrc.zsh-template ~/.zshrc # 直接使用腳本安裝 cd oh-my-zsh/tools ./install.sh
# Once you find a theme that you'd like to use, you will need to edit the ~/.zshrc file. You'll see an environment variable (all caps) in there that looks like: ZSH_THEME="robbyrussell" # If you're feeling feisty, you can let the computer select one randomly for you each time you open a new terminal window. ZSH_THEME="random" # (...please let it be pie... please be some pie..) # And if you want to pick random theme from a list of your favorite themes: ZSH_THEME_RANDOM_CANDIDATES=( "robbyrussell" "agnoster" )
# ~/.zshrc plugins=(git encode64 urltools)
# By default, you will be prompted to check for upgrades every few weeks. If you would like oh-my-zsh to automatically upgrade itself without prompting you, set the following in your ~/.zshrc: DISABLE_UPDATE_PROMPT=true # To disable automatic upgrades, set the following in your ~/.zshrc: DISABLE_AUTO_UPDATE=true # If you'd like to upgrade at any point in time (maybe someone just released a new plugin and you don't want to wait a week?) you just need to run: upgrade_oh_my_zsh
If you want to uninstall oh-my-zsh
, just run uninstall_oh_my_zsh
from the command-line. It will remove itself and revert your previous bash
or zsh
configuration.ubuntu