Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>osmiaNew to Visual Studio Code? Get it now.
osmia

osmia

jkutkut

|
2 installs
| (0) | Free
Extension for the osmia language
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

osmia

The official Visual Studio Code extension for osmia.

Osmia is a clean, expressive templating language library implemented in Rust. It is designed for building dynamic content in any programming language, allowing developers to generate HTML, SQL, JSON, configuration files, or code in various languages.

Code example of an osmia script that formats the output of a docker inspect command

How to use

Create a osmia file by creating a file with the extension .osmia or by selecting the osmia language from the command pallete.

An button with the osmia icon will appear in the editor to run the current file. You can also invoke the command with right click or by running the following command from the command palette:

>osmia: run

Optionally, a context file (json) can be added to inject variables. You will be prompted to select the file if none is detected.

Features

  • Syntax highlighting.
  • Intellisense for variables in context.
  • Configurable execution engine.
  • Fully customizable settings.
  • Built-in wasm engine.
  • Command to run the current files as a Osmia program.
  • Automatic detection of Osmia and context files.

Requirements

A built-in osmia engine comes with the extension. A custom engine can be used instead by changing the configuration.

Extension Settings

  • osmia.executionTimeout.enabled: Enable execution timeout. Code will be aborted if execution takes longer than osmia.executionTimeout.time.
  • osmia.executionTimeout.time: Execution timeout in milliseconds. If the execution takes longer than this, it will be aborted.
  • osmia.executionTimeout.warnTime: Warning timeout in milliseconds. If the execution takes longer than this, a notification will be shown. The execution can be aborted using this notification.
  • osmia.osmiaEngine.native: Use the extension's wasm builtin implementation. If set to false, the osmia.osmiaEngine.osmiaCmd will be used.
  • osmia.osmiaEngine.osmiaCmd: The command to invoke osmia on the system. Only used if osmia.osmiaEngine.native is set to false.

Release Notes

See CHANGELOG.md for details.

Known Issues

  • Testing not implemented, yet.
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft