第一步: 设置一个新的外部配置工具
在 Eclipse 中,选择 “Run -> External Tools -> External Tools Configurations”

第二步: 点击 “New Launch Configuration”

第三步: New Configuration 界面

第四步: 提供命令行配置的详细信息
Name:就是你配置的名字,随便取
Location:CMD.exe 的文件位置
Working Directory:就是命令行打开后的默认工作路径

第五步: 选中“Allocate Console”复选框
这个选项是把 Eclipse 工作台作为命令行来获得输入和输出。

第六步: 点击“Run”
你将打开一个 C: 为工作路径的命令行

第七步; 几个简单的示例命令

就这么简单!