且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

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

更新时间:2022-06-30 21:27:52

文档: 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

<?php
echo "hello world";