xcstats
is a command line tool for analyzing Xcode project and prints statistics of source codes like rake stats
.
This project leverages SwiftSyntax to generate Swift code statistics that describes how many Swift types (class, struct, enum, etc.) are declared on your project.
- Xcode 10.1
Using homebrew:
$ brew tap horimislime/taproom
$ brew install xcstats
You can also download portable executable from releases and install it manually.
Under your Xcode project root, just hit xcstats
.
$ cd /path/to/your/project/root
$ xcstats
Generate .xcodeproj with make xcodeproj
and open it in Xcode 10.1 or later.
This project is still under early development. Missing features are:
- Specifying Xcode project path other than current working directory
- Detailed Objective-C code statistics (currently xcstats only prints lines/LOC. I need SwiftSyntax for ObjC! 😄)
- And some other useful statistics (number of tests, assets, etc.)