Created
September 19, 2012 16:56
-
-
Save goyuix/3750767 to your computer and use it in GitHub Desktop.
Getting around the "grep revision limit exceeded" in Perforce
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# p4 dirs //depot/* returns all the top level folders | |
# | |
# % means ForEach-Object, e.g. each top level folder from p4 dirs | |
# | |
# -s is to quiet the line length > 4096 noise | |
# -i is to make it case insensitive | |
# -e is followed by the search expression | |
# and the last argument is the path to search | |
p4 dirs //depot/* | % { p4 grep -s -i -e "search expression" "$_/..." } |
This isn't exactly robust. If your top-level dir branches out into other dirs and each dir has > 10k entries, this will not work
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Or in bash: