Commit 7a68b9ac authored by nanahira's avatar nanahira

fix

parent f102e8f8
...@@ -159,15 +159,17 @@ var UpdateFilelist = function(msg) { ...@@ -159,15 +159,17 @@ var UpdateFilelist = function(msg) {
} }
runcmd("git", ["pull", "origin", branch], config.client_git_db_path, "Finished updating File List", function(code) { runcmd("git", ["pull", "origin", branch], config.client_git_db_path, "Finished updating File List", function(code) {
var success_function = function() { var success_function = function() {
sendResponse("Finished generating File List"); sendResponse("Finished generating File List");
try { if (config.client_push_repo) {
execSync('git add . -A', { cwd: config.client_git_db_path, env: process.env }); try {
execSync('git commit -m Filelist', { cwd: config.client_git_db_path, env: process.env }); execSync('git add . -A', { cwd: config.client_git_db_path, env: process.env });
execSync('git push '+config.client_push_repo+' '+branch, { cwd: config.client_git_db_path, env: process.env }); execSync('git commit -m Filelist', { cwd: config.client_git_db_path, env: process.env });
} catch (error) { execSync('git push '+config.client_push_repo+' '+branch, { cwd: config.client_git_db_path, env: process.env });
sendResponse("git error: "+error.stdout); } catch (error) {
sendResponse("Failed pushing File List"); sendResponse("git error: "+error.stdout);
return; sendResponse("Failed pushing File List");
return;
}
} }
}; };
sendResponse("Finished updating client data"); sendResponse("Finished updating client data");
......
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