black7375 / BlaCk-Void-Zsh

๐Ÿ”ฎ Awesome, Customable Zsh Starter Kit ๐ŸŒ ๐ŸŒ 
MIT License
339 stars 38 forks source link

[Question] how to unalias? #33

Closed everLEEst closed 2 years ago

everLEEst commented 2 years ago

It might be silly question, but after installed BlaCk-Void-Zsh, I couldn't unalias Oh-My-Zsh preset alias commend. I was unalias gbs in .zshrc but now it didn't work. I put same command on .BlaCk-Void.zshrc, but it didn't work.

where should I put the unalias command?

black7375 commented 2 years ago

What commands would you say? Generally, it will be possible.

everLEEst commented 2 years ago

์•ˆ๋…•ํ•˜์„ธ์š”. ์„ค๋ช…์ด ๊ธธ์–ด์งˆ ๊ฑฐ ๊ฐ™์•„์„œ ํ•œ๊ธ€๋กœ ๋ฌธ์˜ ๋“œ๋ฆฌ๊ฒ ์Šต๋‹ˆ๋‹ค.

๊ธฐ๋ณธ์ ์œผ๋กœ gbs๋ฅผ git bisect๊ฐ€ ์•„๋‹Œ ๋‹ค๋ฅธ ์‹คํ–‰ํŒŒ์ผ๋กœ ์‚ฌ์šฉํ•˜๊ณ  ์žˆ์–ด์„œ ํ˜„์žฌ .zshrc ์• ์„œ

unalias gbs

๋ฐ ๋‹ค๋ฅธ ๋ช…๋ น์–ด๋“ค์„ ์ˆ˜ํ–‰ํ•˜๊ณ  ์žˆ์Šต๋‹ˆ๋‹ค.

BlaCk-Void-Zsh ์„ค์น˜ ์ดํ›„ alias gbs ์‹œ gbs='git bisect' ๋กœ alias๊ฐ€ ์„ ์–ธ๋œ ๊ฒƒ์„ ํ™•์ธํ•˜์˜€์œผ๋ฉฐ(.zshrc์— ๋ช…๋ น์–ด๋Š” ์—ฌ์ „ํžˆ ์กด์žฌํ•จ)

๋””๋ฒ„๊น…์„ ์œ„ํ•ด ๊ตฌ๊ฐ„ ๊ตฌ๊ฐ„ echo๋ฅผ ๋„ฃ์–ด๋ณด๋‹ˆ unalias gbs๊นŒ์ง€๋Š” ์ˆ˜ํ–‰๋˜๋‚˜ source /home/sh10233lee/.zsh/BlaCk-Void.zshrc ์ดํ›„ ๋กœ๊ทธ๊ฐ€ ๋‚˜์˜ค์ง€ ์•Š๋Š” ์ƒํ™ฉ์ž…๋‹ˆ๋‹ค. ์ˆ˜ํ–‰์ค‘ ์˜ค๋ฅ˜๊ฐ€ ๋ฐœ์ƒํ•˜๋Š” ๊ฒŒ ์•„๋‹Œ๊ฐ€ ์˜์‹ฌ์ด ๋˜๋Š”๋ฐ ์„ค์น˜๊ฐ€ ๋ถˆ์™„์ „ํ•˜๊ฒŒ ๋œ ์ƒํ™ฉ์ธ๊ฑธ๊นŒ์š”?

์ถ”๊ฐ€ ํ…Œ์ŠคํŠธ๋ฅผ ์œ„ํ•ด BlaCk-Void.zshrc์— ๋กœ๊ทธ๋ฅผ ๋„ฃ์–ด๋ดค๋Š”๋ฐ, [WARNING]: Console output during zsh initialization detected. ๋ผ๋Š” ์›Œ๋‹๊ณผ ํ•จ๊ป˜ ๊ธฐ์กด์— ์ˆ˜ํ–‰๋˜์ง€ ์•Š๋˜ .zshrc์˜ ์ตœ์ข… ๋กœ๊ทธ๊นŒ์ง€ ์ฐํžˆ๋Š” ๊ฒƒ์„ ํ™•์ธํ–ˆ์Šต๋‹ˆ๋‹ค.

