+get_active_branch_name(py_file_path.split('openairinterface5g')[0][:-1])[:10]# consider first 10 chars
timeout=None
timeoutLimit=5
inp=stdinWait(f"\nEnter Y/y within {timeoutLimit} seconds to create your own COMPOSE_PROJECT_NAME:{cpn} (present) and press <Enter>...: ",cpn,timeoutLimit,f"\nOkay, nothing entered.")
ifnottimeout:
print(f"You entered {inp}")
if(inp=='Y'orinp=='y'):
cpn_inp=input(f"\nEnter your COMPOSE_PROJECT_NAME and press Enter: ")
ifcpn_inp.strip()!='':
cpn=cpn_inp.strip()
else:
print("COMPOSE_PROJECT_NAME can not be blank.")
print(f"\nWill be using COMPOSE_PROJECT_NAME={cpn}")
else:
print(f"\nWill be using COMPOSE_PROJECT_NAME={cpn}")
conf=conf.replace("{{PROJECT_NAME}}",cpn)
withopen(final_conf_path,"w")asconf_file:
conf_file.write(conf)
else:
print("USER is not available in environment variable")