magiblot / tvision

A modern port of Turbo Vision 2.0, the classical framework for text-based user interfaces. Now cross-platform and with Unicode support.
Other
1.99k stars 150 forks source link

use another tools instead of xclip on some operating systems #98

Closed unxed closed 1 year ago

unxed commented 1 year ago

pbcopy and pbpaste should be used under MacOS.

Also there are separate tools for WSL and Cygwin environments. Full list here: https://gist.github.com/RichardBronosky/56d8f614fab2bacdd8b048fb58d0c0c7#file-cb

For Wayland:

    cat | wl-copy
    wl-paste
magiblot commented 1 year ago

Hi @unxed!

pbcopy/pbpaste are already being used on MacOS and wl-copy/wl-paste (part of the wl-clipboard package) are already being used in Wayland sessions (unixcon.cpp).

Cygwin is not supported, so the only case that's missing is WSL. Thanks for the suggestion.

unxed commented 1 year ago

Probably full paths in WSL are not required, try

    cat | clip
    powershell Get-Clipboard | sed 's/\r//'

first

magiblot commented 11 months ago

In WSL, PowerShell was so slow and required so many workarounds that I switched to CScript. Pasting still takes a short delay but it is now a lot better.