์ฐธ๊ณ ๋กœ unalias gbs๋ฅผ BlaCk-Void.zshrc์— ๋„ฃ์–ด๋ณด๋‹ˆ /home/sh10233lee/.zsh/BlaCk-Void.zshrc:unalias:322: no such hash table element: gbs ์™€ ๊ฐ™์€ ๋ฉ”์„ธ์ง€๊ฐ€ ๋‚˜์™€ unalias๊ฐ€ ์ˆ˜ํ–‰๋˜์ง€ ์•Š์•˜์Šต๋‹ˆ๋‹ค.

black7375 commented 2 years ago

์•„๋งˆ ์†Œ์Šค ํ›„์— unalias ์ž‘์—…์„ ํ•ด์ฃผ์‹œ๋ฉด ๋  ๊ฒƒ ๊ฐ™์•„์š”.

# ~/.zshrc
souce ~/.zsh/BlaCk-Void.zshrc
unalias gbs
everLEEst commented 2 years ago

์•„๋งˆ ์†Œ์Šค ํ›„์— unalias ์ž‘์—…์„ ํ•ด์ฃผ์‹œ๋ฉด ๋  ๊ฒƒ ๊ฐ™์•„์š”.

# ~/.zshrc
souce ~/.zsh/BlaCk-Void.zshrc
unalias gbs

๋‹ต๋ณ€ ๊ธ€์— ๋‚ด์šฉ์„ ์ถ”๊ฐ€ํ–ˆ๋Š”๋ฐ ๊ทธ ์‚ฌ์ด์— ๋‹ต๋ณ€์„ ์ฃผ์…จ๋„ค์š”ใ…Žใ…Ž ์—ฌ๊ธฐ์— ์ด์–ด์„œ ์ ๊ฒ ์Šต๋‹ˆ๋‹ค.

์ถ”๊ฐ€ ํ…Œ์ŠคํŠธ๋ฅผ ์œ„ํ•ด BlaCk-Void.zshrc์— ๋กœ๊ทธ๋ฅผ ๋„ฃ์–ด๋ดค๋Š”๋ฐ, [WARNING]: Console output during zsh initialization detected. ๋ผ๋Š” ์›Œ๋‹๊ณผ ํ•จ๊ป˜ ๊ธฐ์กด์— ์ˆ˜ํ–‰๋˜์ง€ ์•Š๋˜ .zshrc์˜ ์ตœ์ข… ๋กœ๊ทธ๊นŒ์ง€ ์ฐํžˆ๋Š” ๊ฒƒ์„ ํ™•์ธํ–ˆ์Šต๋‹ˆ๋‹ค.

์ฐธ๊ณ ๋กœ unalias gbs๋ฅผ BlaCk-Void.zshrc์— ๋„ฃ์–ด๋ณด๋‹ˆ /home/sh10233lee/.zsh/BlaCk-Void.zshrc:unalias:322: no such hash table element: gbs ์™€ ๊ฐ™์€ ๋ฉ”์„ธ์ง€๊ฐ€ ๋‚˜์™€ unalias๊ฐ€ ์ˆ˜ํ–‰๋˜์ง€ ์•Š์•˜์Šต๋‹ˆ๋‹ค.

๋ง์”€ํ•ด์ฃผ์‹  ๊ฒƒ๊ณผ ๊ฐ™์ด source ์ดํ›„๋กœ ๋ณ€๊ฒฝ์„ ํ–ˆ์œผ๋‚˜ ๋งˆ์ฐฌ๊ฐ€์ง€๋กœ unalias๊ฐ€ ์ˆ˜ํ–‰๋˜์ง€ ์•Š์Šต๋‹ˆ๋‹ค. /home/sh10233lee/.zshrc:unalias:117: no such hash table element: gbs

ํ„ฐ๋ฏธ๋„์—์„œ alias gbs๋ฅผ ์ˆ˜ํ–‰ํ•ด๋ณด๋ฉด ์—ฌ์ „ํžˆ gbs='git bisect' ๋กœ ์žกํ˜€์žˆ๊ตฌ์š”.

everLEEst commented 2 years ago

์•„๋งˆ ์†Œ์Šค ํ›„์— unalias ์ž‘์—…์„ ํ•ด์ฃผ์‹œ๋ฉด ๋  ๊ฒƒ ๊ฐ™์•„์š”.

# ~/.zshrc
souce ~/.zsh/BlaCk-Void.zshrc
unalias gbs

๋‹ต๋ณ€ ๊ธ€์— ๋‚ด์šฉ์„ ์ถ”๊ฐ€ํ–ˆ๋Š”๋ฐ ๊ทธ ์‚ฌ์ด์— ๋‹ต๋ณ€์„ ์ฃผ์…จ๋„ค์š”ใ…Žใ…Ž ์—ฌ๊ธฐ์— ์ด์–ด์„œ ์ ๊ฒ ์Šต๋‹ˆ๋‹ค.

์ถ”๊ฐ€ ํ…Œ์ŠคํŠธ๋ฅผ ์œ„ํ•ด BlaCk-Void.zshrc์— ๋กœ๊ทธ๋ฅผ ๋„ฃ์–ด๋ดค๋Š”๋ฐ, [WARNING]: Console output during zsh initialization detected. ๋ผ๋Š” ์›Œ๋‹๊ณผ ํ•จ๊ป˜ ๊ธฐ์กด์— ์ˆ˜ํ–‰๋˜์ง€ ์•Š๋˜ .zshrc์˜ ์ตœ์ข… ๋กœ๊ทธ๊นŒ์ง€ ์ฐํžˆ๋Š” ๊ฒƒ์„ ํ™•์ธํ–ˆ์Šต๋‹ˆ๋‹ค.

์ฐธ๊ณ ๋กœ unalias gbs๋ฅผ BlaCk-Void.zshrc์— ๋„ฃ์–ด๋ณด๋‹ˆ /home/sh10233lee/.zsh/BlaCk-Void.zshrc:unalias:322: no such hash table element: gbs ์™€ ๊ฐ™์€ ๋ฉ”์„ธ์ง€๊ฐ€ ๋‚˜์™€ unalias๊ฐ€ ์ˆ˜ํ–‰๋˜์ง€ ์•Š์•˜์Šต๋‹ˆ๋‹ค.

๋ง์”€ํ•ด์ฃผ์‹  ๊ฒƒ๊ณผ ๊ฐ™์ด source ์ดํ›„๋กœ ๋ณ€๊ฒฝ์„ ํ–ˆ์œผ๋‚˜ ๋งˆ์ฐฌ๊ฐ€์ง€๋กœ unalias๊ฐ€ ์ˆ˜ํ–‰๋˜์ง€ ์•Š์Šต๋‹ˆ๋‹ค. /home/sh10233lee/.zshrc:unalias:117: no such hash table element: gbs

ํ„ฐ๋ฏธ๋„์—์„œ alias gbs๋ฅผ ์ˆ˜ํ–‰ํ•ด๋ณด๋ฉด ์—ฌ์ „ํžˆ gbs='git bisect' ๋กœ ์žกํ˜€์žˆ๊ตฌ์š”.

์•„๋ž˜๋Š” echo๋ฅผ ์ฐ์–ด๋ณธ ๋กœ๊ทธ์ž…๋‹ˆ๋‹ค๋งŒ ํฐ ์˜๋ฏธ๋Š” ์—†์„ ๊ฑฐ ๊ฐ™์Šต๋‹ˆ๋‹ค.

LSH DEBUG::zshrc start! LSH DEBUG::zshrc pulin LSH DEBUG::zshrc oh my zsh! LSH DEBUG::set env done! LSH DEBUG::gbs unaliased! LSH DEBUG::zshrc for black void start.

