ccc我有一个让我发疯的python脚本。这是有问题的代码...... if 语句中的代码没有运行,有人可以提出原因吗?:
print("refresh_type is: " + refresh_type)
if (refresh_type == "update"):
print("hello world")
cmd = 'sudo svn %s --username %s --password %s %s' % ('up', un, pw, working_path)
print("command is: " + str(cmd))
elif(refresh_type == 'checkout' or refresh_type == 'co'):
cmd = 'sudo svn %s --username %s --password %s %s %s' % (refreshType, un, pw, rc_service_url, working_path)
print('username = ' + credentials['un'])
print('password = ' + credentials['pw'])
print("working path = " + working_path)
以下是打印语句的输出:
refresh_type is: 'update'
username = 'cccc'
password = 'vvvvv'
working path = '/home/ubuntu/workingcopy/rc_service'