30 lines
924 B
Bash
Executable File
30 lines
924 B
Bash
Executable File
#!/bin/sh
|
|
|
|
# Description:
|
|
# Generates markdown documentation from nef playgrounds.
|
|
#
|
|
# Required environment variables:
|
|
# SRCROOT - path to project folder.
|
|
#
|
|
|
|
if [ -z ${SRCROOT} ]; then
|
|
echo run \'source setup\ to set SRCROOT environment variable
|
|
fi
|
|
|
|
for module_name in $(cat ${SRCROOT}/project-scripts/ordered_modules_list.txt); do
|
|
APP_FILE=${SRCROOT}/${module_name}/${module_name}.app
|
|
|
|
if [ -d "$APP_FILE" ]; then
|
|
nef compile --project $APP_FILE
|
|
nef markdown --project $APP_FILE --output ${SRCROOT}/docs
|
|
python3 ${SRCROOT}/project-scripts/gen_api_doc.py $module_name
|
|
|
|
# TODO: Open browser with figma ui documentation
|
|
# TODO: Open browser with git remote url
|
|
# TODO: Save state to run flow only if there are changes with documentation files
|
|
# TODO: Add a flag (like --no-doc) to skip api documentation flow
|
|
fi
|
|
done
|
|
|
|
open ${SRCROOT}/docs/api_doc.md
|