Skip to content

Commit fbded3e

Browse files
committed
chore(release): 0.1.6 remove diff preview cmd, lint cleanup, command sanity test
1 parent 520d933 commit fbded3e

File tree

4 files changed

+60
-3
lines changed

4 files changed

+60
-3
lines changed

.eslintrc.js

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,25 @@ module.exports = {
99
'@typescript-eslint',
1010
],
1111
rules: {
12-
'@typescript-eslint/naming-convention': 'warn',
12+
'@typescript-eslint/naming-convention': [
13+
'warn',
14+
{
15+
selector: 'variable',
16+
format: ['camelCase', 'UPPER_CASE', 'PascalCase'],
17+
leadingUnderscore: 'allow'
18+
},
19+
{
20+
selector: 'variableLike',
21+
format: ['camelCase', 'UPPER_CASE', 'PascalCase']
22+
},
23+
{
24+
selector: 'typeLike',
25+
format: ['PascalCase']
26+
}
27+
],
1328
'@typescript-eslint/semi': 'warn',
14-
'curly': 'warn',
29+
// Disable mandatory curly braces for single-line statements to reduce noise
30+
'curly': 'off',
1531
'eqeqeq': 'warn',
1632
'no-throw-literal': 'warn',
1733
'semi': 'off',

CHANGELOG.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,19 @@ All notable changes to this project will be documented in this file.
44

55
The format is based on Keep a Changelog (https://keepachangelog.com/en/1.0.0/) and this project adheres to Semantic Versioning (https://semver.org/spec/v2.0.0.html).
66

7+
## [0.1.6] - 2025-10-05
8+
### Removed
9+
- Preview Auto-fix Diff command (deprecated; fully removed from activation, registration, and docs).
10+
11+
### Changed
12+
- Lint configuration: disabled `curly` rule to reduce noise from style-only warnings.
13+
14+
### Added
15+
- Sanity test ensuring only expected contributed commands are present (guards against accidental reintroduction of removed commands).
16+
17+
### Internal
18+
- Version bump for housekeeping release after feature removal.
19+
720
## [0.1.5] - 2025-10-05
821
### Added
922
- Hash heading normalization tests covering missing-space variants, trailing stray hashes, and deep level headings.
@@ -57,6 +70,7 @@ The format is based on Keep a Changelog (https://keepachangelog.com/en/1.0.0/) a
5770
- Context menu integration across explorer, editor tab, and editor content
5871
- Custom parser for WordPress readme formatting (FAQ, changelog headers, etc.)
5972

73+
[0.1.6]: https://github.com/soderlind/wordpress-readme-preview/compare/v0.1.5...v0.1.6
6074
[0.1.4]: https://github.com/soderlind/wordpress-readme-preview/compare/v0.1.3...v0.1.4
6175
[0.1.5]: https://github.com/soderlind/wordpress-readme-preview/compare/v0.1.4...v0.1.5
6276
[0.1.3]: https://github.com/soderlind/wordpress-readme-preview/compare/v0.1.1...v0.1.3

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "wordpress-readme-preview",
33
"displayName": "WordPress Readme",
44
"description": "Preview, validate, and edit WordPress readme.txt files with syntax highlighting, IntelliSense, and accurate rendering",
5-
"version": "0.1.5",
5+
"version": "0.1.6",
66
"publisher": "persoderlind",
77
"engines": {
88
"vscode": "^1.74.0"

src/test/commands.test.ts

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
import { describe, it, expect } from 'vitest';
2+
import * as fs from 'fs';
3+
import * as path from 'path';
4+
5+
/**
6+
* Sanity test: ensure contributed commands list matches expected set and removed diff command is absent.
7+
*/
8+
describe('contributed commands', () => {
9+
const pkgPath = path.join(__dirname, '../../package.json');
10+
const pkg = JSON.parse(fs.readFileSync(pkgPath, 'utf8'));
11+
12+
it('includes only expected command IDs', () => {
13+
const contributed = (pkg.contributes?.commands || []).map((c: any) => c.command).sort();
14+
const expected = [
15+
'wordpress-readme.showPreview',
16+
'wordpress-readme.showPreviewToSide',
17+
'wordpress-readme.validateReadme',
18+
'wordpress-readme.autoFixMarkdown'
19+
].sort();
20+
expect(contributed).toEqual(expected);
21+
});
22+
23+
it('does not include deprecated diff preview command', () => {
24+
const contributed = (pkg.contributes?.commands || []).map((c: any) => c.command);
25+
expect(contributed).not.toContain('wordpress-readme.previewAutoFixDiff');
26+
});
27+
});

0 commit comments

Comments
 (0)