Fork from inav at github. Modified for some special functions needs.
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.

57 lines
932 B

10 years ago
  1. #!/bin/bash
  2. filename=Manual
  3. doc_files=(
  4. 'Installation.md'
  5. 'Configuration.md'
  6. 'Cli.md'
  7. 'Board - AlienWii32.md'
  8. 'Board - CC3D.md'
  9. 'Board - CJMCU.md'
  10. 'Board - Naze32.md'
  11. 'Board - Sparky.md'
  12. 'Serial.md'
  13. 'Rx.md'
  14. 'Spektrum bind.md'
  15. 'Failsafe.md'
  16. 'Battery.md'
  17. 'Gps.md'
  18. 'Rssi.md'
  19. 'Telemetry.md'
  20. 'LedStrip.md'
  21. 'Display.md'
  22. 'Buzzer.md'
  23. 'Sonar.md'
  24. 'Profiles.md'
  25. 'Modes.md'
  26. 'Inflight Adjustments.md'
  27. 'Controls.md'
  28. 'Autotune.md'
  29. 'Migrating from baseflight.md')
  30. if which gimli >/dev/null; then
  31. echo "Building ${filename}.pdf"
  32. pushd . >/dev/null
  33. cd docs
  34. rm -f ${filename}.md
  35. for i in "${doc_files[@]}"
  36. do
  37. cat "$i" >> ${filename}.md
  38. done
  39. rm -f ${filename}.pdf
  40. gimli -f ${filename}.md
  41. rm ${filename}.md
  42. popd >/dev/null
  43. else
  44. echo -e "\nFAILED"
  45. echo "Install Gimli to build the PDF documentation"
  46. echo -e "https://github.com/walle/gimli\n"
  47. exit 1
  48. fi