Skip to content

Instantly share code, notes, and snippets.

@RachelSa
Created December 5, 2016 01:58
Show Gist options
  • Save RachelSa/9c7b1bbf6e3d4818b5361ce1b9e87b56 to your computer and use it in GitHub Desktop.
Save RachelSa/9c7b1bbf6e3d4818b5361ce1b9e87b56 to your computer and use it in GitHub Desktop.
Dir.foreach
def emoji_finder(file_path)
Dir.foreach(file_path) {|pic|
if pic[-3..-1] == 'png'
puts pic
end
}
end
emoji_finder('/Users/rachel/dev/EmojiFinder/ProfileImages')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment