riscv-asm-vscodeVisual Studio code extension that provides syntax highlighting for RISC-V assembly. This extension highlights instructions defined in the RISC-V Instruction Set Manual Volume I, Chapters 1 to 30. Control flow-aware syntax highlightingTo make it easier to quickly understand the structure of RISC-V assembly
programs, this extension applies the scope
Several color themes do not define distinct colors for
Additionally, you can apply special coloring to a subset of the control keywords using the following scopes:
Here is what the Monokai theme could look like with four extra rules to give each type of control keyword a different color:
A quick intro to Visual Studio Code syntax highlightingThis extension does not actually define any colors. In the file A scope is just a string like The color scheme you are using has many rules that specify the color/style of each scope. To add your own styling rules, press Ctrl+Shift+P, select "Preferences: Open User Settings (JSON)", then add something like this to the top-level object:
When coloring a token with scope "AA.BB.CC", VS Code applies any rules with scope "AA", "AA.BB", or "AA.BB.CC". Attributes in the rules with more-specific (longer) scopes override conflicting attributes from less-specific rules. For more info, see the official Syntax Highlight Guide. Tips for developing this extensionInstall NodeJS. For exmaple, on MSYS2, run:
Open this repository as the workspace. Run Ctrl+F5 to open a new VS Code window with the extension loaded from the files in the workspace. In that new window, open a RISC-V assembly file, and make sure it says "RISC-V Assembly" in the lower right corner of the window where the language is shown. Publishing a new version |

