tar_qsub.sh 499 B

1234567891011121314151617181920212223242526272829303132333435
  1. #!/bin/csh
  2. if ($#argv == 0) then
  3. goto help_lbl
  4. exit
  5. endif
  6. set flist = ""
  7. set fout = ""
  8. foreach arg ($argv)
  9. @ counter++
  10. if ("$arg" == "-d") then
  11. @ counter++
  12. set flist = $argv[$counter]
  13. endif
  14. if ("$arg" == "-f") then
  15. @ counter++
  16. set fout = $argv[$counter]
  17. endif
  18. end
  19. if ("$fout" == "" || "$flist" == "") goto help_lbl
  20. tar -czvf $fout -T $flist
  21. #########################
  22. #### Help procedure #####
  23. #########################
  24. help_lbl:
  25. echo "help :D"