It's easy when you've made sure the entire company leans the same way though. It would be odd to be a right-winger and work in Google--knowing that they're doing everything they can to hurt me. But of course money is money and everybody has a price.
I'm a right-winger in a leftist workplace. The key is just to keep your head down whenever politics comes up, and never participate in discussion about controversial topics. Generally I would act the same in a right-leaning atmosphere if one ever existed anyway, but at least then I wouldn't hear my coworkers' rants.