mirror of
https://github.com/langchain-ai/langgraph.git
synced 2026-08-17 21:25:46 +02:00
* Adds a conversion script from ipython notebook to markdown. * Replaces one ipython notebook (create react agent) with a markdown file for testing. --------- Co-authored-by: Ben Burns <803016+benjamincburns@users.noreply.github.com>
25 lines
710 B
Bash
Executable File
25 lines
710 B
Bash
Executable File
ERROR_FOUND=0
|
|
for file in $(find $1 -name "*.ipynb" | grep -v ".ipynb_checkpoints"); do
|
|
# Adding regexp to ignore base64 strings
|
|
OUTPUT=$(cat "$file" | jupytext --from ipynb --to py:percent | codespell --ignore-regex='[A-Za-z0-9+/=]{25,}' -)
|
|
if [ -n "$OUTPUT" ]; then
|
|
echo "Errors found in $file"
|
|
echo "$OUTPUT"
|
|
ERROR_FOUND=1
|
|
fi
|
|
done
|
|
|
|
for file in $(find $1 -name "*.md"); do
|
|
# Adding regexp to ignore base64 strings
|
|
OUTPUT=$(cat "$file" | codespell --ignore-regex='[A-Za-z0-9+/=]{25,}' -)
|
|
if [ -n "$OUTPUT" ]; then
|
|
echo "Errors found in $file"
|
|
echo "$OUTPUT"
|
|
ERROR_FOUND=1
|
|
fi
|
|
done
|
|
|
|
if [ "$ERROR_FOUND" -ne 0 ]; then
|
|
exit 1
|
|
fi
|