DragonFly On-Line Manual Pages
CURLY(1L) CURLY(1L)
NAME
curly, uncurly - expand or build csh-like path expressions
SYNOPSIS
curly [expressions]
uncurly [-depth] [names]
DESCRIPTION
Curly expands a csh(1) curly brace expression. Such an expression is
of the form
prefix{E1,E2,E3}suffix
which expands to
prefixE1suffix
prefixE2suffix
prefixE3suffix
any subexpressions are also expanded.
Uncurly compresses a given path expression into a minimal curly
expression. Thus
uncurly ab.c ab.h de.c de.h ef.c ef.h
produces this output
{ab,de,ef}.{c,h}
Either product will run in a filter mode if no arguments are provided.
OPTIONS
Both programs take the standard help (-h) and version (-V) options. In
addition uncurly takes an integer -depth option to limit the depth of
the compression search.
EXAMPLES
cd; find . -depth -print | uncurly >/tmp/files.u
save a compressed list of the files in my home directory in
/tmp/files.u.
curly </tmp/files.u | xargs my-tool
Use xargs to run my-tool on each of the saved names in
/tmp/files.u.
sort /tmp/mylist | uncurly -2 >/tmp/mylist.u
Compress a sorted list of the names in /tmp/mylist, but limit
the compression to 2 nested levels of curlies.
BUGS
Files with curly braces in their names are problems.
AUTHOR
Kevin Braunsdorf
Distributed Systems Process Development
ksbrauns@fedex.com
SEE ALSO
csh(1), find(1), xargs(1)
LOCAL CURLY(1L)