CS
fish shell을 기본 셸로 설정하기 (OSX, Linux)
judy@
2023. 7. 20. 16:01
아래 명령어로 파일을 열어, fish shell이 설치된 경로를 추가한다
$ sudo vi /etc/shells
# List of acceptable shells for chpass(1).
# Ftpd will not allow users to connect who are not using
# one of these shells.
/bin/bash
/bin/csh
/bin/dash
/bin/ksh
/bin/sh
/bin/tcsh
/bin/zsh
/opt/homebrew/bin/fish # 추가
설치 경로 보는 법 (나는 OSX, homebrew로 설치하여 경로가 저렇다, 다른 경로여도 상관없고 위와 똑같이 그 경로를 추가해주면 된다)
$ which fish
/opt/homebrew/bin/fish
fish를 기본 셸로 설정하기 (OS의 유저 계정에 대한 비밀번호를 입력하면 설정 완료)
$ chsh -s $(which fish)
Changing shell for leejuyeon.
Password for leejuyeon: ***
참고로 위에서 한 /etc/shells에 경로를 추가하는 작업을 해주지 않으면 다음과 같은 오류가 발생한다. (fish 셸 한정)
chsh: /opt/homebrew/bin/fish: non-standard shell
반응형