Every time I boot my laptop I go blind. I can use xrandr to set the brightness but it becomes a rather impractical. I also use LUKS so when I boot the computer I am always greeted with (from what I think) cryptsetup.Is there a way to run my desired xrandr command when I am asked for the encryption password? Otherwise, when is the earliest (from turning on the laptop) that I can do this and where/how should I configure this?Amongst other stuff I have tried rc.local, /etc/gdm3/Init/Display, /etc/X11/xinit/xinitrc but nothing seems to work. I am running Ubuntu 16.10 with Gnome and the command I try to run is xrandr --output eDP-1 --brightness 0.3.Some updates:Some more info on my hardware and what I have tried.I have the XPS 15 9550 which comes with Intel Skylake and a dedicated Nvidia graphics card. I have disabled the Nvidia card from the Nvidia X Server Settings GUI tool.I have only intel_backlight in /sys/class/backlight by default. I can edit the brightness from there between 0 and 12 but the brightness at 1 is still too bright.I have tried altering the /etc/default/grub to include acpi_backlight=vendor. That creates the entry /sys/class/backlight/dell_backlight. This gives some more control but it's very unstable (brightness jumping here and there and freezes).I have tried altering the /etc/default/grub to include acpi_backlight=video. That creates the entry /sys/class/backlight/acpi_video0 which permits more granularity (0-66). However the monitor still uses the intel_backlight. I tried to solve this by explicitly configuring the xorg.conf to use the ACPI backlight but to no vail.
Earliest I can run xrandr?
gnome3;luks;xrandr;cryptsetup;brightness