Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>venkatNew to Visual Studio Code? Get it now.
venkat

venkat

Mark Needham

|
76 installs
| (1) | Free
Run code snippet and show result inline.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

venkat

This is the README for the VS Code extension "venkat".

It runs the example file up to the current line (or the selection) and displays the result of that last line in a comment after or for multi-line results below (or as info message).

It is inspired by Venkat Subramaniam's use of Textmate tooltips for code execution results which is great for presentations.

Features

  • execute selection or code up to current line
  • Language support for python, javascript, typescript, ruby, java, kotlin
  • supports multiline outputs
  • selects result, so can be deleted or copied with a single keystroke
  • show result as comment or as info message
  • configurable extra languages

Requirements

An interpreter for the languages used, should be installed.

  • python: python
  • javascript : node
  • ruby: ruby
  • java: jshell -s
  • kotlin: kotlin
  • typescript: ts-node
  • php: php -f

Configuration

  • resultAsComment : boolean, default true - insert the result as comments, otherwise show them as info message

  • languages : structure for languages with entries for extension, comment, executable, output, exit, where output contains a ${expression} placeholder, and exit optionally contains code to end the script execution.

Here are two examples:

    "venkat.languages": {
        "python": {
            "comment": "#",
            "executable": "python",
            "extension": "py",
            "output": "print(${expression})"
        },
        "java": {
            "comment": "//",
            "executable": "jshell -s ",
            "extension": "java",
            "output": "System.out.println(${expression});",
            "exit": "/exit"
        }
    }
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft