-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Internal doc #17
Internal doc #17
Conversation
HACKING.md
Outdated
|
||
## helpers.sh | ||
|
||
most function in helper.sh have been documented, so go read it if you want to understand some of the most used functions of cognac_gen |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Most functions in helper.sh are documented, so read through it if you want to understand some of the most commonly used functions in cognac_gen.
helper.sh
Outdated
@@ -1,5 +1,7 @@ | |||
source ./config.sh | |||
|
|||
# get type from the json of the componant of an argument |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Retrieve the type from the JSON of a component for a given argument.
helper.sh
Outdated
@@ -81,6 +83,8 @@ get_type_direct() { | |||
fi | |||
} | |||
|
|||
# like get_type, but use full componant json, instead of API function Name |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Retrieve the type directly from the full component JSON rather than using the API function Name in get_type.
helper.sh
Outdated
@@ -89,6 +93,8 @@ get_type3() { | |||
return 0 | |||
} | |||
|
|||
# like get_type, but use full componant name, instead of API function Name |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Retrieve the type directly from the full component JSON rather than using the API function name in get_type.
helper.sh
Outdated
@@ -132,6 +140,10 @@ get_sub_type_description() { | |||
done | |||
} | |||
|
|||
# Write the description of a componant. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Write the description of a component.
helper.sh
Outdated
@@ -132,6 +140,10 @@ get_sub_type_description() { | |||
done | |||
} | |||
|
|||
# Write the description of a componant. | |||
# useful to genrate SDK Documentation |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
useful for generating SDK documentation.
helper.sh
Outdated
@@ -147,6 +159,10 @@ get_type_description() { | |||
fi | |||
} | |||
|
|||
|
|||
# Take 2 argument, a API function name, and an argument from it |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Takes two arguments: an API function name and one of its arguments.
bin/README.md
Outdated
|
||
Look in a OpenApi json file, the list of Functions. | ||
To do so, look at which object in components.schemas end up with Request. | ||
Then each functions call are separate by a space |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Look in an OpenAPI JSON file for the list of functions. To do this, identify which objects in components.schemas end with 'Request'. Each function call is separated by a space.
bin/README.md
Outdated
Will return "this_arg". | ||
|
||
This utilise was made so we don't have to call grep for each keywork we need to look at. | ||
With this utility we can just give all our keyword to line_check, and then switch on which keywork was found. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This utility was created to avoid calling grep for each keyword we need to check. With this utility, we can pass all our keywords to line_check and then switch based on which keyword was found.
bin/README.md
Outdated
This utilise was made so we don't have to call grep for each keywork we need to look at. | ||
With this utility we can just give all our keyword to line_check, and then switch on which keywork was found. | ||
|
||
This is also a lot faster that multiples calls to grep |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is also much faster than multiple calls to grep.
bin/README.md
Outdated
# osc-api-seems-valid.sh | ||
|
||
This utilise is use to check is osc-api.json have been correctly generate. | ||
It look if the file is indeed a json, and if it contain at last one API function. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This utility is used to check if osc-api.json has been generated correctly. It verifies that the file is a valid JSON and contains at least one API function.
Signed-off-by: Matthias Gatto <[email protected]>
Signed-off-by: Matthias Gatto <[email protected]>
80d086a
to
707c7a4
Compare
No description provided.