facebookarchive / codemod

Codemod is a tool/library to assist you with large-scale codebase refactors that can be partially automated but still require human oversight and occasional intervention. Codemod was developed at Facebook and released as open source.
Apache License 2.0
4.12k stars 197 forks source link

Match all extensions / --extensions should accept glob arguments #30

Closed jonhoo closed 8 years ago

jonhoo commented 10 years ago

I have a codebase in which I would like to search all files within a certain directory for matches. This directory also has several files without an extension (shell scripts). At the moment, there is no way of specifying this in codemod as far as I'm aware?

modocache commented 9 years ago

I think this sounds like a great change! It sounds like it would be possible to accomplish this by having --extensions accept glob arguments. Then you could include all files in /path/to/dir by writing:

$ codemod.py -d /path/to/dir --extensions * --include-extensionless
jonhoo commented 9 years ago

Yes, that would be perfect.

ghost commented 9 years ago

Thank you for reporting this issue and appreciate your patience. We've notified the core team for an update on this issue. We're looking for a response within the next 30 days or the issue may be closed.