Skip to content

harris-chris/tree-surgeon

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Documentation

View the full documentation

Tree surgeon

A mini-language for pruning your directory trees

Tree surgeon is a tool for applying complex (or simple!) filters to directory trees. For example:

$ tree-surgeon tree-diff -f 'endsWith ".md" (basename file)' -s ~/Documents

will show a before & after of your ~/Downloads folder, if all but the markdown (*.md) files were filtered out.

Then:

$ tree-surgeon tree-diff \
    -f 'endsWith ".md" (basename file) | elem "myProjectFiles" (parents file)' \
    -s ~/Documents

will show the same output, plus any files that are holdings (at any level) of the myProjectFiles folder (thanks to the | logical or operator).

See the language tour for more information about how to write filter expressions.

To see a list of available commands:

$ tree-surgeon --help

Supported systems

Only x864_64-linux at the moment.

About

Define and run filters for directory trees

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published