Skip to content

Commit

Permalink
make find command cross-platform
Browse files Browse the repository at this point in the history
  • Loading branch information
Joseph Wecker committed Sep 23, 2011
1 parent 6f9b4a5 commit 15b67c1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Rakefile
Expand Up @@ -120,7 +120,7 @@ namespace :samples do
search_paths << "'./#{user}/#{repo}'"
end
extensions.each do |ext|
cmd = "find -x -f #{search_paths.join(' ')} -iregex '.*\\.#{ext}' -type f -size 4"
cmd = "find #{search_paths.join(' ')} -iregex '.*\\.#{ext}' -type f -size 4"
candidate_files = `#{cmd}`.split("\n").map{|fn|fn.strip}
randf = candidate_files[rand(candidate_files.size)]
unless randf.nil? or randf == ''
Expand Down

0 comments on commit 15b67c1

Please sign in to comment.