Skip to content

Commit 747af5d

Browse files
committed
feat: command to display current codemp version
1 parent 76d82fc commit 747af5d

3 files changed

Lines changed: 11 additions & 1 deletion

File tree

package.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,11 @@
194194
"title": "Follow User",
195195
"category": "codemp",
196196
"icon": "$(debug-console-evaluation-input)"
197+
},
198+
{
199+
"command": "codemp.version",
200+
"title": "Display codemp version",
201+
"category": "codemp"
197202
}
198203
],
199204
"configuration": {

src/commands/client.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -205,5 +205,9 @@ export async function refresh() {
205205
vscode.window.showInformationMessage("Refreshed Session token");
206206
}
207207

208+
export async function version(){
209+
vscode.window.showInformationMessage(`Version: ${codemp.version()}`);
210+
}
211+
208212

209213

src/extension.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import * as vscode from 'vscode';
22
import * as codemp from 'codemp';
3-
import { client, connect, join, refresh, createWorkspace, inviteToWorkspace, listWorkspaces, leave, deleteWorkspace } from './commands/client';
3+
import { client, connect, join, refresh, createWorkspace, inviteToWorkspace, listWorkspaces, leave, deleteWorkspace, version } from './commands/client';
44
import { CodempTreeProvider } from './tree';
55
import * as mapping from './mapping';
66
import { workspaceState, jump, listBuffers, createBuffer, deleteBuffer } from './commands/workspaces'
@@ -47,6 +47,7 @@ export function activate(context: vscode.ExtensionContext) {
4747
vscode.commands.registerCommand('codemp.sync', sync),
4848
vscode.commands.registerCommand('codemp.refresh', refresh),
4949
vscode.commands.registerCommand('codemp.jump', jump),
50+
vscode.commands.registerCommand('codemp.version', version),
5051
]) {
5152
context.subscriptions.push(cmd);
5253
}

0 commit comments

Comments
 (0)