Skip to content

Commit 12410ba

Browse files
committed
Only show send signal command when no Windows
1 parent b9db1ff commit 12410ba

File tree

1 file changed

+8
-9
lines changed

1 file changed

+8
-9
lines changed

src/vs/workbench/contrib/terminal/browser/terminalActions.ts

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -144,10 +144,10 @@ export const terminalSendSignalCommand = async (accessor: ServicesAccessor, args
144144
}
145145

146146
let signal = isObject(args) && 'signal' in args ? toOptionalString(args.signal) : undefined;
147-
147+
148148
if (!signal) {
149149
const quickInputService = accessor.get(IQuickInputService);
150-
150+
151151
const signalOptions: QuickPickItem[] = [
152152
{ label: 'SIGINT', description: 'Interrupt process (Ctrl+C)' },
153153
{ label: 'SIGTERM', description: 'Terminate process gracefully' },
@@ -165,27 +165,26 @@ export const terminalSendSignalCommand = async (accessor: ServicesAccessor, args
165165
const selected = await quickInputService.pick(signalOptions, {
166166
placeHolder: localize('selectSignal', 'Select signal to send to terminal process')
167167
});
168-
168+
169169
if (!selected) {
170170
return;
171171
}
172-
172+
173173
if (selected.label === localize('manualSignal', 'Manually enter signal')) {
174174
const inputSignal = await quickInputService.input({
175175
prompt: localize('enterSignal', 'Enter signal name (e.g., SIGTERM, SIGKILL)'),
176-
placeHolder: 'SIGTERM'
177176
});
178-
177+
179178
if (!inputSignal) {
180179
return;
181180
}
182-
181+
183182
signal = inputSignal;
184183
} else {
185184
signal = selected.label;
186185
}
187186
}
188-
187+
189188
instance.sendSignal(signal);
190189
};
191190

@@ -1032,7 +1031,7 @@ export function registerTerminalActions() {
10321031
registerTerminalAction({
10331032
id: TerminalCommandId.SendSignal,
10341033
title: terminalStrings.sendSignal,
1035-
f1: true,
1034+
f1: !isWindows,
10361035
metadata: {
10371036
description: terminalStrings.sendSignal.value,
10381037
args: [{

0 commit comments

Comments
 (0)