srclib is a polyglot code analysis library, built for hackability. It consists of language analysis toolchains (currently for Go and Java, with Python, JavaScript, and Ruby in beta) with a common output format, and a CLI tool for running the analysis.
Ruby toolchain install fails on OS X 10.10.3, Xcode 6.3, Build version 6D570, Command Line Tools 6.3. Command output found here: https://gist.github.com/lgw4/dbb44c4ba25adcb0a3d2