This article refer to the following blog post, but it did not have a place to make it clear, as I ought way to do it, I had a little mistake.
Slight modifications on it. Following the modified method posted (mainly copy him, made some modifications)
https://blog.csdn.net/he_yang_/article/details/96644480
We all know that clion using cmake to build and run the project for a single cpp file compiler does not support. Some online method is achieved by modifying the CmakeLists.txt file, but creates a file each time you have to modify the file, relatively cumbersome, so is there any way once and for all it?
Haha, of course, some friends !!!
we can to achieve this functionality to configure external tools.
1. Configure External Tools
Here g ++, G ++ to change the bin file of your own mingw. Exe, others do exactly as drawing the line
2 Configure Shortcuts
3. Test
Done
After the configuration I think there may be a key to compile and run, then had to try.
however. . .
Command line can be executed, the tool is not, why he is not yet. . .
The only drawback is that still need points twice, not once both compile and run.