3 Star 0 Fork 0

mirrors_miguelgrinberg / easy-cli

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README
MIT

easy-cli

Easy, yet powerful, command line configuration based on zsh, tmux and vim.

Installation Instructions

First of all, if you have an existing configuration for zsh, tmux or vim, back up your files and remove them from your system, so that you start from a clean slate.

Step 1: Install zsh, tmux, vim and ctags

This step must be performed according to your operating system's method for installing packages.

For Ubuntu:

sudo apt install zsh tmux vim ctags

For macOS:

brew install zsh tmux vim ctags

Step 2: Change your shell to zsh

The shell configured for the account must be set to zsh. For most UNIX-based operating systems, this can be done with the following command:

chsh -s /bin/zsh

Step 3: Copy the configuration files

Copy the three configuration files from this repository into your home directory. Remember to back up any existing config files before doing this.

git clone https://github.com/miguelgrinberg/easy-cli
cd easy-cli
cp .zshrc .tmux.conf .vimrc ~/

Step 4: Log out and back in

Log out of your shell session and then open a new session. During the first login a few plugins for zsh will be downloaded and installed.

As part of the installation, the powerlevel10k theme's own interactive configuration script will run. Feel free to select your preferred settings for the theme (which you can change as many times as you want later, by running the p10k configure command).

The first time you run vim, a few plugins will be installed as well.

Quick reference

Zsh

Plugins for zsh are managed with the zgenom utility. You can change the list of plugins installed by editing the zgenom load lines in .zshrc. The installed plugins are:

You can customize the powerlevel10k theme by editing the .p10k.zsh config file, or if you prefer, run the interactive configuration script with the p10k configure command.

The zsh documentation is the ultimate reference for configuration and use of this shell.

Tmux

You can start a new Tmux session with the command tmux new. You can reattach to a previously created session with tmux attach.

The tmux configuration defines Ctrl-A as the prefix key for all commands. The following is a brief list of defined key bindings that you can use after Ctrl-A:

  • c: create a new window
  • d: detach from the current session
  • n: go to next window
  • p: go to previous window
  • Ctrl-A: go to last window
  • k: kill current window
  • l: repaint window
  • |: split current window or pane vertically
  • -: split current window or pane horizontally
  • r: reload configuration file
  • a: send Ctrl-A to inner tmux session

Mouse and clipboard are enabled and should work with most modern terminal applications.

Consult the tmux documentation to learn how to customize your installation to your liking.

Vim

The vim configuration installs a few plugins that are useful for coding. You can review the list by looking at the lines that begin with Plug near the top of the configuration file.

If you add plugins, enter the command :PlugInstall to install them. If you make more involved changes such as removing plugins, the easiest way to update your installation is to delete the whole ~/.vim directory, which will cause a reinstall the next time the editor is launched.

Vim has extensive configuration options and a large number of plugins, so there are lots of ways in which you can improve the default configuration and make it your own. You can search for example configuration files on GitHub to get inspiration from, as many developers make theirs available for others to learn from.

Extensive documentation for vim can be found directly in the editor, via the :help command. When you are done with the documentation pane, type :q to dismiss it.

Note that this editor has a fairly steep learning curve. There is a vim cheat sheet that might help learn the basics.

MIT License Copyright (c) 2022 Miguel Grinberg Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

简介

暂无描述 展开 收起
Vim script 等 2 种语言
MIT
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
1
https://gitee.com/mirrors_miguelgrinberg/easy-cli.git
git@gitee.com:mirrors_miguelgrinberg/easy-cli.git
mirrors_miguelgrinberg
easy-cli
easy-cli
main

搜索帮助