Date Added: Nov 2012
Traditional Unix tools operate on sequences of characters, bytes, fields, lines, and files. However, modern practitioners often want to manipulate files in terms of a variety of language-specific constructs -C functions, Cisco IOS interface blocks, and XML elements, to name a few. These language-specific structures quite often lie beyond the regular languages upon which Unix text-processing tools can practically compute. In this paper, the authors propose eXtended Unix text-processing tools (xutools) and present implementations that enable practitioners to extract (xugrep), count (xuwc), and compare (xudiff) texts in terms of language-specific structures. They motivate, design, and evaluate their tools around real-world use cases from network and system administrators, security consultants, and software engineers from a variety of domains including the power grid, healthcare, and education.