Automounting usb devices with udev only

Fiddling a little bit with udev rules to automount usb drives. Udev is just amazing, can do about whatever you want! The following rules must be added to one of the .rule files in /etc/udev/rules.d (for example: 98usb-storage.rule):

#Custom USB MountingACTION=="add", KERNEL=="sdb[1-9]", DRIVERS=="usb-storage", NAME="%k"ACTION=="add", KERNEL=="sdb[1-9]", DRIVERS=="usb-storage", SYMLINK+="usbdisk-%k", GROUP="plugdev"ACTION=="add", KERNEL=="sdb[1-9]", DRIVERS=="usb-storage", RUN+="/bin/mkdir -p /media/%k"ACTION=="add", KERNEL=="sdb[1-9]", DRIVERS=="usb-storage", RUN+="/bin/chown root:plugdev /media/%k"ACTION=="add", KERNEL=="sdb[1-9]", DRIVERS=="usb-storage", RUN+="/bin/chmod 775 /media/%k"ACTION=="add", KERNEL=="sdb[1-9]", DRIVERS=="usb-storage", RUN+="/bin/mount -t vfat -o noauto,rw,user,uid=1000,gid=1/dev/%k /media/%k"ACTION=="remove", KERNEL=="sdb[1-9]", RUN+="/bin/umount -l /media/%k"ACTION=="remove", KERNEL=="sdb[1-9]", RUN+="/bin/rmdir /media/%k"

Info comes from here: http://reactivated.net/writing_udev_rules.html http://wiki.archlinux.org/index.php/Udev