본문 바로가기
IT/Mac

zsh 꾸미기 for Mac

by DOSGamer 2022. 8. 23.
반응형

최신 macOS 에는 zsh 가 기본으로 설치되어 있습니다

zsh 테마는 .zshrc 파일을 수정해서 변경할 수 있습니다

zsh 의 플러그인과 테마를 편리하게 사용할 수 있는 oh-my-zsh 를 설치합니다

# oh-my-zsh 설치
sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"

ohmyzsh/ohmyzsh
🙃 A delightful community-driven (with 1500+ contributors) framework for managing your zsh configuration. Includes 200+ optional plugins (rails, git, OSX, hub, capistrano, brew, ant, php, python, etc), over 140 themes to spice up your morning, and an auto-update tool so that makes it easy to keep up with the latest updates from the community.
https://github.com/ohmyzsh/ohmyzsh/wiki/themes

oh-my-zsh 가 설치되면 여러가지 테마들이 기본으로 설치되어 있습니다

ohmyzsh 의 wiki 페이지에서 기본 테마들의 리스트를 볼 수 있습니다

ohmyzsh/ohmyzsh
🙃 A delightful community-driven (with 1500+ contributors) framework for managing your zsh configuration. Includes 200+ optional plugins (rails, git, OSX, hub, capistrano, brew, ant, php, python, etc), over 140 themes to spice up your morning, and an auto-update tool so that makes it easy to keep up with the latest updates from the community.
https://github.com/ohmyzsh/ohmyzsh/wiki/themes

테마 변경하기

~/.zshrc 파일 안에 ZSH_THEME=robbyrussell 을 다른 테마 명칭으로 변경하면 해당 테마가 적용됩니다

ZSH_THEME=agnoster 로 변경하면 하단의 테마를 사용할 수 있습니다

별도 테마 설정하기 (Dracula)

Dark theme for Zsh and 99+ apps - Dracula
Install using Git If you are a git user, you can install the theme and keep up to date by cloning the repo: $ git clone https://github.com/dracula/zsh.git And creating a symbolic link to oh-my-zsh's theme folder: $ ln -s $DRACULA_THEME/dracula.zsh-theme $OH_MY_ZSH/themes/dracula.zsh-theme P.S.: Remember that you should replace $DRACULA_THEME and $OH_MY_ZSH with the actual directories for this command to work.
https://draculatheme.com/zsh/

드라큐라 테마 사이트에서 3가지 방식의 설치 방법을 안내해주고 있습니다.

그 중에 Install manually 방식으로 설치합니다 (git 으로 설치 또는 zplug 로 설치해도 됨)

  1. 테마 파일을 다운로드 합니다
  1. 다운받은 파일을 압축을 풀고
  1. dracula.zsh-theme 파일은 ~/.oh-my-zsh/themes/dracula.zsh-theme 로 이동
  1. /lib 폴더는 ~/.oh-my-zsh/themes/lib 폴더로 이동
  1. ~/.zshrc 파일에 ZSH_THEME='dracula' 로 변경 합니다
# pwd 로 파일위치 확인
/Users/skyksit/Downloads/zsh-master

# dracula.zsh-theme 파일을 oh-my-zsh 의 themes 폴더로 이동
cp dracula.zsh-theme /Users/skyksit/.oh-my-zsh/themes

# lib 폴더를 복사
cp -R lib /Users/skyksit/.oh-my-zsh/themes

oh-my-zsh 플러그인 설치

zsh-syntax-highlighting : 명령어 하이라이팅

zsh-autosuggestions : 자동완성

# zsh-syntax-highlighting 설치
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting

# zsh-autosuggestions 설치
git clone git://github.com/zsh-users/zsh-autosuggestions $ZSH_CUSTOM/plugins/zsh-autosuggestions

플러그인 설정은 ~/.zshrc 파일에서 합니다

plugins=(
  git
  zsh-syntax-highlighting
  zsh-autosuggestions
)


Uploaded by N2T

반응형

'IT > Mac' 카테고리의 다른 글

photoscape x 로 collage 이미지 만들기  (0) 2023.04.12
iTerm2 실행속도 느려지면  (0) 2022.09.21
neovim 설치 for Mac  (0) 2022.08.23
화면 확대 for Mac  (0) 2022.08.23
osx keychain 설정 for Mac  (0) 2022.08.23
스크린샷 찍기 for Mac  (0) 2022.08.23
iTerm2 설치 for Mac  (0) 2022.08.23
OpenJDK 설치 for Mac  (0) 2022.08.23