multiple cursors
multiple cursor in emacs
install
先用M-x输入package-install 安装multiple-cursors包 Multiple Cursors
config
在配置文件中开启multiple-cursors
:
{% highlight shell %} (require 'multiple-cursors) (global-set-key (kbd "C-S-c C-S-c") 'mc/edit-lines)
(global-set-key (kbd "C->") 'mc/mark-next-like-this) (global-set-key (kbd "C-<") 'mc/mark-previous-like-this) (global-set-key (kbd "C-c C-<") 'mc/mark-all-like-this)
(defalias 'mc-mode 'multiple-cursors-mode) {% endhighlight %}
useage
M-x后输入mc-mode
如果开启了evil 最好先按i进入普通模式
然后使用C-c C-<全选中后,就可以随意编排了
PS: command+k 在Mac命令行里好爽