Beta Coming soon. This feature is still being built, so names and details may change before it ships.

Run icons on hover

Hover a line that can run (a package.json script, a test, a main entry, a Makefile target, a shell script) and a green ▷ shows in the gutter beside it. It shows only while you hover, so your code stays clean.

package.json with a green play icon in the gutter beside the hovered hello script and nothing above the scripts blockpackage.json with a green play icon in the gutter beside the hovered hello script and nothing above the scripts block
package.json with a green play icon in the gutter beside the hovered hello script and nothing above the scripts block

Run, debug, or run with changes

  • Click ▷ to run that entry in a terminal named after it, for example npm run dev. Running it again replaces that terminal.
  • Right-click ▷, the line number or the line itself for Run, Debug and Run with….
  • Run with… shows the command first, so you can add arguments or environment variables (PORT=4000 npm run dev -- --open) before it runs.
  • Debug starts the entry under the right debugger: the Node.js inspector for npm scripts and JavaScript or TypeScript tests, the Python debugger for __main__ and pytest, the Java debugger for main. Where Ingot has no debugger for that language yet, Debug is greyed out and Run still works.
Right-click menu on the play icon of the serve script with Run, Debug and Run with…; the fail script above shows a red markRight-click menu on the play icon of the serve script with Run, Debug and Run with…; the fail script above shows a red mark
Right-click menu on the play icon of the serve script with Run, Debug and Run with…; the fail script above shows a red mark

What gets a ▷

FileLinesRuns
package.jsoneach script in "scripts"npm run <script> in that package's folder
JavaScript / TypeScript teststhe file (first line), each describe, each testyour project's runner (Vitest, Jest, Mocha, Playwright or node --test) with that test's name
Pythonif __name__ == "__main__":; in test_*.py the file, Test… classes and test_… functionspython3 <file>, or python3 -m pytest <file>::<test>
Gofunc main() in package main; func TestX(t *testing.T)go run ./<package>, or go test -run '^TestX$'
Javastatic void main(String[] args)java <file>
Rustfn main(); #[test] functionscargo run (--bin <name> in src/bin/), or cargo test <name>
C#static void Maindotnet run
Makefileeach targetmake <target>
Shell scriptsthe first line of .sh, .bash and .zsh files, and of files that start with a shell #!bash <file> (or the shell named in #!)

While it runs, and when it fails

While an entry runs, its icon stays as a red ■ without hovering. Click it to stop the run, in the terminal or the debug session.

Debugging the serve script: the Debug view on the left, the debug toolbar at the top and a red stop square in the gutter beside serveDebugging the serve script: the Debug view on the left, the debug toolbar at the top and a red stop square in the gutter beside serve
Debugging the serve script: the Debug view on the left, the debug toolbar at the top and a red stop square in the gutter beside serve

When a run ends with an error, a red ⓧ stays on its line. Hover it for the exit code; click it to run again.

A red error mark beside the fail script after npm run fail exited with code 3A red error mark beside the fail script after npm run fail exited with code 3
A red error mark beside the fail script after npm run fail exited with code 3

Breakpoints

Clicking the gutter of a line that runs nothing still adds a breakpoint, as before. On a line with a ▷, right-click and choose Add Breakpoint, or press ⌘F8 (Ctrl+F8).

Turn it off

Run icons are on by default. Turn them off in Settings › Editor › General › Run icons on hover, in Settings › Features, or in your settings file.

SettingValuesDefault
ingot.editor.runIcons.enabledtrue or falsetrue

Good to know

  • The fixed "Debug" line that used to sit above "scripts" in package.json is gone; the ▷ on each script replaces it.
  • The Test Explorer still runs whole suites from its own panel; the ▷ runs the one test you are looking at.