Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Path-Class CPAN distribution.

Maintainer(s)' notes

I prefer that bugs & patches are filed on GitHub rather than on RT: Thanks.

Report information
The Basics
Id: 16056
Status: new
Priority: 0/
Queue: Path-Class

Owner: Nobody in particular
Requestors: dagolden [...]

Bug Information
Severity: Wishlist
Broken in: (no value)
Fixed in: (no value)

Content-Type: text/plain
Content-Disposition: inline
Content-Transfer-Encoding: binary
MIME-Version: 1.0
X-Mailer: MIME-tools 5.418 (Entity 5.418)
Subject: RFE: shorter synonyms for absolute & relative files and dirs
X-RT-Original-Encoding: iso-8859-1
Content-Length: 859
Download (untitled) / with headers
text/plain 859b
I find myself frequently switching to absolute pathnames. It's frustrating to have to sprinkle "->absolute" everywhere. E.g. for current directory, "dir()->absolute". I'd love to have a shorter synonym, e.g. "abs()". relative() could also be rel(). E.g. "dir()->abs". Another good (and easy) possibility might be to implement "absdir" and "absfile" to just wrap "dir" and "file" to return the absolute versions of each. Those functions would maintain brevity and clarity. I thought about being able to request absolute filenames as the default rather than relative in the import of Path::Class. E.g.: use Path::Class ':ABSOLUTE'; However, a toggle like this to the API could be a source of confusion to those later reading/maintaning the code, so I'm not sure if it's actually a good idea. (Mentioned just for completeness of my brainstorming.)

This service is sponsored and maintained by Best Practical Solutions and runs on infrastructure.

Please report any issues with to