[WARNING]: Console output during zsh initialization detected.

When using Powerlevel10k with instant prompt, console output during zsh initialization may indicate issues.

You can:

For details, see: https://github.com/romkatv/powerlevel10k/blob/master/README.md#instant-prompt

-- console output produced during zsh initialization follows --

LSH DEBUG::zshrc for black void init done. LSH DEBUG::zshrc for black void z-plugin done. LSH DEBUG::zshrc for black void theme set done. LSH DEBUG::zshrc for black void plugin set done. LSH DEBUG::zshrc for black void OMZ bundle done. LSH DEBUG::zshrc for black void custom bundle step 1 done. LSH DEBUG::zshrc for black void plugin load done. LSH DEBUG::zshrc for black void custom bundle step 2 done. LSH DEBUG::zshrc for black void library setting done. LSH DEBUG::zshrc for black void bashrc done. /home/sh10233lee/.zsh/BlaCk-Void.zshrc:unalias:322: no such hash table element: gbs LSH DEBUG::zshrc for black unalias gbs. LSH DEBUG::zshrc for black void custom set done. LSH DEBUG::zshrc for black void is done. /home/sh10233lee/.zshrc:unalias:117: no such hash table element: gbs LSH DEBUG::zshrc done!

everLEEst commented 2 years ago

no such hash table element: gbs ์ด ๋ฉ”์„ธ์ง€๋Š” ์ค‘๋ณต์œผ๋กœ unalias๋ฅผ ํ•ด์„œ ๋‚˜์˜จ ๊ฒƒ์œผ๋กœ ๋ณด์—ฌ ์ตœ์ข…์ ์œผ๋กœ source ์ˆ˜ํ–‰ํ›„ zshrc ๋งˆ์ง€๋ง‰์— unalias๋ฅผ ํ•œ๋ฒˆ๋งŒ ์ˆ˜ํ–‰์‹œํ‚ค๋ฉด ๋ฉ”์„ธ์ง€๋Š” ๋‚˜์˜ค์ง€ ์•Š์Šต๋‹ˆ๋‹ค๋งŒ ์—ฌ์ „ํžˆ alias๋Š” ํ’€๋ฆฌ์ง€ ์•Š๋„ค์š”....

black7375 commented 2 years ago

์•„.. ์ด์œ ๋ฅผ ์•Œ ๊ฒƒ ๊ฐ™๋„ค์š”. ์š”์ฆ˜์— ์•ˆ๊ฑด๋“ค์—ฌ์„œ ์ž ์‹œ ๊นŒ๋จน์—ˆ๋Š”๋ฐ, ์ œ ์„ค์ •์€ ๋กœ๋“œํ•ด์•ผํ•˜๋Š” ํ”Œ๋Ÿฌ๊ทธ์ธ ์–‘์ด ๋งŽ์€ ํŽธ์ด๋ผ ์„ฑ๋Šฅ์„ ์œ„ํ•ด ๋น„๋™๊ธฐ ๋กœ๋“œ๋˜๋„๋ก ๊ตฌ์„ฑ๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค.

๋”ฐ๋ผ์„œ ๋น„๋™๊ธฐ ํ์—์„œ ๋Šฆ๊ฒŒ ์ฒ˜๋ฆฌ๋˜๋„๋ก ์šฐ์„ ์ˆœ์œ„๋ฅผ ์„ค์ •ํ•ด์ฃผ๋ฉด ๋  ๊ฒƒ ๊ฐ™์Šต๋‹ˆ๋‹ค.

zinit ice wait"2c" atload"unalias gbs" lucid
zinit light zdharma-continuum/null
everLEEst commented 2 years ago

๋ง์”€ํ•ด์ฃผ์‹ ๋Œ€๋กœ ์ถ”๊ฐ€ํ•˜๋‹ˆ ์ž˜ ์ ์šฉ๋˜๋„ค์š”. ๋„์›€ ๊ฐ์‚ฌ๋“œ๋ฆฝ๋‹ˆ๋‹ค!