make
is command line tool related to Linux environment so you can't use it in windows CMD or PowerShell. To use make
in windows envronment you have to install either MINGW
or cygwin. This file illestrates how to install cygwin step by step then integrate cygwin into vscode
- Download cygwin installer from this link.
- Run cygwin installer.
- In choose package type make in search bar and the new column choose a version to be installed (any version) - I selected all automake packages and cmake - then press next
- After cygwin installation a cygwin shotcut will be on the desktop
- open cygwin terminal (from the desktop shotcut) and type make (You should see
make: *** No targets specified and no makefile found. Stop.
) if another output is shown please contact me (Most probably make was't installed in cygwin, error happend with step 3)
- From VSCode extensions install
shell launcher
- press the gear button (Manage) and select keyboard shotcut
- open KeyBindings.json and add these lines
// Place your key bindings in this file to override the defaults
[{
"key": "ctrl+shift+t",
"command": "shellLauncher.launch"
}]
- press the gear button (Manage) and select settings
- search for launcher and from
Shell launcher Shells:windows
pressEdit in Settings Json
- Add this json object in the
shellLauncher.shells.windows
list
{
"shell": "C:\\cygwin64\\bin\\bash.exe",
"args": ["--login"],
"label": "Cygwin Bash",
"env": {"CHERE_INVOKING": "1"},
"launchName": "Cygwin Bash",
},
- Press
ctrl+shift+t
and choose Cygwin Bash