blob: bc4ff5a1799cd878d66bf3cd70853f1e385505a3 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
## Copy text from (n)vim to
```
* linux:
:w !xclip -sel c # copy the whole file
$ xclip -o sel -c # paste from the clipboard
or
:w !xsel -b # copy the whole file
$ xsel -o -b # paste from the clipboard
-- Note: In case neither of these tools (xsel and xclip) are preinstalled on your distro, you can probably find them in the repos
* macos:
:%w !pbcopy # copy the whole file
:r !pbpaste # paste from the clipboard
```
|