Jump to content

SH Script doubt ;)


  • Please log in to reply
No replies to this topic

#1
aspirina750

aspirina750

    InsanelyMac Protégé

  • Members
  • PipPip
  • 69 posts
  • Gender:Male
  • Location:Barcelona, Spain
Hi there guys, I have a small doubt and wanted your opinion. Right now I'm using my laptop, an Acer Travelmate C200, with an external LCD because with the integrated GeForce Go 6200TC is impossible to get QE & CI working in the internal one, I only get white snow :thumbsup_anim:
Anyway, sometimes I need to use my laptop outside the office and wanted a script that deleted the ext that enabled the external screen and moved the old ones without QE & CI for the internal one. I did this, but I'm afraid to try it without checking with you guys first, just in case :hysterical:

Enabling the internal screen:
#!/bin/sh
sudo su
rm -fr /System/Library/Extensions/NVDANV40Hal.kext
rm -fr /System/Library/Extensions/GeForce.kext
rm -fr /System/Library/Extensions/NVDAResman.kext
rm -fr /System/Library/Extensions/NVinjectGo.kext
ditto /System/Library/Extensions/video_int/NVDANV40Hal.kext /System/Library/Extensions/
ditto /System/Library/Extensions/video_int/GeForce.kext /System/Library/Extensions/
ditto /System/Library/Extensions/video_int/NVDAResman.kext /System/Library/Extensions/
chown -R root:wheel /System/Library/Extensions/NVDANV40Hal.kext
chmod -R 755 /System/Library/Extensions/NVDANV40Hal.kext
chown -R root:wheel /System/Library/Extensions/GeForce.kext
chmod -R 755 /System/Library/Extensions/GeForce.kext
chown -R root:wheel /System/Library/Extensions/NVDAResman.kext
chmod -R 755 /System/Library/Extensions/NVDAResman.kext
rm /System/Library/Extensions.mkext
rm /System/Library/Extensions.kextcache
diskutil repairpermissions /

Enabling the External LCD
#!/bin/sh
sudo su
rm -fr /System/Library/Extensions/NVDANV40Hal.kext
rm -fr /System/Library/Extensions/GeForce.kext
rm -fr /System/Library/Extensions/NVDAResman.kext
ditto /System/Library/Extensions/video_ext/NVDANV40Hal.kext /System/Library/Extensions/
ditto /System/Library/Extensions/video_ext/GeForce.kext /System/Library/Extensions/
ditto /System/Library/Extensions/video_ext/NVDAResman.kext /System/Library/Extensions/
ditto /System/Library/Extensions/video_ext/NVinjectGo.kext /System/Library/Extensions/
chown -R root:wheel /System/Library/Extensions/NVDANV40Hal.kext
chmod -R 755 /System/Library/Extensions/NVDANV40Hal.kext
chown -R root:wheel /System/Library/Extensions/GeForce.kext
chmod -R 755 /System/Library/Extensions/GeForce.kext
chown -R root:wheel /System/Library/Extensions/NVDAResman.kext
chmod -R 755 /System/Library/Extensions/NVDAResman.kext
chown -R root:wheel /System/Library/Extensions/NVinjectGo.kext
chmod -R 755 /System/Library/Extensions/NVinjectGo.kext
rm /System/Library/Extensions.mkext
rm /System/Library/Extensions.kextcache
diskutil repairpermissions /

Will this work, any suggestions?

Thanks!!!





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

© 2014 InsanelyMac  |   News  |   Forum  |   Downloads  |   OSx86 Wiki  |   Mac Netbook  |   PHP hosting by CatN  |   Designed by Ed Gain  |   Logo by irfan  |   Privacy Policy