I’m building a little script and I’d need to know some way of testing if a path (a string for example) is outside another path (another string). For example:
/some/path and /some/path/file.rb would return false because file.rb is inside /some/path but /some/path and /some/file.rb would return true because file.rb it’s outside /some/path.
Thanks in advance!
You could use
String#starts_with?:And: