this post was submitted on 08 Oct 2023
183 points (96.4% liked)

Linux

47342 readers
1606 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS
 

Pretty sure most of you already know this but for those who don't: you have two clipboards in Linux. One is the traditional clipboard where you copy with control c and paste with control v. The other one is when you highlight text and use the mouse middle click to paste text.

More details here.

top 50 comments
sorted by: hot top controversial new old
[–] JWBananas@startrek.website 61 points 11 months ago (1 children)
[–] d3Xt3r@lemmy.nz 15 points 11 months ago* (last edited 11 months ago) (1 children)

Is this applicable for Wayland as well? That link makes several references to X and its ecosystem of tools.

[–] Chewy7324@discuss.tchncs.de 14 points 11 months ago

If I understand it correctly, Wayland only specifies a single clipboard but no primary. But most (all?) wayland compositors implement an additional protocol that's also supported by the toolkits (gtk, qt, ...) and programs like wl-clipboard.

So yes, wayland also has clipboard + primary. But no secondary, as far as I found. Though I never used secondary on X anyway.

[–] grinceur@programming.dev 41 points 11 months ago

Btw it makes using other OSs painful when you are used to it...

[–] Bitrot@lemmy.sdf.org 26 points 11 months ago (2 children)

I use auto scroll a lot, middle click paste is generally an immediate no for me.

[–] pinchcramp@lemmy.dbzer0.com 10 points 11 months ago (1 children)

How do middle-click-to-paste and middle-click-to-scroll conflict? In Firefox I can click-to-paste if the cursor is over an input field and click-to-scroll anywhere else. Never had any problem with this behavior.

[–] JWBananas@startrek.website 7 points 11 months ago (1 children)

How do middle-click-to-paste and middle-click-to-scroll conflict?

Some of us are clumsy.

[–] pinchcramp@lemmy.dbzer0.com 1 points 11 months ago

That's not something I thought about. Good thing that you can disable the feature then

[–] stepanzak@iusearchlinux.fyi 4 points 11 months ago

How did you setup auto scroll? It doesn't work for me.

[–] ChristianWS@lemmy.eco.br 24 points 11 months ago (2 children)

Not going to lie, I hate the middle click clipboard and disable it ASAP. I really dislike the idea that it copies things without my explicit permission.

[–] moreeni@lemm.ee 21 points 11 months ago (1 children)

It's one of the things that I hated at first when moving from Windows, but then I got so used to it I just can't live without it. Whenever I use Windows, I would try to quickly copypaste text using selection, doing so for 5-10 seconds, until I realise this is not a thing on this OS.

[–] lvxferre@lemmy.ml 16 points 11 months ago (1 children)

Ditto. And sometimes I use both the Ctrl+C and middle-click clipboards at the same time, when I want to copy two chunks of text. Like this:

  • Select chunk A, press Ctrl+C
  • Select chunk B
  • Shift window
  • Paste chunk B through middle-click
  • Paste chunk A through Ctrl+V
[–] dandroid@dandroid.app 5 points 11 months ago (1 children)

Windows and KDE Plasma both have CMD + V to show a list of all things that have been copied. So I always just do Ctrl + C, Ctrl + C, Ctrl + V, CMD + V -> down arrow -> enter. Though on KDE Plasma you will need another Ctrl + V to actually do the pasting after you have selected the value to paste, whereas on Windows selecting the value also pastes it. But the workflows are very similar.

[–] westyvw@lemm.ee 1 points 11 months ago (4 children)

Huh, I do not have CMD + V for clipboard contents in Plasma with Klipper. What distro is configuring that?

I am assuming by CMD you mean Superkey. If not, I would like to know. I looked at Klipper shortcuts and didnt find it in there either.

load more comments (4 replies)
[–] melvin@lemmy.ml 4 points 11 months ago (2 children)

I actually like the feature but could you explain how you disabled it? I've tried to merge all three clipboards into one a few years ago and couldn't make it work

[–] ChristianWS@lemmy.eco.br 2 points 11 months ago

KDE has the option to disable middle click paste, so I do that. Out of sight, out of mind

[–] prunerye@slrpnk.net 1 points 11 months ago

Whenever I use a touchpad without physical buttons, I usually disable the middle button entirely. It's more of a hammer-to-mosquito solution than what you were asking, but it's as easy as adding this command to the autostart file (on Xorg): xinput set-button-map "Name-of-your-Touchpad-goes-here" 1 0 3 4 5 6 7, where "Name-of-your-Touchpad-goes-here" can be found with xinput list --name-only.

