diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2005-03-06 23:39:12 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2005-03-06 23:39:12 +0000 |
commit | 693e0df352e52dd5b3d1b191bbd018cd17023343 (patch) | |
tree | 07833c042daac63a4e52a14d50d9ad37f3f9156f /railties/lib | |
parent | 86543a70fb93069d2522dad00edf06c1ef2570de (diff) | |
download | rails-693e0df352e52dd5b3d1b191bbd018cd17023343.tar.gz rails-693e0df352e52dd5b3d1b191bbd018cd17023343.tar.bz2 rails-693e0df352e52dd5b3d1b191bbd018cd17023343.zip |
Fixed rake stats to ignore editor backup files like model.rb~ #791 [skanthak]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@868 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'railties/lib')
-rw-r--r-- | railties/lib/code_statistics.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/railties/lib/code_statistics.rb b/railties/lib/code_statistics.rb index efe8fc2454..ea3c1ad66d 100644 --- a/railties/lib/code_statistics.rb +++ b/railties/lib/code_statistics.rb @@ -23,7 +23,7 @@ class CodeStatistics @pairs.inject({}) { |stats, pair| stats[pair.first] = calculate_directory_statistics(pair.last); stats } end - def calculate_directory_statistics(directory, pattern = /.*rb/) + def calculate_directory_statistics(directory, pattern = /.*\.rb$/) stats = { "lines" => 0, "codelines" => 0, "classes" => 0, "methods" => 0 } Dir.foreach(directory) do |file_name| |