4 ms·
Popular languages on GitHub ranked by number of bytes stored
- sant0sk1 17y agoLove stuff like this. Wonder if C is that popular or if its verbosity is skewing the results?
- evdawg 17y agoYes, its verbosity is skewing the results. Same with PHP, C++, and Java. We can see that Ruby is the most popular language on Github here http://github.com/languages http://github.com/languages, with 28% of all projects being in Ruby. C, PHP, Java, and C++ rank 6%, 5%, 4%, and 4% respectively.
- WilliamLP 17y agoHow do you know it's verbosity skewing results, and not a preference for certain languages depending on the size of the project?
- lallysingh 17y agoThe only way to account for that is to compensate for verbosity between languages. I'm not sure anyone wants to go there, it's not pretty.
- dangoldin 17y agoYou can potentially have a sample of programs implemented in many different languages and compare the length of each program across languages. With enough programs you should be able to get a good enough sample as long as they are diverse enough.
- silentbicycle 17y agoGood point. Also, I wonder how those would be weighted if you counted projects that consist of >90% identical code as the same project (for example, how many of those Ruby projects are thinly veiled forks of Rails?), filtered out projects that are less than (say) 10k of source, etc. Maybe more Python projects are on bitbucket because of Merucial. The 90% and 10k there are pretty arbitrary; just, those language stats need a lot more clarification before their meaning is clear.
- wizard_2 17y agoI wonder if you could pull all the projects into one repo, repack and figure out it's unique objects using git. I always wondered if a global object store was possible or even a good idea for a site like github. I guess that's a different project though.
- silentbicycle 17y agoFWIW, finding duplicated code (particularly in a language-independent manner!) is a surprisingly difficult problem. You need to scan not just for large copy-and-pasted blobs, but code chunks that have just had constants changed, variable names adjusted, indentation style changes, etc. I've been working on a tool for this in my spare time, and I hope to have it out sometime this summer.
- deleted 17y ago[deleted]
- ryanwaggoner 17y agoOr perhaps since Rails/Ruby is trendy, a lot of projects get started in Ruby, but never finished. I'd like to see some language stats broken down by activity on the project.
- defunkt 17y agoThat's the direction we want to take it.
- csbartus 17y ago"a lot of projects get started in Ruby, but never finished." how do you know that?
- ryanwaggoner 17y agoI don't, hence the word perhaps.
- mpk 17y agoTime to invoke Sturgeon's law and mangle it a bit. 90% of all projects are junk.
- uggedal 17y agoThe C projects could also be more complete and mature. Everyone and their mother has a 50 line Ruby twitter-client/blog/wiki implementation up on Github. I would also argue that the presence of a Linux kernel mirror, Perl mirror, Android (including the Linux kernel, again), and large projects like them skews the byte vs projects percentages a great deal.
- teej 17y agoThe top languages calculation on GitHub is done by lines of code per language. By that calculation, there are 4.5x more Ruby LOC than C LOC on Github, yet C is still has the most bytes. http://github.com/blog/99-popular-languages http://github.com/blog/99-popular-languages
- silentbicycle 17y agoI'm pretty sure that lines of Ruby code tend to be shorter than lines of C. Static typing annotations tend to add to line length more directly than line count.
- defunkt 17y agoThat blog post is no longer accurate. We don't count LOC for language popularity, we count the number of non-fork projects that include a language. If your project includes both Ruby and Perl, Ruby and Perl each get a +1.
- cosmo7 17y agoThat doesn't mean they're the most popular. It might be people all sharing stuff to say "look how retarded this code is." (just saying)
- davidw 17y agoC is popular: http://langpop.com http://langpop.com However, in this case, yeah, verbosity is skewing things. Also, it should be noted that github numbers, like stack overflow, are still influenced by big initial communities with strong biases (Ruby, and C#, respectively). Still, though, interesting numbers, thanks!
- dhotson 17y agoPerhaps it's because of the linux kernel?
- ii 17y agoInteresting. A good example that illustrates why C is the top language is _why's shoes -- it's written mostly in C, but still belongs to Ruby-land.
- aston 17y agocloc does a rough estimation of the terseness/verbosity of the almost 80 languages it supports. It'd be pretty easy to incorporate those scaling factors for this analysis.
- jmtulloss 17y agoI know that I personally have a Clojure project that has many more lines of JavaScript than Clojure just because I have a large JavaScript library checked in with my other code. I wonder if there's a way to figure out unique lines of code, or unique files. jQuery really shouldn't be counted 5000 times, I would think.
- defunkt 17y agoWe exclude certain paths, especially popular JavaScript libraries.
- geirfreysson 17y agoAlso, check out the list of the most watched projects. Ruby and Rails seem to dominate there: http://github.com/popular/watched http://github.com/popular/watched
- mprovost 17y agoMy project shows up on github as Shell even though it's in C just because of all the autoconf/automake/libtool files. I imagine that's why Shell places so high on the list. For example, my 267 line configure.in file produces a 12952 line configure script. And a 6 line Makefile.am gets you a 683 line Makefile.
- cubicle67 17y ago33: SuperCollider er, what?
- donaq 17y agoIt's a language for real-time audio synthesis and algorithmic composition. http://en.wikipedia.org/wiki/SuperCollider http://en.wikipedia.org/wiki/SuperCollider
- grandalf 17y agoDon't forget that many projects include jquery, prototype, etc., which add quite a few points to js.
- ossenabled 17y agoI guess it's not clear to me how you rank popularity by number of bytes (or LOC). I really do like this information though! Thanks!