Commit 465e5837 by sikang

update script

parent f33ec28d
......@@ -20,9 +20,10 @@ def rename_api(path):
#替换api
with open(path, "w", encoding="utf-8") as f_w:
for api_l in api_lines:
if "//API-REPAIR*-*" in api_l:
api_l = "\t"+api_l.split("*-*")[1]
# if "//API-REPAIR*-*" in api_l:
# api_l = "\t"+api_l.split("*-*")[1]
if "loanapp/{loanAppId}/bank" in api_l:
api_l = api_l.replace("loanapp/{loanAppId}/bank","loanapp/bank/{loanAppId}")
if (api_map[1]+"/{" in api_l or api_map[1]+"\"" in api_l) and ( "@GET" in api_l or "@PUT" in api_l or "@POST" in api_l):
api_l = api_l.replace(api_map[1], api_map[0])
print(api_map[1]+ " -> " + api_map[0])
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment