{"id":13344240,"url":"https://github.com/kimud6003/My-Terminal","last_synced_at":"2025-03-12T07:32:21.782Z","repository":{"id":45797883,"uuid":"514508947","full_name":"kimud6003/My-Terminal","owner":"kimud6003","description":"Unix,Windows Terminal Config","archived":false,"fork":false,"pushed_at":"2022-07-16T16:08:21.000Z","size":17785,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-07-30T21:09:28.106Z","etag":null,"topics":["macos","settings","terminal","vim","windows","zsh"],"latest_commit_sha":null,"homepage":"","language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kimud6003.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-07-16T07:24:53.000Z","updated_at":"2022-07-16T15:50:52.000Z","dependencies_parsed_at":"2022-07-17T05:46:06.677Z","dependency_job_id":null,"html_url":"https://github.com/kimud6003/My-Terminal","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kimud6003%2FMy-Terminal","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kimud6003%2FMy-Terminal/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kimud6003%2FMy-Terminal/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kimud6003%2FMy-Terminal/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kimud6003","download_url":"https://codeload.github.com/kimud6003/My-Terminal/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":221279939,"owners_count":16790558,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["macos","settings","terminal","vim","windows","zsh"],"created_at":"2024-07-29T19:32:53.426Z","updated_at":"2024-10-24T05:30:20.796Z","avatar_url":"https://github.com/kimud6003.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# My-Terminal \u003cimg src=\"https://img.shields.io/badge/Terminal-4D4D4D?style=for-the-badge\u0026logo=Windows Terminal\u0026logoColor=white\"\u003e \r\n\r\n### Windows\r\n   ![windows](./imgs/win.png)\r\n\r\n### Mac\r\n   ![Macs](./imgs/mac.png) \r\n   \r\n\r\n- 해당 레포지토리는 `mac`, `linux`, `windows`에서 터미널 환경을 사용할때마다 번거로움을 느껴 설정 커맨드를 저장하고자 하는 레포지토리입니다.\r\n\r\n## Mac,Linux\r\n\r\n- `mac`은 기본적으로 `brew`가 필요합니다.\r\n\r\n```bash\r\n/bin/bash -c \"$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)\"\r\n```\r\n\r\n   ![mac1](./imgs/mac1.png)\r\n\r\n- 'brew'가 설치 되었다면 `mac`에서 다양한 기능을 가진 터미널 `Iterm2`를 설치해보도록 하겠습니다.\r\n\r\n\r\n```bash\r\nIterm2\r\n\r\nbrew install --cask iterm2\r\n\r\n```\r\n   ![mac2](./imgs/mac2.png)\r\n   - 왼쪽 `iterm` 오른쪽 `Terminal`   \r\n\r\n- 저는 `bash` 보다 `zsh`환경을 선호하는 편이기 때문에 `zsh`도 설치하겠습니다.   \r\n\r\n```bash\r\n# curl 사용하여 zsh 설치\r\nsh -c \"$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)\"\r\n```\r\n   ![mac3](./imgs/mac3.png)\r\n\r\n```bash\r\n# zsh 플러그인 Auto Suggestions\r\nbrew install zsh-autosuggestions\r\n\r\n# Auto Suggestions 세팅\r\necho \"source /usr/local/share/zsh-autosuggestions/zsh-autosuggestions.zsh\" \u003e\u003e ~/.zshrc\r\n\r\n# zsh플러그인 Syntax Highlighting\r\ngit clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting\r\n\r\n# Syntax Highlighting 세팅\r\necho \"source ~/.oh-my-zsh/custom/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh\" \u003e\u003e ${HOME}/.zshrc\r\n\r\n# zsh 테마 Powerlever10k 설치\r\ngit clone --depth=1 https://github.com/romkatv/powerlevel10k.git ${ZSH_CUSTOM:-$HOME/.oh-my-zsh/custom}/themes/powerlevel10k\r\n\r\n```\r\n| zsh-autosuggestions | zsh-syntax-highlighting | \r\n|-------------- | -------------- | \r\n| ![mac4](./imgs/mac4.png)|![mac5](./imgs/mac5.png)|\r\n\r\n\r\n- 해당 설치 과정을 수행하고 나고 `zsh`를 타이핑 하면 `powerlevel10k`의 세팅 화면이 시작 될것입니다.\r\n\r\n\u003e Powerlever10k는 `Nerd Font`가 없으면 아이콘이 깨지게 되기 때문에 저는 `Fira Code Nerd Font`를 설치해서 사용했습니다  \r\n\u003e\r\n\u003e [Nerd Font](https://www.nerdfonts.com/font-downloads) \r\n\r\n- 마지막으로 `IDE Neovim`과 `Github TUI Tool lazygit`을 설치하면 끝입니다.  \r\n\r\n```bash\r\n# neovim 설치\r\nbrew install neovim\r\n\r\n# neovim 커스텀 세팅\r\ngit clone https://github.com/kimud6003/NvChad ~/.config/nvim; nvim\r\n\r\n# lazygit 설치\r\nbrew install lazygit\r\n```\r\n   ![mac6](./imgs/mac6.png)\r\n   - vim vs Neovim\r\n\r\n   ![mac7](./imgs/mac7.png)\r\n   - lazygit\r\n\r\n## Window\r\n\r\n- `Window`의 경우 저는 `wsl2`를 사용하여 개발을 주로합니다.\r\n\r\n- 하지만 `Window`에서 개발이 필요하다고 생각 드는 경우에 아래 세팅을 하는데 참고 해주시면 좋겠습니다.\r\n\r\n\u003e `wsl2`가 궁금하시다면 [wsl2](https://github.com/kimud6003/wsl) \r\n\r\n- 우선 윈도우에서는 패키지 관리자로 `chocolatey`가 필요합니다. \r\n\r\n- `chocolatey`는 `powerShell` 을 관리자 권한으로 실행후 아래 코드를 치면 설치가 가능합니다.\r\n\r\n```bash\r\nSet-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))\r\n\r\nchoco feature enable -n allowGlobalConfirmation\r\n```\r\n\r\n   ![win1](./imgs/win1.png)\r\n\r\n- 아마 여러분들의 `powerShell`은 저처럼 색이 어둡지 않고 파란색일 겁니다. \r\n\r\n- 이와 같은 설정도 앞으로 차차 해보도록 하겠습니다.\r\n\r\n- `powerShell`보다 높은 `Terminal`을 설치해서 기존의 `shell` 보다 다양한 환경을 구성해보도록 하겠습니다 \r\n\r\n- 설치 방법은 크게 2가지로 하나는 `microsoft Store`를 사용하는 방법과 , `chocolatey`를 사용하는 방법이 있습니다.  \r\n\r\n- 방법 1\r\n   | microsoft store | 터미널 검색 | \r\n   |-------------- | -------------- | \r\n   | ![win2](./imgs/win2.png)|![win3](./imgs/win3.png)|\r\n\r\n- 방법 2\r\n\r\n   ```bash\r\n      choco install microsoft-windows-terminal\r\n   ``` \r\n\r\n- 그럼 이제 `Terminal`설치가 완료가 되었습니다.\r\n\r\n- 이제 `powerShell` 최신 버전을 설치해보도록 하겠습니다. (2022-7월 기준으로 7.2.5버전이 최신입니다)\r\n\r\n   ```bash\r\n      choco install powershell-core\r\n   ``` \r\n   ![win4](./imgs/win4.png)\r\n\r\n- `powerShell`도 현재 `bash`처럼 밋밋한 느낌으로 되어있습니다.\r\n\r\n- 이것을 `zsh`처럼 바꾸어 보도록 하겠습니다.\r\n\r\n```bash\r\n# oh-my-zsh와 비슷한 Tool install\r\n   Install-Module oh-my-posh -Scope CurrentUser \r\n\r\n# oh-my-posh git Tool install\r\n   Install-Module posh-git -Scope CurrentUser \r\n\r\n# Pretty Icon\r\n   Install-Module -Name Terminal-Icons -Repository PSGallery \r\n\r\n# Pretty ls Install\r\n   Install-Module -Name PowerColorLS -Repository PSGallery \r\n\r\n# oh-my-posh update\r\n   Update-Module -Name oh-my-posh -AllowPrerelease -Scope CurrentUser\r\n\r\n# zsh-autosuggestions 기능하는 Tool\r\n   Import-Module PSReadLine\r\n   Set-PSReadLineOption -PredictionSource History\r\n\r\n# .zshrc의 powershell 버전인 profile파일 만들기\r\n   New-Item -ItemType File -Path $PROFILE\r\n\r\n# poshTheme 설치\r\n   Get-PoshThemes\r\n\r\n# posh 실행\r\n   Set-PoshPrompt -Theme M365Princess\r\n```\r\n- 여기 까지 실행하면 아마 아래처럼 바뀌어있을겁니다 \r\n   ![win5](./imgs/win5.png)\r\n\r\n- 하지만 `powershell`을 다시 새로고침하면 아마 초기화 될것인데 이를 방지하기 위해 우리는 설정파일에 내용을 넣어 주어야 합니다.\r\n\r\n- 아래 코드를 복사해서 `powershell`에 넣으면 자동으로 설정파일에 글을 작성하게 될것이니 그냥 실행시켜주세요 \r\n\r\n```bash\r\n\r\n# 설정 파일에 내용 넣어주기\r\n   echo \"Import-Module PSReadLine\" \u003e\u003e ${profile}\r\n\r\n   echo \"Import-Module PowerColorLS\" \u003e\u003e ${profile}\r\n\r\n   echo \"Set-PoshPrompt -Theme M365Princesss\" \u003e\u003e ${profile}\r\n\r\n   echo \"Set-PSReadLineOption -PredictionSource History\" \u003e\u003e ${profile}\r\n\r\n   echo \"Set-Alias -Name ls -Value PowerColorLS -Option AllScope\" \u003e\u003e ${profile}\r\n```\r\n\r\n   | autosuggestions | Pretty LS  | \r\n   |-------------- | -------------- | \r\n   | ![win6](./imgs/win6.png)|![win7](./imgs/win7.png)|\r\n\r\n- 마지막으로 `Terminal` 테마에 대해 올리겠습니다.\r\n\r\n- 테마를 설치하기전에 `FiraCode Nerd Font`를 설치하고 가도록 하겠습니다. [링크](https://github.com/ryanoasis/nerd-fonts/releases/download/v2.1.0/FiraCode.zip) \r\n\r\n```json\r\n\"defaults\": \r\n        {\r\n            \"colorScheme\": \"Tokyo Night\",\r\n            \"font\": \r\n            {\r\n                \"face\": \"FiraCode Nerd Font\"\r\n            }\r\n        },\r\n\"schemes\":[\r\n   {\r\n           \"name\": \"Tokyo Night\",\r\n           \"foreground\": \"#a9b1dc\",\r\n           \"background\": \"#1a1b2c\",\r\n           \"cursorColor\": \"#c0caf5\",\r\n           \"selectionBackground\": \"#28344a\",\r\n           \"black\": \"#414868\",\r\n           \"red\": \"#f7768e\",\r\n           \"green\": \"#73daca\",\r\n           \"yellow\": \"#e0af68\",\r\n           \"blue\": \"#7aa2f7\",\r\n           \"purple\": \"#bb9af7\",\r\n           \"cyan\": \"#7dcfff\",\r\n           \"white\": \"#c0caf5\",\r\n           \"brightBlack\": \"#414868\",\r\n           \"brightRed\": \"#f7768e\",\r\n           \"brightGreen\": \"#73daca\",\r\n           \"brightYellow\": \"#e0af68\",\r\n           \"brightBlue\": \"#7aa2f7\",\r\n           \"brightPurple\": \"#bb9af7\",\r\n           \"brightCyan\": \"#7dcfff\",\r\n           \"brightWhite\": \"#c0caf5\"\r\n   }\r\n]\r\n\r\n```\r\n\r\n- 추가적으로 `nvim`을 사용하실분은 아래 코드를 따라 쳐주세요 \r\n\r\n\r\n```bash\r\n\r\n   choco install neovim\r\n\r\n   choco install lazygit\r\n\r\n   git clone https://github.com/kimud6003/NvChad $HOME\\AppData\\Local\\nvim\r\n\r\n   nvim\r\n\r\n```\r\n![windows](./imgs/win.png)\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkimud6003%2FMy-Terminal","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkimud6003%2FMy-Terminal","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkimud6003%2FMy-Terminal/lists"}