Project

General

Profile

Feature #3356

Add GetShortPathName to ruby

Added by docwhat (Christian Höltje) about 10 years ago. Updated over 4 years ago.

Status:
Feedback
Priority:
Normal
Target version:
-
[ruby-core:30470]

Description

=begin
Hi!

I use Ruby on windows and it would be really useful to have access to GetShortPathName in ruby.

I have a monkey-patch to add Pathname.shortpath (attached) to demonstrate it. Probably realpath, etc. should take this in to account as well, since in windows, only the shortpath is canonical.

In addition, the shortpath doesn't need to be escaped, so you can use it with backticks (`), etc.

Ciao!
=end


Files

pathname-shortpath.rb (640 Bytes) pathname-shortpath.rb Monkey patch to pathname docwhat (Christian Höltje), 05/28/2010 01:42 AM

Also available in: Atom PDF