<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Alex Gonzalez Lacasa</title>
    <description>The latest articles on DEV Community by Alex Gonzalez Lacasa (@aloon).</description>
    <link>https://dev.to/aloon</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F401084%2Fd8d79db0-9ba5-439f-9bdd-fd6a81023c14.png</url>
      <title>DEV Community: Alex Gonzalez Lacasa</title>
      <link>https://dev.to/aloon</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/aloon"/>
    <language>en</language>
    <item>
      <title>wayland &amp; clipboard</title>
      <dc:creator>Alex Gonzalez Lacasa</dc:creator>
      <pubDate>Thu, 10 Aug 2023 18:29:25 +0000</pubDate>
      <link>https://dev.to/aloon/wayland-clipboard-o9f</link>
      <guid>https://dev.to/aloon/wayland-clipboard-o9f</guid>
      <description>&lt;p&gt;The clipboard in wayland works differently than in X11.&lt;br&gt;
For some programs like vim to be able to access the system clipboard you must have installed wl-clipboard&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;apt &lt;span class="nb"&gt;install &lt;/span&gt;wl-clipboard
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To be able to copy stdout you need wl-copy, xclip or xsel doesn't work anymore&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;apt &lt;span class="nb"&gt;install &lt;/span&gt;wl-copy
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;example&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Hello world"&lt;/span&gt; | wl-copy
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



</description>
      <category>linux</category>
      <category>wayland</category>
      <category>clipboard</category>
      <category>copy</category>
    </item>
    <item>
      <title>VIM / NeoVim and the clipboard (in Linux)</title>
      <dc:creator>Alex Gonzalez Lacasa</dc:creator>
      <pubDate>Thu, 10 Aug 2023 07:32:18 +0000</pubDate>
      <link>https://dev.to/aloon/vim-neovim-and-the-clipboard-in-linux-42lg</link>
      <guid>https://dev.to/aloon/vim-neovim-and-the-clipboard-in-linux-42lg</guid>
      <description>&lt;p&gt;First check is your vim installation is enabled to access to the system clipboard.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;:checkhealth
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This show posible warnings like&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Clipboard (optional)
- WARNING No clipboard tool found. Clipboard registers ("+ and "*) will not work.
  - ADVICE:
    - :help clipboard
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;try to put in &lt;code&gt;~/.config/nvim/init.vim&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;set clipboard=unnamedplus
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If the clipboard still isn't working and your graphical environment uses Wayland, install:&lt;br&gt;
wl-clipboard&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo apt install wl-clipboard
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;At least in my case the clipboard between applications already works.&lt;/p&gt;

&lt;p&gt;And remember, in VISUAL mode&lt;br&gt;
&lt;code&gt;y&lt;/code&gt; for copy&lt;br&gt;
&lt;code&gt;p&lt;/code&gt; for paste&lt;/p&gt;

</description>
      <category>neovim</category>
      <category>vim</category>
      <category>clipboard</category>
    </item>
  </channel>
</rss>
