Created
November 30, 2017 18:42
-
-
Save gbpereira/f48daf5f97928752121c61ec4674a847 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
require 'find' | |
dir = ARGV[0] | |
input = File.open(ARGV[1]).read | |
# output = File.new((ARGV[2] || 'output'), 'w+') | |
# puts "searching for #{input.lines.count} files starting at #{dir}" | |
input.each_line do |filename| | |
# puts '*' | |
Find.find(dir) do |path| | |
if path.match(filename.gsub("\n", '')) | |
# output.puts(path) | |
puts path | |
end | |
end | |
end | |
# puts "output: #{output.path}" | |
# output.close |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment