From d0abf577097d6ffdc5941d36817d38e6a6fb1e7a Mon Sep 17 00:00:00 2001
From: Johnson Chu
Date: Thu, 4 Apr 2024 16:28:39 +0800
Subject: [PATCH] chore: changelog
---
CHANGELOG.md | 22 ++++++++++++++
CHANGELOG_INSIDERS.md | 19 ------------
extensions/vscode/src/common.ts | 53 ++++-----------------------------
insiders.json | 8 -----
4 files changed, 28 insertions(+), 74 deletions(-)
delete mode 100644 CHANGELOG_INSIDERS.md
delete mode 100644 insiders.json
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 67b8d5d307..9374edfca4 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,27 @@
# Changelog
+## 2.1.0-insiders.1
+
+> [Join the Insiders Program](https://github.com/vuejs/language-tools/wiki/Get-Insiders-Edition) for more exclusive features and updates.
+
+Download Pages: [GitHub Releases](https://github.com/volarjs/insiders/releases/tag/v2.1.0-insiders.1), [爱发电电圈](https://afdian.net/p/ba0901a2edce11ee8f2e52540025c377)
+
+### New Features
+
+#### Reactions visualization (PR: https://github.com/volarjs/insiders/pull/5)
+
+
+
+#### Template interpolation decorators (PR: https://github.com/volarjs/insiders/pull/4)
+
+> To disable this feature, uncheck `vue.editor.templateInterpolationDecorators` in VSCode settings.
+
+
+
+### Other Changes
+
+- Merged https://github.com/vuejs/language-tools/commit/1b9946c02ee3f5bb8c2de17c430985756115e51c
+
## 2.0.7 (2024/3/20)
> [!NOTE]
diff --git a/CHANGELOG_INSIDERS.md b/CHANGELOG_INSIDERS.md
deleted file mode 100644
index 907ca335c7..0000000000
--- a/CHANGELOG_INSIDERS.md
+++ /dev/null
@@ -1,19 +0,0 @@
-# Changelog (Insiders)
-
-## [v2.1.0-insiders.1](https://github.com/volarjs/insiders/releases/tag/v2.1.0-insiders.1)
-
-### New Features
-
-#### Reactions visualization (PR: https://github.com/volarjs/insiders/pull/5)
-
-
-
-#### Template interpolation decorators (PR: https://github.com/volarjs/insiders/pull/4)
-
-> To disable this feature, uncheck `vue.editor.templateInterpolationDecorators` in VSCode settings.
-
-
-
-### Other Changes
-
-- Merged https://github.com/vuejs/language-tools/commit/1b9946c02ee3f5bb8c2de17c430985756115e51c into Insider.
diff --git a/extensions/vscode/src/common.ts b/extensions/vscode/src/common.ts
index a9283a9756..263b45b0c5 100644
--- a/extensions/vscode/src/common.ts
+++ b/extensions/vscode/src/common.ts
@@ -100,55 +100,14 @@ async function doActivate(context: vscode.ExtensionContext, createLc: CreateLang
};
}
else {
- const versionsUrl = 'https://cdn.jsdelivr.net/gh/vuejs/language-tools/insiders.json';
item.text = '🚀 Vue - Official Insiders';
item.detail = 'Installed';
- item.busy = true;
- const currentVersion = context.extension.packageJSON.version;
- fetch(versionsUrl)
- .then(res => res.json())
- .then(({ versions }: { versions: { version: string; date: string; }[]; }) => {
- item.command = {
- title: 'Select Version',
- command: 'vue-insiders.selectVersion',
- arguments: [{ versions }],
- };
- if (versions.length && versions[0].version !== currentVersion) {
- item.command.title = 'Update';
- item.detail = 'New version available';
- item.severity = vscode.LanguageStatusSeverity.Warning;
- }
- })
- .catch(() => {
- item.detail = 'Failed to fetch versions';
- })
- .finally(() => {
- item.busy = false;
- });
- vscode.commands.registerCommand('vue-insiders.selectVersion', async ({ versions }: { versions: { version: string; date: string; }[]; }) => {
- const items = versions.map(version => ({
- label: version.version,
- description: version.date + (version.version === currentVersion ? ' (current)' : ''),
- }));
- if (!items.some(item => item.description?.endsWith('(current)'))) {
- items.push({
- label: '',
- kind: vscode.QuickPickItemKind.Separator,
- }, {
- label: currentVersion,
- description: '(current)',
- });
- }
- const selected = await vscode.window.showQuickPick(
- items,
- {
- canPickMany: false,
- placeHolder: 'Select a version',
- });
- if (!selected || selected.label === currentVersion) {
- return;
- }
- const updateUrl = `https://github.com/volarjs/insiders/releases/tag/v${selected.label}`;
+ item.command = {
+ title: 'Changelog',
+ command: 'vue-insiders.checkUpdate',
+ };
+ vscode.commands.registerCommand('vue-insiders.checkUpdate', () => {
+ const updateUrl = 'https://github.com/vuejs/language-tools/blob/master/CHANGELOG.md';
vscode.env.openExternal(vscode.Uri.parse(updateUrl));
});
}
diff --git a/insiders.json b/insiders.json
deleted file mode 100644
index fbbbc90620..0000000000
--- a/insiders.json
+++ /dev/null
@@ -1,8 +0,0 @@
-{
- "versions": [
- {
- "version": "2.1.0-insiders.1",
- "date": "2024-03-29"
- }
- ]
-}
\ No newline at end of file