From time to time I use copy and paste in terminal. It's not necessary but it could improve usability.
is anyone working on this issue? if so, what is the status?
I don't know of anyone working on this issue. Likely the first step is migrating our use of term.js to xterm.js instead, since the latter is maintained going forward.
Indeed, this would be very welcome. Great stuff by the way.
I'd love this too
Is it the task (copy and paste in terminal) in progress or wont it to be supported?
What exactly did you mean by "could improve usability"? It was broken for a long time, but #7983 should at least allow copy and pasting with the right click menu.
Did you imagine something in addition to that? In #7956, @garrett suggested that Ctrl+Shit+C could be used, similar to how gnome terminal does it.
Windows 10, IE 11, Chrome Version 63.0.3239.132 copy & paste not working
Firefox 58.0.2 on Linux (Fedora 27, Cockpit built from master):
Is this feature considered for next release? This is a must feature for us to start using cockpit.
Okay, so paste is working on linux machines chrome and chromium and not working in firefox.
We can work with this. Thanks!
Heya,
I see thing is working on chorme. However I can not paste into the terminal. I'm on version 172, Google Chrome om Windows and I do not get an option to paste.
Am I missing a step here?
Win10 64bit, Chrome68.0.3440.75 (official), x64
copy working but paste into terminal not working.
Copy / Paste would be appreciated.
I too would love to have this functionality. Windows using Chrome here, not that I can't setup a Fedora device, but it's a nice to have.
Very missing features indeed. At least Paste.
I've tested several browsers and their ability to copy and paste text in Cockpit's terminal.
Here are the steps I used for testing:
 | Copy | Paste
-- | -- | --
Firefox 64.0 | :heavy_check_mark: | :heavy_check_mark:
Chromium 71.0.3578.98 | :heavy_check_mark: | :heavy_check_mark:
Epiphany 3.30.2 (WebKit 2.22.5) | :heavy_check_mark: | :heavy_multiplication_x:
Safari 11.1.2 (WebKit 11605.3.8.1) on OS X 10.11.6 | :heavy_check_mark: | :heavy_check_mark:
Edge 42.17134.1.0 (EdgeHTML 17.17134) | :white_check_mark: | :heavy_multiplication_x:
:white_check_mark:: _Edge can copy, but it's a bit fiddly with the right click, as it sometimes dismisses the selection and sometimes does not show the context menu._
_Note: With the exceptions of Safari and Edge, all browsers were tested on Fedora 29._
Ctrl-C / Ctrl-V generally do not work for copying and pasting in a terminal, as the commands are entered into the terminal instead. This is expected, as it's how terminals work. Ctrl-C is rather critical too, for breaks.
On most Linux terminals, including GNOME-Terminal, Ctrl-Shift-C / Ctrl-Shift-V are workarounds for copying and pasting. There is not special handler in the Cockpit terminal to implement these workarounds.
Alternatively, it could also be possible to make Ctrl-C / Ctrl-V do copy/paste and use Ctrl-Shift-C / Ctrl-Shift-V as workarounds.
On a Mac, the ⌘-C and ⌘-V shortcuts do not work. They simply should. Perhaps the JavaScript can be augmented to make this work?
Copying & pasting via a right-click works in most (but not all) browsers — but it's not discoverable enough. (Generally, pasting via a context menu needs text de-selected first.) In addition, other terminals and applications use alternate means for copying & pasting. Also, the standard desktop copy/paste keyboard shortcuts do not work (nor do the usual work-arounds).
Cockpit should make copying & pasting more discoverable through a visible menu (or even action buttons) and keyboard shortcuts.
Note: I had additional suggestions in a different bug @ https://github.com/cockpit-project/cockpit/issues/7956#issuecomment-339296754 & https://github.com/cockpit-project/cockpit/issues/7956#issuecomment-339365141 (including sticky keys and such). Both were written a long time ago, but probably still apply.
This was driving me crazy. Using Windows 10 + Chrome 71
Press Ctrl+a first. Then Ctrl-v.
Someone else can probably explain why it works this way. I'm a little lost as to why, but I'm super happy it does.
https://github.com/cockpit-project/cockpit/commit/8eb0e5e6 provides copy and paste through context menu. Also it makes shortcuts discoverable (ctrl+Insert and shift+insert).
Others combinations can be added, but as discussed, crtl+c and ctrl+v generally are not great choice, ctrl+shift+c/v can be implemented, but for example ctrl+shift+c is already reserved in firefox.
Closing, if anyone thinks there is something missing please reopen.
Most helpful comment
This was driving me crazy. Using Windows 10 + Chrome 71
Press Ctrl+a first. Then Ctrl-v.
Someone else can probably explain why it works this way. I'm a little lost as to why, but I'm super happy it does.