mirror of
https://github.com/pcottle/learnGitBranching.git
synced 2025-06-27 00:18:56 +02:00
set vcs separately
This commit is contained in:
parent
3c1887f1d0
commit
b71e794e8e
2 changed files with 14 additions and 5 deletions
|
@ -10422,14 +10422,16 @@ var instantCommands = [
|
||||||
];
|
];
|
||||||
|
|
||||||
var parse = function(str) {
|
var parse = function(str) {
|
||||||
|
var vcs;
|
||||||
var method;
|
var method;
|
||||||
var options;
|
var options;
|
||||||
|
|
||||||
// see if we support this particular command
|
// see if we support this particular command
|
||||||
_.each(commands.getRegexMap(), function(regex, thisMethod) {
|
_.each(commands.getRegexMap(), function(regex, thisMethod) {
|
||||||
if (regex.exec(str)) {
|
if (regex.exec(str)) {
|
||||||
options = str.slice(thisMethod.length + 1);
|
vcs = 'git'; // XXX get from regex map
|
||||||
method = thisMethod.slice('git '.length);
|
options = str.slice(vcs.length + 1 + thisMethod.length + 1);
|
||||||
|
method = thisMethod.slice(vcs.length + 1);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -10444,6 +10446,7 @@ var parse = function(str) {
|
||||||
toSet: {
|
toSet: {
|
||||||
generalArgs: parsedOptions.generalArgs,
|
generalArgs: parsedOptions.generalArgs,
|
||||||
supportedMap: parsedOptions.supportedMap,
|
supportedMap: parsedOptions.supportedMap,
|
||||||
|
vcs: vcs,
|
||||||
method: method,
|
method: method,
|
||||||
options: options,
|
options: options,
|
||||||
eventName: 'processGitCommand'
|
eventName: 'processGitCommand'
|
||||||
|
@ -24318,14 +24321,16 @@ var instantCommands = [
|
||||||
];
|
];
|
||||||
|
|
||||||
var parse = function(str) {
|
var parse = function(str) {
|
||||||
|
var vcs;
|
||||||
var method;
|
var method;
|
||||||
var options;
|
var options;
|
||||||
|
|
||||||
// see if we support this particular command
|
// see if we support this particular command
|
||||||
_.each(commands.getRegexMap(), function(regex, thisMethod) {
|
_.each(commands.getRegexMap(), function(regex, thisMethod) {
|
||||||
if (regex.exec(str)) {
|
if (regex.exec(str)) {
|
||||||
options = str.slice(thisMethod.length + 1);
|
vcs = 'git'; // XXX get from regex map
|
||||||
method = thisMethod.slice('git '.length);
|
options = str.slice(vcs.length + 1 + thisMethod.length + 1);
|
||||||
|
method = thisMethod.slice(vcs.length + 1);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -24340,6 +24345,7 @@ var parse = function(str) {
|
||||||
toSet: {
|
toSet: {
|
||||||
generalArgs: parsedOptions.generalArgs,
|
generalArgs: parsedOptions.generalArgs,
|
||||||
supportedMap: parsedOptions.supportedMap,
|
supportedMap: parsedOptions.supportedMap,
|
||||||
|
vcs: vcs,
|
||||||
method: method,
|
method: method,
|
||||||
options: options,
|
options: options,
|
||||||
eventName: 'processGitCommand'
|
eventName: 'processGitCommand'
|
||||||
|
|
|
@ -555,14 +555,16 @@ var instantCommands = [
|
||||||
];
|
];
|
||||||
|
|
||||||
var parse = function(str) {
|
var parse = function(str) {
|
||||||
|
var vcs;
|
||||||
var method;
|
var method;
|
||||||
var options;
|
var options;
|
||||||
|
|
||||||
// see if we support this particular command
|
// see if we support this particular command
|
||||||
_.each(commands.getRegexMap(), function(regex, thisMethod) {
|
_.each(commands.getRegexMap(), function(regex, thisMethod) {
|
||||||
if (regex.exec(str)) {
|
if (regex.exec(str)) {
|
||||||
|
vcs = 'git'; // XXX get from regex map
|
||||||
options = str.slice(thisMethod.length + 1);
|
options = str.slice(thisMethod.length + 1);
|
||||||
method = thisMethod.slice('git '.length);
|
method = thisMethod.slice(vcs.length + 1);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -577,6 +579,7 @@ var parse = function(str) {
|
||||||
toSet: {
|
toSet: {
|
||||||
generalArgs: parsedOptions.generalArgs,
|
generalArgs: parsedOptions.generalArgs,
|
||||||
supportedMap: parsedOptions.supportedMap,
|
supportedMap: parsedOptions.supportedMap,
|
||||||
|
vcs: vcs,
|
||||||
method: method,
|
method: method,
|
||||||
options: options,
|
options: options,
|
||||||
eventName: 'processGitCommand'
|
eventName: 'processGitCommand'
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue