martanne / vis

A vi-like editor based on Plan 9's structural regular expressions
Other
4.19k stars 259 forks source link

Paste error, after installing dwl (dwm wayland fork) and wayland #1140

Closed Disonantemus closed 8 months ago

Disonantemus commented 9 months ago
mcepl commented 9 months ago

On Sat Sep 30, 2023 at 3:58 PM CEST, Disonantemus wrote:

Command failed Failed to connect to a Wayland server: No such file or directory Note: WAYLAND_DISPLAY is set to wayland-0 Note: XDG_RUNTIME_DIR is set to /run/user/1000 Please check whether /run/user/1000/wayland-0 socket exists and is accessible.

Please, give us the output of echo $XDG_SESSION_TYPE. Do you have Wayland or Xorg based desktop?

Which clipboard manager you use? (not xsel, that’s Xorg-based).

Disonantemus commented 8 months ago

Sorry 4 late response, I'm no programmer, and didn't get any notification 4 this.

  1. echo output:

    $ echo $XDG_SESSION_TYPE
    tty
  2. clipmenu from Arch Extra repo.

  3. I use Xorg everyday (with dwm window manager), but I did install and try Wayland 2 weeks ago, maybe vis got confused because of that?

  4. Maybe it's not related, but I also use autocutsel (same Arch repo) 2 clone all clipboards and use them like one:

# .xinitrc
autocutsel -s PRIMARY &
autocutsel -s CLIPBOARD &

On Sat Sep 30, 2023 at 3:58 PM CEST, Disonantemus wrote: ~ Command failed Failed to connect to a Wayland server: No such file or directory Note: WAYLAND_DISPLAY is set to wayland-0 Note: XDG_RUNTIME_DIR is set to /run/user/1000 Please check whether /run/user/1000/wayland-0 socket exists and is accessible. ~ Please, give us the output of echo $XDG_SESSION_TYPE. Do you have Wayland or Xorg based desktop? Which clipboard manager you use? (not xsel, that’s Xorg-based).


OS: Arch Linux x86_64 Host: MS-7816 2.0 Kernel: 6.1.52-1-lts Shell: fish 3.6.1 Resolution: 1920x1080 WM: dwm Terminal: tmux CPU: Intel i7-4790 (8) @ 3.600GHz GPU: AMD ATI Radeon RX 470/480/570/570X/580/580X/590

mcepl commented 8 months ago
  1. echo output:
$ echo $XDG_SESSION_TYPE
tty

There’s something wrong there. Is this running in some kind of terminal emulator (xterm, gnome-terminal, foot, st, or something) in a graphical environment? To my knowledge only normal values of this variable are x11 or wayland (depending on the type of the graphical environment).

(after some vigorous searching over the Internet)

I see, so it is possible for xclip/xsel to work with gpm without any graphical environment present. Is it your case? If yes, then you should probably fix https://github.com/martanne/vis/blob/master/vis-clipboard to work for you.

Disonantemus commented 8 months ago

Maybe was:

Because right now I get this ("empty" as expected):

$ echo $WAYLAND_DISPLAY

And vis work as should with "*p


Sorry 4 time U spend with this, I get that wasn't vis fault, just confused, maybe because some of the above.

PD: I still get this (inside Xorg with Kitty terminal, with|without tmux):

$ echo $XDG_SESSION_TYPE
tty

But it's working ok and not a problem.

mcepl commented 8 months ago

Weird, however, @rnpnr , I think we can close this one.