Skip to content

Instantly share code, notes, and snippets.

@shawn42
Created March 5, 2009 01:46
Show Gist options
  • Save shawn42/74130 to your computer and use it in GitHub Desktop.
Save shawn42/74130 to your computer and use it in GitHub Desktop.
STATS_DIRECTORIES = [
%w(Source src/),
%w(Config config/),
%w(Maps maps/),
%w(Unit\ tests specs/),
%w(Libraries lib/),
].collect { |name, dir| [ name, "#{APP_ROOT}/#{dir}" ] }.select { |name, dir| File.directory?(dir) }
desc "Report code statistics (KLOCs, etc) from the application"
task :stats do
require 'code_statistics'
CodeStatistics.new(*STATS_DIRECTORIES).to_s
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment