module Git::Repository::Staging::Private
Private helpers local to {Git::Repository::Staging}
@api private
Public Instance Methods
Source
# File lib/git/repository/staging.rb, line 397 def unescape_quoted_path(path) if path.start_with?('"') && path.end_with?('"') Git::EscapedPath.new(path[1..-2]).unescape else path end end
Unescape a git-quoted path
Git wraps paths containing non-ASCII or special characters in double-quotes and octal-escapes each byte. This method strips the surrounding quotes and delegates unescaping to {Git::EscapedPath}.
@param path [String] the path as it appears in git output
@return [String] the unescaped path