begin rework for js tests and hook examples

This commit is contained in:
Richard Holland
2022-06-06 14:05:17 +00:00
parent d452f9ca5a
commit 5f74392bcb
68 changed files with 4197 additions and 0 deletions

View File

@@ -0,0 +1,8 @@
#!/bin/bash
RIPPLED_ROOT="`git rev-parse --show-toplevel`/src/ripple"
echo '// For documentation please see: https://xrpl-hooks.readme.io/reference/'
echo '// Generated using generate_error.sh'
echo '#ifndef HOOK_ERROR_CODES'
cat $RIPPLED_ROOT/app/hook/Enum.h | tr -d '\n' | grep -Eo 'hook_return_code : int64_t *{[^}]+}' | grep -Eo '[A-Z_]+ *= *[0-9-]+' | sed -E 's/ *= */ /g' | sed -E 's/^/#define /g'
echo '#define HOOK_ERROR_CODES'
echo '#endif //HOOK_ERROR_CODES'