Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- copyq:
- // Copy without changing X11 selection (on Windows you can use copy instead).
- function copy2() {
- try {
- var x = config('copy_clipboard')
- config('copy_clipboard', false)
- try {
- copy.apply(this, arguments)
- } finally {
- config('copy_clipboard', x)
- }
- } catch(e) {
- copy.apply(this, arguments)
- }
- }
- copy2()
- var text = str(clipboard())
- if (text) {
- var tmp1 = text.replace(new RegExp('-\n', 'g'), '')
- var tmp2 = tmp1.replace(new RegExp('\n', 'g'), ' ')
- copy2(tmp2)
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement