Two weeks ago I launched "Learn Ruby on Rails" with a Kickstarter campaign: http://www.kickstarter.com/projects/909377477/learn-ruby-on-...
(You can read more about the book here:
http://learn-rails.com/learn-ruby-on-rails.html
if you want to help with a new book for Rails beginners).
In less than two weeks I've raised over $4000. Significantly, nearly a third of revenue is from people who found out about the book on Kickstarter. So, Leanpub is great, but first, do a Kickstarter campaign. You get advance sales, a significant market channel, sales of a book at multiple price points (customers choose different pledge levels), and the additional boost of time-limited, event-driven marketing. Publishing is not dead; it's booming thanks to new market channels like Leanpub and Kickstarter. And yes, you have to build a following first.