VSCode插件 code runner执行PHP,JavaScript,Python

文档: https://github.com/formulahendry/vscode-code-runner

常用设置

// 运行之前保存文件
"code-runner.saveFileBeforeRun": true,

// 清空控制台
"code-runner.clearPreviousOutput": true,

// 指定Python解释器
"code-runner.executorMap": {
  "python": "/Users/.pyenv/versions/py370/bin/python3",
},

快捷键
运行快捷键改为: control + r

用以下文件测试都可以顺利执行
demo.js

console.log("hello world");

demo.py

print("hello world");

demo.php


echo "hello world";

这样就可以快速测试一些简单的程序,不用启动IDE了

你可能感兴趣的:(VSCode插件 code runner执行PHP,JavaScript,Python)