Duplicator is a small package that help you duplicate lines.
- Duplicate current line if no region is active
- Duplicate all lines in the region if region is active
- Support prefix argument to execute multiple times
- Never pollute kill ring
(require 'duplicator)
(global-set-key (kbd "C-c d") 'duplicator/duplicate-lines)
Enable transient-mark-mode is required
- fix bug when duplicate lines in region with newline character at the end
- fix duplicate whole lines in region may duplicate line above region
- duplicate whole lines in region should now works with prefix argument properly
- support prefix argument
- duplicate current lines/whole lines across region
Copyright (C) 2014 Rangi Lin
Author: Rangi Lin Version: 0.2.2
This file is not part of GNU Emacs.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.