Skip to content

Commit a237cb4

Browse files
committed
prepare v2.0.0 prerelease
- Update version to 2.0.0 in package.json - Rename enableAglintCache setting to enableInMemoryAglintCache and mark as experimental - Change enableInMemoryAglintCache default value from true to false - Update CHANGELOG.md with release date and additional details about removed settings - Update README.md to reflect new setting name and experimental status - Update all references to enableAglintCache throughout codebase
1 parent 7a4ebb6 commit a237cb4

5 files changed

Lines changed: 17 additions & 13 deletions

File tree

CHANGELOG.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,15 @@ The format is based on [Keep a Changelog], and this project adheres to [Semantic
77
[Keep a Changelog]: https://keepachangelog.com/en/1.0.0/
88
[Semantic Versioning]: https://semver.org/spec/v2.0.0.html
99

10-
## Unreleased
10+
## [2.0.0] (prerelease) - 2025-11-28
1111

1212
### Added
1313

1414
- Support for multi-root workspaces [#112].
1515
- `Remove this rule` quick fix option [#126].
1616
- Support for applying various fixes offered by AGLint [#127].
1717
- Support for detecting package manager automatically [#117].
18+
- `enableAglintDebug` and `enableInMemoryAglintCache` (experimental, disabled by default) settings.
1819

1920
### Changed
2021

@@ -25,7 +26,10 @@ The format is based on [Keep a Changelog], and this project adheres to [Semantic
2526

2627
- Integrated version of AGLint. From now on, AGLint only works if it is installed separately.
2728
This provides more consistent behavior.
29+
This removed `useExternalAglintPackages` setting.
30+
- `packageManager` setting. It is now detected automatically.
2831

32+
[2.0.0]: https://github.com/AdguardTeam/VscodeAdblockSyntax/compare/1.1.17...2.0.0
2933
[#112]: https://github.com/AdguardTeam/VscodeAdblockSyntax/issues/112
3034
[#117]: https://github.com/AdguardTeam/VscodeAdblockSyntax/issues/117
3135
[#126]: https://github.com/AdguardTeam/VscodeAdblockSyntax/issues/126

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ This extension provides the following configuration options:
104104
| ------ | ----------- | ------------- | --------------- |
105105
| `adblock.enableAglint` | Enable or disable AGLint integration. If disabled, only syntax highlighting and other language features will be available. | `true` | `true`, `false` |
106106
| `adblock.enableAglintDebug` | Enable or disable AGLint debug logging. | `false` | `true`, `false` |
107-
| `adblock.enableAglintCache` | Enable or disable caching of linting results for better performance. | `true` | `true`, `false` |
107+
| `adblock.enableInMemoryAglintCache` | ⚠️ **Experimental**: Enable or disable in-memory caching of linting results for better performance. | `false` | `true`, `false` |
108108
<!--markdownlint-enable MD013-->
109109

110110
### GitHub Linguist support

package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "adblock",
33
"displayName": "Adblock/AdGuard/uBlock filters grammar",
44
"description": "VS code extension that adds support for ad blocking rules syntax.",
5-
"version": "1.1.17",
5+
"version": "2.0.0",
66
"publisher": "adguard",
77
"icon": "icons/aglint_128x128.png",
88
"main": "./client/out/extension",
@@ -72,11 +72,11 @@
7272
"default": false,
7373
"description": "Enable or disable AGLint debug logging."
7474
},
75-
"adblock.enableAglintCache": {
75+
"adblock.enableInMemoryAglintCache": {
7676
"scope": "resource",
7777
"type": "boolean",
78-
"default": true,
79-
"description": "Enable or disable caching of linting results for better performance."
78+
"default": false,
79+
"markdownDescription": "⚠️ **Experimental**: Enable or disable in-memory caching of linting results for better performance."
8080
}
8181
}
8282
}

server/src/server.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -338,7 +338,7 @@ async function lintFile(textDocument: TextDocument): Promise<void> {
338338
);
339339

340340
// Check cache first if caching is enabled
341-
if (settings.enableAglintCache) {
341+
if (settings.enableInMemoryAglintCache) {
342342
const cachedDiagnostics = lintCache.get(cacheKey);
343343
if (cachedDiagnostics) {
344344
const duration = Date.now() - startTime;
@@ -372,7 +372,7 @@ async function lintFile(textDocument: TextDocument): Promise<void> {
372372
const diagnostics = getVscodeDiagnosticsFromLinterResult(linterResult);
373373

374374
// Store result in cache if caching is enabled
375-
if (settings.enableAglintCache) {
375+
if (settings.enableInMemoryAglintCache) {
376376
lintCache.set(cacheKey, diagnostics);
377377
}
378378

@@ -766,7 +766,7 @@ async function refreshLinter() {
766766
async function pullSettings() {
767767
const previousEnableAglint = settings.enableAglint;
768768
const previousEnableDebug = settings.enableAglintDebug;
769-
const previousEnableCache = settings.enableAglintCache;
769+
const previousEnableCache = settings.enableInMemoryAglintCache;
770770

771771
if (hasConfigurationCapability) {
772772
const scopeUri = workspaceRoot ? pathToFileURL(workspaceRoot).toString() : undefined;
@@ -785,13 +785,13 @@ async function pullSettings() {
785785
aglintContext
786786
&& previousEnableAglint === settings.enableAglint
787787
&& previousEnableDebug === settings.enableAglintDebug
788-
&& previousEnableCache === settings.enableAglintCache
788+
&& previousEnableCache === settings.enableInMemoryAglintCache
789789
) {
790790
return;
791791
}
792792

793793
// Clear cache if caching was disabled
794-
if (previousEnableCache && !settings.enableAglintCache) {
794+
if (previousEnableCache && !settings.enableInMemoryAglintCache) {
795795
lintCache.clear();
796796
connection.console.info('AGLint cache cleared (caching disabled)');
797797
}

server/src/settings.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ export interface ExtensionSettings {
1818

1919
enableAglintDebug: boolean;
2020

21-
enableAglintCache: boolean;
21+
enableInMemoryAglintCache: boolean;
2222
}
2323

2424
/**
@@ -27,5 +27,5 @@ export interface ExtensionSettings {
2727
export const defaultSettings: ExtensionSettings = {
2828
enableAglint: true,
2929
enableAglintDebug: false,
30-
enableAglintCache: true,
30+
enableInMemoryAglintCache: false,
3131
};

0 commit comments

Comments
 (0)