I put code on GitHub on the off chance someone else will find it useful or informative. Between the user base, platform usability, and the fact that I use git anyway, it's convenient for that. But "portfolio" isn't really a consideration.
If, for some reason, you want a portfolio anyway: my recommendation would be private website + GitHub. Preferably, in the form of writing an article demonstrating why a given project on GitHub is novel or interesting or useful. If you go that way, any off-the-shelf blogging tool should work (e.g. Jekyll / Octopress + GitHub Pages), and it will tend to be more useful to the community as large (which increases the odds of other devs explicitly being interested in working with you).