bash_test.sh 295 B

12345678910111213141516
  1. #!/bin/bash
  2. times=$1
  3. rm -rf OUTPUT
  4. [ $times -gt 0 2> /dev/null ] || times=300
  5. time for (( c=1; c<=$times; c++ ))
  6. do
  7. echo "hello $c" >> OUTPUT
  8. cp somefile ./testdir/somefile
  9. rm -rf ./testdir/somefile
  10. ls ./testdir/ >> OUTPUT
  11. cat somefile > ./testdir/x
  12. date >> OUTPUT
  13. done
  14. #cleanup
  15. rm ./testdir/x