If you want speed over longer distances, I recommend to buy a Trekking bike. They have 700C wheels, and therefore are faster. My experience is that for 30 min or longer commutes I like speed. For this bike a derailleur gear is better so you can speed up.
If you like comfort, you can buy a Cannondale Badboy or similar. With 2" wide tires that handle well the potholes. To get from A to B in a big city, lots of stopping, changing directions, I liked the comfort better.
A third option can be a Brompton foldable bike, with 6 gears, which is the most versatile in city traffic, you can mix biking and public transport, and use whichever is faster/better. They last long, so good investment.
- If you are a serious commuter, ie not just when the sun is shining, and you ride in the rain, you need fenders.
- The rack is a must for carryng your bag. On such a ride I wouldn't wear a backpack. Check that the bike has braze-ons/eyelets for fenders, and for the rack. I recommend Tubus Cargo Evo. For the bag, I like the convertible ones, that can be hang on the rack, and used as a messengar/backpack, too. VauDe has such nice bags.
- Otherwise, I recommend to buy a bike that looks very "average". V-brakes, rigid forks, etc. nothing that tells it's an expensive bike.
- A hubgear gives more flexibility, to change gears at red lights when standing. 7-8 gears are enough, unless you need to tackle hills like in San Francisco, so a Shimano Nexus 7 or 8. I also commute 20 miles with a hubgear bike, for me it works, but many find it not enough.