Method: Bundler::SharedHelpers#relative_path_to
- Defined in:
- lib/bundler/shared_helpers.rb
permalink #relative_path_to(destination, from: pwd) ⇒ Object
[View source]
233 234 235 236 237 238 |
# File 'lib/bundler/shared_helpers.rb', line 233 def relative_path_to(destination, from: pwd) Pathname.new(destination).relative_path_from(from).to_s rescue ArgumentError # on Windows, if source and destination are on different drivers, there's no relative path from one to the other destination end |