Releases: selfint/code-blocks
v0.6.2
What's Changed
- fixed build-wasm to build--wasm by @Almoglevy2k in #182
- fix tree-sitter build --wasm command by @selfint in #184
New Contributors
- @Almoglevy2k made their first contribution in #182
Full Changelog: v0.6.1...v0.6.2
v0.7.0
v0.6.1
Added
codeBlocks.treeSitterCliPath
configuration: Set path totree-sitter
command.
Full Changelog: v0.6.0...v0.6.1
v0.6.0
Added
-
Block mode now supports all
tree-sitter
supported languages by default: Queries
are only required for the Code Blocks Editor. -
node
+npm
dependency: Extension new requiresnode
v16+, andnpm
. -
tree-sitter-cli
dependency: Extension now requirestree-sitter-cli
, and so
transitively requires eitheremscripten
(preferred) ordocker
. -
Tree viewer: View the syntax tree of the current file.
-
Block mode highlights can be toggled.
Fixed
-
Rapidly toggling block mode breaks extension.
-
Rapidly moving blocks is slow.
Changed
-
Block mode blocks: Instead of only using blocks, block mode now has
access to all nodes in the syntax tree. Blocks are now only used to automatically
expand a selection.Fine grained selection of nodes
Selection expansion to nearest block
-
Simplify language config:
- Parsers are now installed from NPM, instead of from GitHub.
- By default, the extension will try to use the
tree-sitter-<language>
NPM package, so
many languages will not need to be configured at all. - Queries are an optional config, required only for the Code Blocks Editor (not for
Block Mode) to work. - Configuration is by
[languageId]
instead of a massivelanguageSupport
config.
-
Change Block Mode colors config:
codeBlocks.colors.enabled
: Whether Block Mode should color selections or not. Defaults tofalse
.codeBlocks.colors.sibling
: CSS string for sibling selection background color. Defaults tovar(--vscode-editor-selectionHighlightBackground)
.codeBlocks.colors.parent
: CSS string for parent selection background color. Defaults tovar(--vscode-editor-linkedEditingBackground)
.
Old config for Python and TSX
"codeBlocks.languageSupport": { "python": { "parserInstaller": { "downloadCmd": "git clone https://github.com/tree-sitter/tree-sitter-python", "libraryName": "tree_sitter_python", "languageFnSymbol": "language" }, "queries": [ "(class_definition) @item", "(function_definition) @item", "(decorated_definition) @item" ] }, "typescriptreact": { "parserInstaller": { "downloadCmd": "git clone https://github.com/tree-sitter/tree-sitter-typescript", "symbol": "language_tsx", "name": "tree_sitter_typescript" }, "queries": [ "( (comment)* @header . (class_declaration) @item)", "( (comment)* @header . (method_definition) @item)", "( (comment)* @header . (function_declaration) @item)", "( (comment)* @header . (export_statement) @item)", "(jsx_element) @item", "(jsx_self_closing_element) @item" ] } }
New config for Python and TSX
"[python]": { // single-node blocks are only for the Code Blocks Editor "codeBlocks.queries": [ "(class_definition) @item", "(function_definition) @item", "(decorated_definition) @item" ] }, // parser is configured inside each languageId's config "[typescriptreact]": { "codeBlocks.npmPackageName": "tree-sitter-typescript", "codeBlocks.parserName": "tree-sitter-tsx", "codeBlocks.subdirectory": "tsx", // queries are now optional "codeBlocks.queries": [ "( (comment)* @header . (class_declaration) @item)", "( (comment)* @header . (method_definition) @item)", "( (comment)* @header . (function_declaration) @item)", "( (comment)* @header . (export_statement) @item)", // single-node blocks are only for the Code Blocks Editor "(jsx_element) @item", "(jsx_self_closing_element) @item" ] }
Removed
-
Rust dependencies:
cargo
,code-blocks-server
, no longer required. -
Force moves: Were inconsistent (especially in indent-based languages) and rarely useful.
If they are missed, please comment on this issue, preferably with your use case.
Full Changelog: vscode-extension-v0.5.2...v0.6.0
vscode-extension-v0.5.2
vscode-extension-v0.5.1
What's Changed
- 87 block mode run on unsupported languages by @selfint in #88
- Focus selection if moved out of view by @selfint in #90
- 91-improve-force-move-ux by @selfint in #92
- 93-navigate-between-blocks-command by @selfint in #95
- make block mode a vscode context by @selfint in #99
- add select block command by @selfint in #101
- Create .github/workflows/jekyll-gh-pages.yml by @selfint in #104
- add configurable colors by @selfint in #106
- 107-update-assets-to-v051 by @selfint in #110
Full Changelog: vscode-extension-v0.5.0...vscode-extension-v0.5.1
vscode-extension-v0.5.0
What's Changed
- 77-inline-view by @selfint in #79
- 80-check-code-blocks-server-version-in-extension by @selfint in #81
- 82 remove block mode highlights when switching editor by @selfint in #84
- VSCode extension version 0.5.0 by @selfint in #86
Full Changelog: vscode-extension-v0.4.5...vscode-extension-v0.5.0
code-blocks-server-v0.6.0
vscode-extension-v0.4.5
What's Changed
Full Changelog: vscode-extension-v0.4.4...vscode-extension-v0.4.5