Detect the presence of your Bluetooth device and execute actions on your Mac.

BlueSense analyzes the signal of your Bluetooth device and executes any desired actions when you move or come back at proximity of your Mac.

BlueSense requires OS X 10.10 or later
BlueSense AppleScripts

How to enable Mac OS X session auto login in AppleScript

Re-enable Mac OS X Automatic login with your username.

script EnableAutomaticLogin
	set my_password to getPassword(KeychainPasswordName)
	set my_username to getUsername()
	do shell script ("/usr/bin/defaults write /Library/Preferences/ autoLoginUser " & quoted form of my_username) user name my_username password my_password with administrator privileges
on error errString number errorNumber
	log (errString)
end try
end script