Why xrandr numerical output is VGA-1 instead of VGA1? The same behaviour hapens with LVDS-1 instead of LVDS1.

I'm using Debian 9 stable and i3wm. Xrandr version 1.5.0. Laptop Thinkpad Lenovo.

However, in a second laptop (Acer Aspire One) the output is LVDS1. I'm using the same dotfiles for both laptops and I'm writing a script which should work in both. The script would help me to manage an external monitor (VGA). How can I solve this numerical difference?

  • I'd just remove the dash with tr.
    – jbrock
    Jan 20 '18 at 2:21
  • I finally used a solution with bash and regex into a loop, like this one: infra.in.zekjur.net/archives/i3-discuss/2015-August/002148.html, so it will match also with different numbers after the dash. I'm not sure what would be the best, though. I like your idea using tr as well. Thanks!
    – Unix
    Jan 20 '18 at 2:30

I suspect that the name is dependent on the device driver as well as the kernel. For example, I have a two graphic display ports resident on one graphics card on one of my computers, one is called DVI-D-1 and the other is called DVI-I-1.

  • Yes, probably it's something related with the hardware, therefore drivers as well. My two laptops are very different: Acer is 32 bits, very old one, 512 MB of RAM, while Thinkpad Lenovo is 64 bits, 4 GB, CPU i5... Acer has Debian 4.9.65-3+deb9u1, while Thinkpad has Debian 4.9.65-3+deb9u2.
    – Unix
    Jan 20 '18 at 2:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.