Ultimately we are looking for creative hackers, and public projects are crucial in determining the inquisitiveness of a potential candidate. Other employers may have different priorities, but I think most startups are looking for similar types.
My biggest fear when hiring someone is that they're so image conscious that every commit must look perfect... I know this ads about a 20% time overhead onto everything and not only is it extremely vane, is typically part of a quest to get job offers, etc. In general not things that are valuable to the current employer at all.
It's great if I'm impressed with their code, but bad code isn't necessarily a negative. I'm much more interested in why they wrote it a certain way then looking at their code with no context. Everyone out there has written bad code, it's understanding the decisions made behind the code that's interesting to me, in regards to whether or not a candidate will make a good employee.
1) They are interested in coding. This was done on their own time, away from work. This means they actually like to code.
2) A lot of work is done to learn a new language/technology. This often shows desire to learn and the ability to at least hack together something that is new to them. This is important because we will be asking them to come up to speed quickly in our code base.
3) You can look at the code and get a feel for how they code. We are a small team and each developer will have the ability to have a big impact (for good or bad). Getting an idea of how they think, how they solve problems is a huge plus.
I don't think you need to have a lot of code available. Pick your favorite project, or 'best' project and make it available. I see very little downside.
a) I wanted to expand my skill set and work on a language and environment that I don't get to explore in my current job.
b) I want to have something to show potential employers to let them know that I am passionate about development and more than just a 9-5 programmer.
The issue I currently have is that the code is ugly and there are lots of things that I feel I could refactor and clean up. I might always feel this way as I am sure I will never have anything "perfect". I am wanting to get it live within the next few weeks and I think that I will have to accept that I just need to get it live and then focus on improving it after I have had feed back from users etc.
If you publish code, even if it is buggy, you have proof that you can code (which is pretty important). However, I'd ensure that it works. If you are aware of bugs, document them in the code.
Would you buy clothes at a store that didn't let you see them until you bought them?
(I've only seen this for Ruby jobs though... Java is tending towards 'Are you using these libraries in your current position? No? Thanks for your application but...'.)