George Hotz was the first to release a jailbreak app for the iPhone 3GS -- the only problem was that it was only available for Windows. Now there's a Mac-based jailbreak solution for the 3GS, Purplera1n RC2a has been released for the Mac. iPhoneHacks.com has posted a detailed step-by-step of the process.
If simply jailbreaking your iPhone isn't enough and you feel compelled to unlock your shiny new iPhone 3GS too, there's an app for that. If you've jailbroken via Purplera1n RC2a you can use the iPhone Dev Team's UltraSn0w to unlock an iPhone 3GS (video).