I'd like to hg add excluding files that begin with ._, or even better exclude all hidden files.

It's not working, it's just completely ignoring my -X option.

I tried the following:

hg add -n -X '._*'
hg add -n -X '*._*'

and just to be sure also:

hg add -n -X '*.*'

nothing. It's just as if I didn't -X at all.

I've tried both with hg 1.4.3 and hg 1.0.1

link|improve this question

80% accept rate
feedback

1 Answer

up vote 1 down vote accepted

(This works on Windows and Mercurial 1.5.3; things may be different for Unix if that's what you're using).

You have the file spec. in single quotes; it should be double quotes:

hg add -X "._*"

Another way would be to add an entry to your .hgignore file, for example:

 syntax: glob
 ._*
link|improve this answer
I'll have a look at .hgignore because it seems it should do it, thanks :) (btw: I'm using OSX) – Lohoris May 29 '10 at 16:07
it worked, thanks :) – Lohoris May 31 '10 at 20:06
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.