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.

34 lines
831 B

  1. #! /bin/sh
  2. #
  3. # Script to display the Japanese translation status of documents
  4. #
  5. if [ ! -d docs/ja ]; then
  6. echo "'docs/ja' not found."
  7. echo "do:"
  8. echo " cd \$(QMK_TOP)"
  9. echo " ./docs/ja/ja_doc_status.sh"
  10. exit 1
  11. fi
  12. en_docs=`cd docs;ls -1 [a-z]*.md`
  13. ja_docs=`cd docs/ja;ls -1 [a-z]*.md`
  14. en_count=`echo $en_docs | wc -w`
  15. ja_count=`echo $ja_docs | wc -w`
  16. echo "English documents $en_count files."
  17. echo "Japanese documents $ja_count files."
  18. echo "Files that have not been translated yet:"
  19. for docfile in $en_docs
  20. do
  21. if [ ! -f docs/ja/$docfile ]; then
  22. wc docs/$docfile
  23. fi
  24. done | sort
  25. echo "Files that have not been updated yet:"
  26. grep --no-filename "^[ ]*git diff" docs/ja/*.md | while read cmd
  27. do
  28. cline=`echo $cmd | sh | wc -l`
  29. if [ $cline -gt 0 ]; then
  30. echo "$cline $cmd"
  31. fi
  32. done | sort