Skip to content

Commit

Permalink
fix: openDeploymentsLink should open /deployments
Browse files Browse the repository at this point in the history
It previously only opened the project homepage
  • Loading branch information
aarondill committed Mar 14, 2024
1 parent 5d7ade4 commit eaa1829
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
7 changes: 6 additions & 1 deletion src/commands/Deployments/openDeploymentsLink.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,12 @@ export class OpenDeploymentsLink implements Command {
if (!user)
return void vscode.window.showErrorMessage("Could not get user info!");
const base = vscode.Uri.parse("https://vercel.com");
const url = vscode.Uri.joinPath(base, user.username, projectInfo.name);
const url = vscode.Uri.joinPath(
base,
user.username,
projectInfo.name,
"/deployments"
);
await vscode.env.openExternal(url);
}
}
10 changes: 8 additions & 2 deletions src/commands/Environment/openEnvironmentLink.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,13 @@ export class OpenEnvironmentLink implements Command {
const user = await this.vercel.user.getInfo();
if (!user)
return void vscode.window.showErrorMessage("Could not get user info!");
const url = `https://vercel.com/${user.username}/${projectInfo.name}/settings/environment-variables`;
await vscode.commands.executeCommand("vscode.open", vscode.Uri.parse(url));
const base = vscode.Uri.parse("https://vercel.com");
const url = vscode.Uri.joinPath(
base,
user.username,
projectInfo.name,
"/settings/environment-variables"
);
await vscode.commands.executeCommand("vscode.open", url);
}
}

0 comments on commit eaa1829

Please sign in to comment.