mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-05-13 05:12:55 -07:00
fix(skills): remove "Restart required" message from non-interactive commands (#16307)
This commit is contained in:
@@ -80,7 +80,7 @@ describe('skills disable command', () => {
|
|||||||
);
|
);
|
||||||
expect(emitConsoleLog).toHaveBeenCalledWith(
|
expect(emitConsoleLog).toHaveBeenCalledWith(
|
||||||
'log',
|
'log',
|
||||||
'Skill "skill1" disabled by adding it to the disabled list in user (/user/settings.json) settings. Restart required to take effect.',
|
'Skill "skill1" disabled by adding it to the disabled list in user (/user/settings.json) settings.',
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -23,13 +23,10 @@ export async function handleDisable(args: DisableArgs) {
|
|||||||
const settings = loadSettings(workspaceDir);
|
const settings = loadSettings(workspaceDir);
|
||||||
|
|
||||||
const result = disableSkill(settings, name, scope);
|
const result = disableSkill(settings, name, scope);
|
||||||
let feedback = renderSkillActionFeedback(
|
const feedback = renderSkillActionFeedback(
|
||||||
result,
|
result,
|
||||||
(label, path) => `${chalk.bold(label)} (${chalk.dim(path)})`,
|
(label, path) => `${chalk.bold(label)} (${chalk.dim(path)})`,
|
||||||
);
|
);
|
||||||
if (result.status === 'success') {
|
|
||||||
feedback += ' Restart required to take effect.';
|
|
||||||
}
|
|
||||||
debugLogger.log(feedback);
|
debugLogger.log(feedback);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -81,7 +81,7 @@ describe('skills enable command', () => {
|
|||||||
);
|
);
|
||||||
expect(emitConsoleLog).toHaveBeenCalledWith(
|
expect(emitConsoleLog).toHaveBeenCalledWith(
|
||||||
'log',
|
'log',
|
||||||
'Skill "skill1" enabled by removing it from the disabled list in user (/user/settings.json) and project (/project/settings.json) settings. Restart required to take effect.',
|
'Skill "skill1" enabled by removing it from the disabled list in user (/user/settings.json) and project (/project/settings.json) settings.',
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -122,7 +122,7 @@ describe('skills enable command', () => {
|
|||||||
);
|
);
|
||||||
expect(emitConsoleLog).toHaveBeenCalledWith(
|
expect(emitConsoleLog).toHaveBeenCalledWith(
|
||||||
'log',
|
'log',
|
||||||
'Skill "skill1" enabled by removing it from the disabled list in project (/workspace/settings.json) and user (/user/settings.json) settings. Restart required to take effect.',
|
'Skill "skill1" enabled by removing it from the disabled list in project (/workspace/settings.json) and user (/user/settings.json) settings.',
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -22,13 +22,10 @@ export async function handleEnable(args: EnableArgs) {
|
|||||||
const settings = loadSettings(workspaceDir);
|
const settings = loadSettings(workspaceDir);
|
||||||
|
|
||||||
const result = enableSkill(settings, name);
|
const result = enableSkill(settings, name);
|
||||||
let feedback = renderSkillActionFeedback(
|
const feedback = renderSkillActionFeedback(
|
||||||
result,
|
result,
|
||||||
(label, path) => `${chalk.bold(label)} (${chalk.dim(path)})`,
|
(label, path) => `${chalk.bold(label)} (${chalk.dim(path)})`,
|
||||||
);
|
);
|
||||||
if (result.status === 'success') {
|
|
||||||
feedback += ' Restart required to take effect.';
|
|
||||||
}
|
|
||||||
debugLogger.log(feedback);
|
debugLogger.log(feedback);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user