tASTe: The AST EditorEditing code often involves dealing with low-level textual representations, which can be tedious and error-prone. tASTe is a vscode extension to edit code based on its structure, allowing you to interact more directly with the elements that make up your language. For example, when your cursor is inside a for loop, you can invoke a command to select the whole loop at once. Or, if you have a list of elements, tASTe gives you a command to jump from one element to the next, or expand the current selection from one element to te next. This works equally well with strings in a list as it does with other syntactic elements of many languages; you can for instance jump between code blocks (to jump from one function to the next for example), or select markdown paragraphs one after the other. The theme of this plugin is to do away with some of the tediousness of editing code by raising the level of abstraction, so as to end up a little closer to manipulating the concepts inherent to your programming language instead of characters. Hopefully resulting in less errors and more fun :) CommandsExpand and Contract Selection
Grow and Shrink Selection
Move Cursor
Select Top Level
Raise
Swap
Slurp / Barf
Install instructions
Here's some suggested ones:
Supported languages
TroubleshootingUnrecognized languageIf you get the message "The language ... is not yet supported by tASTe" but the language of my file listed as supported in this readme, it could be that vscode cannot auto-detect the language in question. You can verify this by checking that the language is shown correctly in the bottom-right corner of vscode. In case it's not shown correctly, you might need to install an extension that enables support for your language. If the language is already recognized correctly and you still get the "language not supported" error, the problem is probably that the languageId assigned by vscode to your language does not coincide with the one used by tree-sitter. Please open an issue! CreditsCredit for this idea goes to the long lineage of lisp structured editors, with a special shoutout to Emac's paredit and vscode's Calva. A special thank you also to the developers of Tree-sitter and its many parsers, without which this wouldn't be possible. Dev HOWTOsBringup development environment
Publish
Get Personal access tokenThis only applies if you are the extension publisher (simonacca). Rebuild parsers
Configure a new language
A language is installed and built but not recognizedAdd an entry in |