Rizwan Kassim - Pathabbr 0.3 - Includes support for Cygwin

Pathabbr doesn't compile on cygwin32 due to glibc not being completely implemented in cygwin. I've provided 0.3 with a modified Makefile and codebase that implements the missing functions.
Pathabbr 0.3 should be functionally equivalent to 0.2.
Original version

Download

pathabbr-0.3.tar.bz2 (12.3 kB)

Description

Pathabbr abbreviates paths to given length using ellipsis.

Pathabbr is primarily intended for shortening bash prompt. It's however quite general and everything, including the string used as ellipsis and the set of rules defining good places to break the path at, can be customized. Thus it can be used to abbreviate other path types than file/directory names.

Some simple examples:

$ cd /usr/X11R6/lib/X11/xkb/geometry/sgi
$ pwd | pathabbr 20
/usr/../geometry/sgi
$ pwd | pathabbr 30
/usr..lib/X11/xkb/geometry/sgi
$ pwd | pathabbr -r 0 30
/usr/X11R6/lib/../geometry/sgi
$ pwd | pathabbr -r 2.0 30
..1R6/lib/X11/xkb/geometry/sgi
$ pwd | pathabbr -e ">>>" 30
/usr/X11R6>>>/xkb/geometry/sgi

Changes in this version.

List of Changes:

Copying

Copyright © 2002 Yeti (David Necas) <yeti at physics dot muni dot cz>.

Copyright © 2005

  • Pathabbr is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. For full license text see file COPYING included in the source tarball.