Hacker News new | past | comments | ask | show | jobs | submit login

pb[paste|copy] are a life improver. Here is a one-liner to edit the pasteboard contents in vim.

  pbpaste > tmp; vim tmp; cat tmp | pbcopy; rm tmp;
I also use pbpaste to append various notes to files, but since pbpaste doesnt have a newline at the end I wind up using:

  echo "$(pbpaste)" >> notes.txt



You can do this specific task with just vim: https://vi.stackexchange.com/a/21448




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: