]> Git Repo - pico-vscode.git/blob - src/commands/command.mts
Basic project generation setup
[pico-vscode.git] / src / commands / command.mts
1 import { commands, type Disposable } from "vscode";
2
3 const extensionId = "raspberry-pi-pico";
4
5 export default abstract class Command {
6   private readonly commandId: string;
7
8   protected constructor(commandId: string) {
9     this.commandId = commandId;
10   }
11
12   register(): Disposable {
13     return commands.registerCommand(
14       extensionId + "." + this.commandId,
15       this.execute.bind(this)
16     );
17   }
18
19   abstract execute(): Promise<void>;
20 }
This page took 0.029531 seconds and 4 git commands to generate.