Author Topic: excluding .git directories  (Read 1899 times)

flethuseo

  • Senior Community Member
  • Posts: 177
  • Hero Points: 2
excluding .git directories
« on: April 04, 2014, 03:58:32 pm »
Hi all,

What regular expression do I use to omit all .git subdirectories. I can do so successfully for the current directory, but can't get it to do it for all subdirectories (recursively).

Ted

Graeme

  • Senior Community Member
  • Posts: 2232
  • Hero Points: 277
Re: excluding .git directories
« Reply #1 on: April 05, 2014, 12:44:16 am »
You forgot to say what operation you were trying to do.

If it's find in files then the help file says

Exclude - Paths, files, or file types can be excluded from a multi-file search by specifying them with wildcards or full path names. To specify multiple patterns, separate them with semicolons (colons on UNIX). No files are searched in a path that is excluded, including any files in sub-directories beneath. See examples of exclude patterns, below.

So *.git* should exclude any path with .git in its name.  If it doesn't work you could report it to SlickEdit Inc and maybe get a hotfix.


jporkkahtc

  • Senior Community Member
  • Posts: 1682
  • Hero Points: 161
  • Text
Re: excluding .git directories
« Reply #2 on: April 07, 2014, 07:41:38 pm »
For excluding subdirectories, I use the syntax "name\"
So, in FindAndReplace, I use something like this for exclusion:
    *.o;.git\;*.exe

This also works in "add tree" for a project.

I don't think Slick supports "*" or other patterns for directory exclusions.
See here: http://community.slickedit.com/index.php/topic,9190.msg39202.html#msg39202

flethuseo

  • Senior Community Member
  • Posts: 177
  • Hero Points: 2
Re: excluding .git directories
« Reply #3 on: April 09, 2014, 05:31:45 pm »
Yes, I forgot to specify where.. I meant on the Project properties, add tree. I was adding the .git part incorrectly something like this **/*.git*, but .git\ worked fine.