Created
December 19, 2016 14:26
-
-
Save yjh0502/1355939dc89a055029d1161e5501a50a to your computer and use it in GitHub Desktop.
This file contains 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
#!/usr/bin/env bash | |
mkdir -p foo bar | |
seq -w 0 100 | xargs -n1 -I{} touch foo/{}.c | |
echo '["subscribe","./","mysub",{"fields":["name"],"expression":["allof",["type","f"],["not","empty"],["suffix","c"]]}]' | watchman -p -j --server-encoding=json > /dev/null & | |
while true; do find bar/ -type f | xargs -n1 -P5 -I'{}' mv '{}' foo; done & | |
while true; do find foo/ -type f | xargs -n1 -P5 -I'{}' mv '{}' bar; done & | |
wait |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment