|
@@ -1,5 +1,4 @@
|
|
|
import os
|
|
|
-import flask
|
|
|
import requests
|
|
|
import json
|
|
|
import time
|
|
@@ -221,17 +220,37 @@ def get_branch():
|
|
|
"cd "+current_path+ ";"
|
|
|
"git clone https://git.yishihui.com/weapp/longVideoFactory.git;"
|
|
|
"cd longVideoFactory;"
|
|
|
- "git branch -a;"
|
|
|
+ "git pull;"
|
|
|
+ )
|
|
|
+ os.system(command_str)
|
|
|
+
|
|
|
+ command_str= (
|
|
|
+ "cd "+current_path+ ";"
|
|
|
+ "cd longVideoFactory;"
|
|
|
+ "git branch -r;"
|
|
|
)
|
|
|
f_read = os.popen(command_str).read()
|
|
|
|
|
|
branch_list = []
|
|
|
for item in f_read.split():
|
|
|
- if "->" not in item and "origin/master" not in item and "HEAD" not in item and "*" not in item:
|
|
|
- branch_list.append(item.replace("remotes/origin/",""))
|
|
|
+ if "->" not in item and "HEAD" not in item and "*" not in item:
|
|
|
+ branch_list.append(item.replace("origin/",""))
|
|
|
|
|
|
res = {"code":0,"data":branch_list}
|
|
|
return res
|
|
|
|
|
|
if __name__ == '__main__':
|
|
|
- app.run(host='0.0.0.0', port=7777, debug=False)
|
|
|
+ app.run(host='0.0.0.0', port=7777, debug=False)
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|