summaryrefslogtreecommitdiffstats
path: root/config/revdepth-nt.pl
diff options
context:
space:
mode:
Diffstat (limited to 'config/revdepth-nt.pl')
-rw-r--r--config/revdepth-nt.pl19
1 files changed, 19 insertions, 0 deletions
diff --git a/config/revdepth-nt.pl b/config/revdepth-nt.pl
new file mode 100644
index 00000000..8b8a85f5
--- /dev/null
+++ b/config/revdepth-nt.pl
@@ -0,0 +1,19 @@
+#! /usr/local/bin/perl
+#
+# BEGIN COPYRIGHT BLOCK
+# Copyright 2001 Sun Microsystems, Inc.
+# Portions copyright 1999, 2001-2003 Netscape Communications Corporation.
+# All rights reserved.
+# END COPYRIGHT BLOCK
+#
+
+require "/ns/config/fastcwd.pl";
+
+$cur = &fastcwd;
+chdir($ARGV[0]);
+$newcur = &fastcwd;
+$newcurlen = length($newcur);
+
+# Skip common separating / unless $newcur is "/"
+$cur = substr($cur, $newcurlen + ($newcurlen > 1));
+print $cur;