Set-Clipboard Linux
See original GitHub issueSummary of the new feature/enhancement
PowerShell’s [SG]et-Clipboard
functional independence.
How to work with the clipboard in Linux using PowerShell? If the cmdlet Get-Clipboard
requires installing xclip
(gcb is a stub?), then what about Set-Clipboard
? You can certainly use native utilities, but why then useless cmdlets?
My Environment
OS: KDE neon User Edition 5.20 x64 PowerShell v7.1.2 (manual install: download, unpack, symlink to /usr/bin) xclip v0.13-1
Issue Analytics
- State:
- Created 3 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Pipe to/from the clipboard in a Bash script
If you're in Linux terminal mode (no X) then look into gpm or Screen which has a clipboard. Try the Screen command readreg...
Read more >Set-Clipboard (Microsoft.PowerShell.Management)
The Set-Clipboard cmdlet sets the contents of the clipboard. Note On Linux, this cmdlet requires the xclip utility to be in the path....
Read more >[SOLVED] ssh set clipboard of remote machine
Hi everyone,. I would like to set the clipboard of a remote ssh server machine through ssh. For example, I have machine A...
Read more >How To Copy Command Output To Linux Clipboard Directly
Explains how to copy and paste from UNIX / Linux shell prompt to X applications clipboard from shell prompt using xclip/xsel command.
Read more >How to Use the Set-Clipboard Cmdlet in PowerShell?
To copy the content to the clipboard, first, use the “Set-Clipboard” cmdlet, then specify the text or file path to be copied. Syntax....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Now it is in Work Groups competence 😃 so I stopped all review work on issues.
Good point - I also see the problem in 7.1.2 and 7.2.0-preview.3, on Ubuntu 18.04, and this is clearly a bug.
The problem must be related to how PowerShell waits for
xclip
to exit.Please update your original post with the details of your environment, as requested in the issue template (edit: I now see that you used the “Feature Request/Idea” rather than the “Bug” template - only the latter requests this information, but since this actually a bug, it should be added), and please change the issue title to reflect that
Set-Clipboard
on Linux withxclip
present hangs.The workaround for now is to use
xclip
explicitly; e.g.,'foo' | xclip -selection clipboard