[–] Quazatron@lemmy.world 15 points 11 months ago

Neat, he?

It's a pain when you switch between Windows and Linux all the time and you can't do the middle click in Windows.

[–] Blizzard@lemmy.zip 11 points 11 months ago (4 children)

Is it possible to have have a Windows 10-like clipboard in Mint? Where you can copy multiple stuff with ctrl+c and then press super+v to have a dropdown of things that you copied with a possiblity to pin some of them?

[–] ExLisper@linux.community 17 points 11 months ago
[–] 6xpipe_@lemmy.world 13 points 11 months ago

What your talking about is called a clipboard manager, and there are tons of them out there. All with varying features.

[–] elkalbil@jlai.lu 11 points 11 months ago* (last edited 11 months ago)

Klipper on KDE offers a clipboard history. Don't know about other DEs.

[–] demonsword@lemmy.world 3 points 11 months ago

qlipper is the one I use the most

[–] tacostrange@lemmy.ml 7 points 11 months ago

Wow! TIL too, thanks!

[–] Gsus4@feddit.nl 7 points 11 months ago

I knew and use this, but I never thought to call it two clipboards :)

Plus I'd never heard of shift-ins, I just used ctrl-shift-c/v in graphic terminals :P

[–] vis4valentine@lemmy.ml 6 points 11 months ago

Ohhhhh!!!! IT WORKS!

This will be so usefull in the future.

[–] Unmapped@lemmy.ml 5 points 11 months ago* (last edited 11 months ago) (1 children)

On my arch install with hyperland, clip boards have been by far the hardest thing to setup. I finally got a basic clipboard manger working using clipman and wofi. But tbh I don't really understand how that's working.

My main issues though have been trying to copy from one with vim open to other terminal with vim. Copying from vim elsewhere using y(yank) works fine. Copying elsewhere into vim works great. But vim to vim will not work for me.

Also trying to find a way to make copying text out of a terminal running tmux not so overly complex and tedious.

[–] stepanzak@iusearchlinux.fyi 3 points 11 months ago (1 children)

For copying from Tmux, I recommend tmux-yank. There are also multiple plugins allowing you to copy predefined set of text types (IP adresses, URLs, etc...). I'm currently using tmux-thumbs. Note that you have to set custom command in tmux-thums to actually copy the text to xclip or whatever you are using. example in my dotfiles

[–] Unmapped@lemmy.ml 2 points 11 months ago

I have tmux-thumbs, but only been able to use it a few times. Apparently most of what I need to copy is not ip's and URLs. But this tmux-yank looks like what I'm looking for. I'll give it a try. Thanks.

[–] JubilantJaguar@lemmy.world 5 points 11 months ago (1 children)

This user, at least, has not touched a mouse in a decade. Young people do not even know what a mouse is.

[–] pirat@lemmy.world 3 points 11 months ago* (last edited 11 months ago)

It's like a rat but cute, right??

btw do you know how to press Ctrl on my keyboard? I have already found the key of C, they're all white and sound good, kind of like an organ, but I can't see any Ctrl key. Also, do I need to press the entire key of C at once to copy? It's gonna sound intense! But I haven't learned using all 10 fingers yet for the keyboard. I only use two, so it will be hard to press them all at once while also pressing Ctrl once I find it! Is it one of those black keys? Actually I haven't even heard about the key of V yet... So I can't paste before I've learned a lot more! I've only learned A to D by now. And btw how do I compile in C#? Is keyboard really supposed to be so hard to use???

[–] donio@lemmy.world 5 points 11 months ago

Clipboard managers often have an option to synchronize them. There are standalone tools as well, autocutsel for example.

[–] brax@sh.itjust.works 4 points 11 months ago

This has been a thing for like ever. Throws me off a lot in Windows when I just want a temporary clipboard to search something and nothing comes up.

I think PowerShell abides by it, but that's it.

[–] Grass@sh.itjust.works 3 points 11 months ago

I didn't realize they were different. I always thought my copy failed and tried to use one copy with the other paste.

[–] wviana@lemmy.eco.br 2 points 11 months ago (1 children)
[–] wviana@lemmy.eco.br 2 points 11 months ago

Thought more vim folks would notice this.

[–] radioactiveradio@lemm.ee 2 points 11 months ago

3 i use copyq with kde's clipboard and the highlighting thingy.

[–] neosheo@beehaw.org 2 points 11 months ago

Lol i had no idea

load more comments
view more: next ›