-
Notifications
You must be signed in to change notification settings - Fork 7
/
apple_ubuntu.sh
51 lines (43 loc) · 1.26 KB
/
apple_ubuntu.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
#!/bin/bash
## Define Variables
MODEL=`dmidecode -s system-product-name`
#~/.config/xfce4/xfconf/xfce-perchannel-xml/thunar-volman.xml
## Install webcam firmware
webcam() {
apt-get -y install cheese
apt-get -y install isight-firmware-tools
wget -qO /lib/firmware/AppleUSBVideoSupport http://fgc-nfs/iSight/AppleUSBVideoSupport
ift-extract -a /lib/firmware/AppleUSBVideoSupport
}
### Install Broadcom Wireless Driver
wireless() {
apt-get -y install firmware-b43-installer b43-fwcutter
}
## Fix touchpad issues
touchpad() {
### Current session
synclient FingerLow=10
synclient FingerHigh=20
### Permanently
if [ ! -d "/etc/X11/xorg.conf.d" ]; then
mkdir /etc/X11/xorg.conf.d
fi
echo 'Section "InputClass"
Identifier "touchpad catchall"
MatchIsTouchpad "on"
MatchDevicePath "/dev/input/event*"
Driver "synaptics"
Option "FingerLow" "10"
Option "FingerHigh" "20"
EndSection' >> /etc/X11/xorg.conf.d/10-synaptics.conf
}
echo "You are using an Apple $MODEL."
echo "Installing iSight webcam"
webcam
echo "Installing wireless drivers"
wireless
## Fix touchpad sensitivity for MACBOOK2,1 and MACBOOK4,1
if [ $MODEL = "MacBook2,1" ] || [ $MODEL = "MacBook4,1" ]; then
echo "Fixing touchpad sensitivity"
touchpad
fi