앨리스래빗팀 기술블로그

태그 글작성 관리
  • 홈
  • 태그
  • 방명록

BE/Linux

[ LINUX ] zsh 쉘 폴더 경로 축약 표시

HEON.D 2023. 1. 31. 21:43

https://unix.stackexchange.com/questions/651155/how-to-make-bash-zsh-prompt-show-only-the-current-directory-and-its-parent

 

How to make Bash/Zsh prompt show only the current directory and its parent?

How can I create a bash and a zsh prompt that shows only the current directory and its parent directory? For example, if I'm at the dir ~/pictures/photos/2021, it should show: [photos/2021]$ echo hi

unix.stackexchange.com

 

.zshrc 설정

PS1='[%2d] $ '

 

저작자표시 비영리 변경금지 (새창열림)

'BE > Linux' 카테고리의 다른 글

[ LINUX ] zshrc, alias를 효율적으로 관리하기  (0) 2023.10.23
[ Linux ] EB 리눅스 접속 간단 명령어  (0) 2023.06.03
[ LINUX ] 리눅스 다중 명령어  (0) 2022.12.16
[ Linux ] 터미널 매크로 만들기 - alias  (0) 2022.12.16
[ LINUX ] node version update  (0) 2022.08.19

'BE/Linux'의 다른글

  • 현재글[ LINUX ] zsh 쉘 폴더 경로 축약 표시

관련글

  • [ LINUX ] zshrc, alias를 효율적으로 관리하기 2023.10.23
  • [ Linux ] EB 리눅스 접속 간단 명령어 2023.06.03
  • [ LINUX ] 리눅스 다중 명령어 2022.12.16
  • [ Linux ] 터미널 매크로 만들기 - alias 2022.12.16
댓글

Calendar

«   2026/04   »
일 월 화 수 목 금 토
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30
  • 분류 전체보기
    • Team
      • GIT
      • TOOLS
      • 난감했던 이슈들
    • Design
      • 기업페이지
      • 커머스
      • Inspiration
      • UIUX
    • App
      • Flutter
      • Android
      • iOS
    • FE
      • Angular
      • Canvas
      • CSS
      • HTML
      • IONIC
      • Javascript
      • NodeJS
      • React
      • Next
      • Typescript
      • Vue
      • Plugins
    • BE
      • AWS
      • Java
      • Linux
      • Nest
      • OS
      • PHP
      • Python
      • Security
      • Network
    • DB
      • DB2
      • MongoDB
      • MYSQL
    • Inspirations
      • Art
      • Code
    • AI
      • openai

Archives

프로필사진

앨리스래빗팀 기술블로그입니다. https://alicerabbit.team

방문자수Total

  • Today :
  • Yesterday :

Tag

DB2, DART, git, ios, Web, CSS, ionic, node, vscode, HTML, RDS, AWS, Linux, Android, angular, 플러터, mysql, OSX, Flutter, Javascript,

최근글과 인기글

  • 최근글
  • 인기글

Copyright © AXZ Corp. All rights reserved.

  • 앨리스래빗

티스토리툴바