Pathname2

Software Screenshot:
Pathname2
Software Details:
Version: 1.7.3
Upload Date: 13 May 15
Developer: Daniel Berger
Distribution Type: Freeware
Downloads: 295

Rating: 5.0/5 (Total Votes: 2)

The differences between Pathname in the standard library and this version:

It is a subclass of String (and thus, mixes in Enumerable).
It has sensical to_a and root instance methods.
It works on Windows and Unix.  The current implementation does not work with Windows path names very well, and not at all when it comes to UNC paths.
The Pathname#cleanpath method works differently - it always returns a canonical pathname.  In addition, there is no special consideration for symlinks (yet), though I'm not sure it warrants it.
The Pathname#+ method auto cleans.
It uses a facade for all File and Dir methods, as well as most FileUtils methods.
Pathname#clean works slightly differently.  In the stdlib version, Pathname#clean("../a") returns "../a".  In this version, it returns "a". This affects other methods, such as Pathname#relative_path_from.
Accepts file urls and converts them to paths automatically, e.g. file:///foo bar/baz becomes '/foo/bar/baz'.
Adds a Kernel level +pn+ method as a shortcut.
Allows you to add paths together with the '/' operator.

What is new in this release:

  • The basename and dirname methods now return Pathname objects.

What is new in version 1.6.3:

  • Updated Windows platform handling code to include mingw and cygwin.
  • Added the :gem rake task.
  • Minor gemspec updates.
  • Some minor test suite updates.

Requirements:

  • Ruby 1.8.0 or higher
  • facade 1.0.0 or higher
  • Windows-pr 0.5.1 or higher

Similar Software

jQuery
jQuery

2 Oct 16

java-oembed
java-oembed

10 Dec 15

libphonenumber
libphonenumber

13 Apr 15

Apache Ivy
Apache Ivy

1 Mar 15

Other Software of Developer Daniel Berger

HTML-table
HTML-table

13 Apr 15

crypt-fog
crypt-fog

24 Feb 15

ptools
ptools

10 Dec 15

net-tnsping
net-tnsping

13 May 15

Comments to Pathname2

Comments not found
Add Comment
Turn on images!