Skip to content
Snippets Groups Projects
Commit cd71443d authored by Rohit Gupta's avatar Rohit Gupta
Browse files

added keyword to handle numeric substitution

parent dc440717
No related branches found
No related tags found
No related merge requests found
......@@ -22,6 +22,9 @@ if keyword == 'mme_ip_address':
#string = (re.sub(r"mme_ip_address\s*=\s*\([^\$]+)\)\s*;\s*", r"<% tex \1 %>", t, re.M)
replacement_text = keyword + ' = ' + replacement_text + ' ; '
string = re.sub(r"mme_ip_address\s*=\s*\(([^\$]+?)\)\s*;", replacement_text, string, re.M)
elif keyword == 'N_RB_DL':
replacement_text = keyword + ' = ' + replacement_text + ' ; '
string = re.sub(r"%s\s*=\s*([^\$]+?)\s*;" % keyword , replacement_text, string, re.M)
else :
replacement_text = keyword + ' = \" ' + replacement_text + '\" ; '
string = re.sub(r"%s\s*=\s*\"([^\$]+?)\"\s*;" % keyword , replacement_text, string, re.M)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment