mirror of
https://github.com/node-red/node-red.git
synced 2025-03-01 10:36:34 +00:00
Add unified diff view to version control tab
This commit is contained in:
@@ -209,5 +209,15 @@ module.exports = {
|
||||
commit: function(cwd, message) {
|
||||
var args = ["commit","-m",message];
|
||||
return runCommand(gitCommand,args,cwd);
|
||||
},
|
||||
getFileDiff(cwd,file,type) {
|
||||
var args = ["diff"];
|
||||
if (type === "tree") {
|
||||
// nothing else to do
|
||||
} else if (type === "index") {
|
||||
args.push("--cached");
|
||||
}
|
||||
args.push(file);
|
||||
return runCommand(gitCommand,args,cwd);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user