module Sprockets::PathUtils
def split_subpath(path, subpath)
Returns relative String path if subpath is a subpath of path, or nil if
subpath - String subpath of path
path - String path
Internal: Get relative path for root path and subpath.
def split_subpath(path, subpath) return "" if path == subpath path = File.join(path, '') if subpath.start_with?(path) subpath[path.length..-1] else nil end end