Prechádzať zdrojové kódy

fix nvidia hook logic

Casey DeLorme 2 rokov pred
rodič
commit
6f1cb8c166
1 zmenil súbory, kde vykonal 1 pridanie a 0 odobranie
  1. 1 0
      arch.sh

+ 1 - 0
arch.sh

@@ -118,6 +118,7 @@ if [ $(lspci | grep -i "vga" | grep -ci "nvidia") -gt 0 ]; then
 	[ $(grep -c "nvidia" /etc/mkinitcpio.conf) -eq 0 ] && sed -i 's/MODULES=(\(.*\))/MODULES=(\1 nvidia nvidia_modeset nvidia_uvm nvidia_drm)/' /etc/mkinitcpio.conf
 
 	# automatic mkinitcpio updates in pacman.d
+	mkdir -p /etc/pacman.d/hooks
 	echo -e "[Trigger]\nOperation=Install\nOperation=Upgrade\nOperation=Remove\nType=Package\nTarget=nvidia\n\n[Action]\nDepends=mkinitcpio\nWhen=PostTransaction\nExec=/usr/bin/mkinitcpio -P" > /etc/pacman.d/hooks/nvidia.hook
 fi