Created
August 31, 2016 11:02
-
-
Save plombix/f103456d6709ed3b52f337728083d7d8 to your computer and use it in GitHub Desktop.
Basic ruby string operation to find if file is '.erb' or not
This file contains 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
class String | |
def erb? | |
self[-3..-1] == "erb" | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment