Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
585 B

  1. BEGIN {
  2. FS="\t"
  3. printf "{\n"
  4. printf " dir = \"\"\n"
  5. printf "\n"
  6. }
  7. {
  8. if ($0 !~ /^;/ && $2 != ".")
  9. {
  10. printf " if ($4 ~ /%s/)\n",$2
  11. printf " dir = \"%s\"\n",$1
  12. # printf " else\n"
  13. }
  14. }
  15. END {
  16. printf "\n"
  17. printf " if (dir != \"\")\n"
  18. printf " {\n"
  19. printf " basename=substr($4,1,index($4,\".\")-1)\n"
  20. printf " printf \"cd %%s\\n\",dir\n"
  21. printf " printf \"log -r -v -i -t %%s > \\\\tmp\\\\log\\\\%%%%tgt%%%%\\\\%%s.txt\\n\",$1,basename\n"
  22. printf " }\n"
  23. printf "}\n"
  24. }