Secondary monitor driver on System76 laptop appears to be missing; how to determine what drivers to install?

Trying out NixOS on a System76 Oryx Pro. Happily, got reasonably far before finding something broken; my laptop doesn’t appear to detect a new device on the HDMI port.

I suspect there’s a cleaner way to determine whether the system is detecting a new device on the HDMI port, but the way I’m currently doing so is with xrandr:

xrandr --listmonitors
Monitors: 1
# Plug in HDMI cord
xrandr --listmonitors
Monitors: 1 # booooooo

On Pop OS, my prior operating system, this would return the other HDMI display.

How should I:

  1. Detect whether the system detected a new device
  2. Generally go about searching for drivers to install for said device
  3. Update my thought process to reduce dependency on this help forum?

If I understand right, the Oryx has two display adapters – one Intel, one Nvidia.

I have a hunch that the external display is connected to a different adapter than the laptop’s monitor, and that the driver for that other adapter isn’t loaded.

If you’re lucky, it may be as simple as loading the nvidia driver.

  services.xserver.videoDrivers = [ "nvidia" ];

You could also try some of the prime/optimus solutions documented on the Nvidia page in the NixOS Wiki. I’ve had decent luck with prime on some of my devices, but never attempted to make it work with external displays.

Did you ever figure this out? I’m struggling with the same problem. I’ve added nvidia to videoDrivers but still no luck getting an external monitor working.