Skip to content

Instantly share code, notes, and snippets.

@SkamDart
Last active May 3, 2017 18:06
Show Gist options
  • Save SkamDart/04574756b34d65b0cb26268b775b37f4 to your computer and use it in GitHub Desktop.
Save SkamDart/04574756b34d65b0cb26268b775b37f4 to your computer and use it in GitHub Desktop.
Sample bash commands for testing client PUT/GET
# fill in n with some integer
# run in foreground
for i in $(seq 0 n) ; do ./client localhost:4000 PUT file$i.txt file.txt ; done
# run in background
for i in $(seq 0 n) ; do ./client localhost:4000 PUT file$i.txt file.txt &
# diff all files in foreground
for i in $(seq 0 n) diff temp_dir/file$i file.txt ; done
mkdir tmp
for i in $(seq 0 n) ; do ./client localhost:4000 GET file$i.txt tmp/file$i.txt ; done
for i in $(seq 0 n) ; do diff file.txt tmp/file$i.txt ; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment