use_other_language_in_shell
directly use other language code in shell script
code link: https://github.com/Shuiliusheng/use_other_language_in_shell
./xxx srcFilename dstFilename
************ python transform ******************
-
python code block start with #python-code-start
-
python code block end with #python-code-end
-
input parameters to python codes should be defined as:
input python_var_name=shell_varname -
output parameters to shell script should be defined as:
output shell_varname=python_var_name -
python codes support use “import” to define the package for using
-
python codes support define function in block
-
python codes support call the defined python code by using the fuc define place number
function number start with 1 to … -
if the input is string, it will replace all blanks to string “###” as inputs
************ C++ transform ******************
- C++ code block start with #C+±code-start
- C++ code block end with #C+±code-end
- input parameters to C++ codes should be defined as:
input type cpp_var_name=shell_varname - output parameters to shell script should be defined as:
output shell_varname=cpp_var_name - C++ codes support use “#include<>” to define the package for using
- C++ codes support define function in block.
function start with: #subfuc; end with: #endfuc - C++ codes support call the defined C++ code by using the fuc define place number
function number start with 1 to … - if the input is string, it will replace all blanks to string “###” as inputs