New Ticket     Wiki     Browse Source     Timeline     Roadmap     Ticket Reports     Search

Ticket #21873 (new enhancement)

Opened 5 months ago

Last modified 5 months ago

fs-traverse: Add -strip option to remove path prefix

Reported by: raimue@… Owned by: macports-tickets@…
Priority: Normal Milestone: MacPorts Future
Component: base Version:
Keywords: Cc:
Port:

Description

fs-traverse currently returns the full path name combined from the path argument and the "local" file name. It would be helpful to have an option to get the "local" part only.

Example:

fs-traverse f /path/to/foo {
    puts $f
}

=>

/path/to/foo/file1
/path/to/foo/file2
...
fs-traverse -strip f /path/to/foo {
    puts $f
}

=>

file1
file2
...

Change History

Changed 5 months ago by blb@…

If we want to be consistent with Tcl, perhaps we should call it -tails like the option for glob?

Note: See TracTickets for help on using tickets.