Xcode is really narrowly focused on iOS and macOS software development. You probably installed it as the obvious way to get all the dev stuff installed (headers, compilers, etc). You'd need those to build any native extensions for gems.

For IDEs for many other languages, lots of people swear by JetBrains' stuff. I think they have a PHP IDE. I know they have Ruby, Python, and Go. And Java was where they started.

// @kdfrawg