New feature - exclude directory

  • Drake

    Drake - 2010-03-11

    Is there currently any way to do a list command and exclude a directory.  If not is this a feature that can be added???  I was able to grep the data I wanted but having it look through some huge directory it didn't need to is a waste of time/cpu. 

    Thanks very much..

  • Michael Jennings

    I agree. That would be a good feature, exclusions.

  • stahlworks

    stahlworks - 2010-03-11

    This feature is part of SFK since SFK exists, and at first I thought that it's described in the help text -
    but it isn't. Thanks for pointing that out. And now for the syntax:

    SFK for Windows example:

    sfk list -dir mydir !\tmp !\backup !\.svn -file .hpp .cpp .txt

    lists all .hpp .cpp and .txt files from the directory tree "mydir", however excluding
    all contained sub directories beginning with "tmp", "backup" or ".svn".
    if you leave out the backslashes "\" then this will also exclude all subdirs
    having "tmp" or "backup" in their name, or which end with extension ".svn".

    SFK for Linux example:

    sfk list -dir mydir :/tmp :/backup :/.svn -file .hpp .cpp .txt

    does the same as above, but as ever use ":" instead of "!",
    otherwise the linux shell will (mis)interpret the "!" character by itself.

  • Drake

    Drake - 2010-03-11

    That worked great!!!   Thank you…  :)


Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks