Тёмный

Run C/C++ Code Visual Studio Code On Ubuntu 

Linux Hero
Подписаться 354
Просмотров 106 тыс.
50% 1

Run C/C++ Code Visual Studio Code On Ubuntu....
{
"version": "2.0.0",
"tasks": [
{
"label": "debug",
"type": "shell",
"command": "",
"args": ["g++","-g", "${relativeFile}", "-o","a.exe"]
},
{
"label": "Compile and run",
"type": "shell",
"command": "",
"args": [
"g++","-g", "${relativeFile}", "-o","${fileBasenameNoExtension}.out", "&&", "clear" , "&&" , "./${fileBasenameNoExtension}.out"
],
"group": {
"kind": "build",
"isDefault": true
},
"problemMatcher": {
"owner": "cpp",
"fileLocation": ["relative", "${workspaceRoot}"],
"pattern": {
"regexp": "^(.*):(\\d+):(\\d+):\\s+(warning|error):\\s+(.*)$",
"file": 1,
"line": 2,
"column": 3,
"severity": 4,
"message": 5
}
}
},
]
}

Наука

Опубликовано:

 

7 май 2018

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 184   
@LinuxHero
@LinuxHero 6 лет назад
Copy Code From Description
@Plutonergy
@Plutonergy 6 лет назад
How do i make this the default setting?
@midas2570
@midas2570 5 лет назад
@@Plutonergy did u find a way?
@midas2570
@midas2570 3 года назад
@Satyam Sundaram no. Still have this problem :(
@partialdata
@partialdata 5 лет назад
these damn task runners are harder to figure out than the actual program i'm trying to write... Thank you sir!
@ericcartman4799
@ericcartman4799 4 года назад
lol so true
@drachnelord7433
@drachnelord7433 3 года назад
Thanks brother, was trying for three days without a break! love the song
@swapneil5549
@swapneil5549 5 лет назад
was trying since last 30 mins on how to run c++ code in visual studio when I came across this. Solved my problem. Thanks man!!
@LinuxHero
@LinuxHero 5 лет назад
You Are Welcome...
@faisalahmed9434
@faisalahmed9434 5 лет назад
I spent more than 5-6 hours -_-
@jeffcheng2868
@jeffcheng2868 5 лет назад
Man, you are awesome. Thanks. Setting up Virtual Machine and running Ubuntu weren't that difficult, but setting up VS Code to run has proven indeed very difficult. Thanks!
@SimonYells
@SimonYells 5 лет назад
Simple and straight to the subject! Thanks :D
@gabriel7cd310
@gabriel7cd310 4 года назад
case folk not be success in open the task.json file, after press ctrl+shift+b in list you can see 1 or more selects option of c/cpp compiler builder and in right side of item have a small gear, click this and the task file be open, after past the json code in file, save and enjoy :)
@itsdanielpin
@itsdanielpin 4 года назад
Nice dude its working! Thanks you... Finaly a will code in visual
@CrazySkillz15
@CrazySkillz15 4 года назад
Thanks so much! Was looking for something just like this :)
@cyfull1985
@cyfull1985 4 года назад
thanks a lot bro, still work on 2020...
@AHMEDADEL-qx2ip
@AHMEDADEL-qx2ip 5 лет назад
Maaan, this video saved my life. Finally, I can now start coding and finish my freaking assignment.
@LinuxHero
@LinuxHero 5 лет назад
Welcome. I'm glad to help you.
@minhaz2597
@minhaz2597 5 лет назад
it's very helpful video.Thank you sir..
@nancygarcia9814
@nancygarcia9814 4 года назад
Finally!! thanks a lot, blessings :D
@ivanj988
@ivanj988 5 лет назад
Thanks! For Linux Deepin users, this tutorial solved the problem! :D
@LinuxHero
@LinuxHero 5 лет назад
Deepin is also based on ubuntu. so it works.
@dk0263
@dk0263 3 года назад
thanks a lot for this bro! works like a charm and saved me a lot of time trying to configure this
@LinuxHero
@LinuxHero 3 года назад
Welcome. Stay Safe.
@nidhish1407
@nidhish1407 5 лет назад
Damn....this works. Thanks man :)
@szabolcsagai
@szabolcsagai 5 лет назад
Thanks, hero of the day is you today :)
@eudo81
@eudo81 5 лет назад
thanks man , you are a hero!
@CREATIVEEXPERTZ
@CREATIVEEXPERTZ 3 года назад
Thank You Sir :D keep making such videos
@LinuxHero
@LinuxHero 3 года назад
Welcome .😀
@rk_0059
@rk_0059 3 года назад
thanks brother. i was trying for last 2 hours.
@rajangohil497
@rajangohil497 5 лет назад
Worked, thanks!
@cesarmoltoni
@cesarmoltoni 5 лет назад
It's works in Kubuntu 18.10 Very helpful
@gogolja4
@gogolja4 5 лет назад
The Best! Thank you very much
@hameddoroudi1993
@hameddoroudi1993 3 года назад
thanks ,thats short and powerly .nice
@shahriar-siddique
@shahriar-siddique 4 года назад
Thanks man!! That save my many time.
@LinuxHero
@LinuxHero 4 года назад
স্বাগতম ভাই। sub++?
@stalker1961
@stalker1961 4 года назад
2020, June 18. Working Respect+
@LinuxHero
@LinuxHero 3 года назад
Thanks . Sub++ 😊
@amirbahador.developer
@amirbahador.developer 4 года назад
tnx man Its really work!!! ty very much
@juniorcoder6988
@juniorcoder6988 5 лет назад
Very useful ! Thanks for author !
@darshant6935
@darshant6935 3 года назад
u are a legend...awesome tutorial!!
@josuecoronado1300
@josuecoronado1300 5 лет назад
2019; still working!
@borufkaz
@borufkaz 5 лет назад
Works great!
@marekcingel6633
@marekcingel6633 5 лет назад
Very nice example. Haw to create precompiled header?
@abboskhamidullaev3948
@abboskhamidullaev3948 4 года назад
very good. thank you!!
@JSCruz-to9cr
@JSCruz-to9cr 4 года назад
Oh dear god!! It finally works, thanks a lot!!
@LinuxHero
@LinuxHero 4 года назад
Welcome and Subscribe. 😊
@leodeguzman463
@leodeguzman463 5 лет назад
thanks man.....hope you also make how to remove autofill on vs code
@mattwilliams1844
@mattwilliams1844 5 лет назад
just have a terminal running and run code in that... So much easier. g++ -Wall yourFile.cpp -o test Then it runs your code in your terminal.
@rafehn
@rafehn 5 лет назад
Matt Williams where do I out that g++ -Wall command for it to run in my terminal?
@itsanantsingh
@itsanantsingh 4 года назад
i know but for some reason i cant do it right now...dunno what i did wrong
@Metamor-phosis
@Metamor-phosis 3 года назад
That's exactly my thing! I just want vs code for the editing, managing the project tree, etc...
@kostyastrong3556
@kostyastrong3556 4 года назад
You are god dame right, it works!!!
@quazar-omega
@quazar-omega 4 года назад
Thank you, this has saved me
@turararykbaev840
@turararykbaev840 5 лет назад
Thank You VERY MUCH!!!
@ln4043
@ln4043 5 лет назад
Hello from Russia))) thank you very much))) its work)) but need install gcc on your system)))
@LinuxHero
@LinuxHero 5 лет назад
Welcome.
@rafehn
@rafehn 5 лет назад
You can install gcc on ubuntu by typing the following command in terminal sudo apt-get install gcc
@ln4043
@ln4043 5 лет назад
@@rafehn yes all right)))
@erai-sama
@erai-sama 5 лет назад
Thanks it's worked +1
@angelluisgomezmartinez89
@angelluisgomezmartinez89 3 года назад
It works, thank you!!!
@deeppanchal1332
@deeppanchal1332 5 лет назад
Thanks. It works
@user-qp9ux2mr1u
@user-qp9ux2mr1u 4 года назад
Elektronomia - Sky Higt music.. Good
@yourownazog8069
@yourownazog8069 5 лет назад
The greatest thanks to you!!!!!!!
@LinuxHero
@LinuxHero 5 лет назад
Welcome
@16_deveshshirsath88
@16_deveshshirsath88 4 года назад
Worked mannn!!
@kasimbasil4481
@kasimbasil4481 4 года назад
thank u so much , u saved me ! Legend.
@manikanthanekkalapudi
@manikanthanekkalapudi 4 года назад
Holy Shit! This works! Thanks you! :)
@alijavidi2503
@alijavidi2503 5 лет назад
2019 , You saved me
@parthsharma322
@parthsharma322 3 года назад
thank you sir for your service.
@mandeep2192
@mandeep2192 4 года назад
it finally worked !!.. thnx
@LinuxHero
@LinuxHero 4 года назад
Welcome. :)
@blackbarry45
@blackbarry45 4 года назад
do you have this for c# ?
@borufkaz
@borufkaz 5 лет назад
Hi Great Tutorial! Thank you! Can you make a similar video for the debugger in visual studio code on Ubuntu? I would appreciate it and it could be a continuation of that clip! Regards, PT
@LinuxHero
@LinuxHero 5 лет назад
I will Soon Try
@borufkaz
@borufkaz 5 лет назад
@@LinuxHero thanks :) :)
@adityabealways
@adityabealways 4 года назад
Thanks man!!
@juliocesar2159
@juliocesar2159 4 года назад
Thanks, it worked.
@phamphungoctrai7235
@phamphungoctrai7235 5 лет назад
thanks a lot
@md.saifulislam3352
@md.saifulislam3352 4 года назад
Well done. Thank you very much............
@LinuxHero
@LinuxHero 4 года назад
ধন্যবাদ
@HugoMaxMTeixeira
@HugoMaxMTeixeira 3 года назад
Thanks a lot.
@Tanzeel431
@Tanzeel431 5 лет назад
How to make that json file default for our machine.
@samuelfelipev.goncalves6352
@samuelfelipev.goncalves6352 4 года назад
thanks dude!
@lakshaykumar7518
@lakshaykumar7518 5 лет назад
Thanks alot.
@samuelrushton8090
@samuelrushton8090 4 года назад
You can also just use the code runner extension
@motaharhossain4855
@motaharhossain4855 3 года назад
Code runner sometime sucks.
@ta2ulk
@ta2ulk 4 года назад
Thanx a lot ^^
@nalanbyc3849
@nalanbyc3849 4 года назад
You got my 100% love.
@nalanbyc3849
@nalanbyc3849 4 года назад
Wroks for Deepin user until now.
@longhai6825
@longhai6825 5 лет назад
what is this Theme?
@johnnguyen6224
@johnnguyen6224 3 года назад
Thank you for the guide! Working in 2020
@LinuxHero
@LinuxHero 3 года назад
Thank You. Stay Subscribe :)
@johnnguyen6224
@johnnguyen6224 3 года назад
@@LinuxHero Do you know how to enable the terminal in the IDE to 'let user input data'? Example: int main(){ int a,b; printf("Please insert number: "); scanf("%d", &a); b = a * a; printf("Result is: %d * %d = %d", a, a, b); return 0; } Online IDE let me insert a number. VS code does not. Thanks in advance
@LinuxHero
@LinuxHero 3 года назад
@@johnnguyen6224 Which ide you use?
@LinuxHero
@LinuxHero 3 года назад
If you use VS Code then after pressing ctrl+shift+b . you will see a black terminal and a keyboard cursor blinking. Then you will enter a number and press enter.
@LinuxHero
@LinuxHero 3 года назад
And if you use Windows then follow his method. ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-Si8rN5J249M.html
@ziwok5831
@ziwok5831 4 года назад
Thanks so much! But how to debug?
@omerzerenuz6184
@omerzerenuz6184 4 года назад
you're a true hero
@LinuxHero
@LinuxHero 3 года назад
Thanks
@ekanshsharma1507
@ekanshsharma1507 4 года назад
Thanks
@manavendrasen
@manavendrasen 4 года назад
you are god thank you soooo much
@deniznehlyadyuk4447
@deniznehlyadyuk4447 5 лет назад
thanks!
@christopherlathrop6317
@christopherlathrop6317 5 лет назад
Thank you!
@LinuxHero
@LinuxHero 5 лет назад
Welcome
@RajeshKrishnan1
@RajeshKrishnan1 4 года назад
How to launch a debug session where a C/C++ program is called from a shell script in Visual Studio Code?
@motaharhossain4855
@motaharhossain4855 3 года назад
F5
@fustrebe
@fustrebe 3 года назад
Ty brother
@Anonymous-2-0-1-2
@Anonymous-2-0-1-2 4 года назад
An unknown Hero . Thanks
@LinuxHero
@LinuxHero 3 года назад
Thank You 😀
@rapid1010
@rapid1010 5 лет назад
thanks
@Rahul.Kumar.
@Rahul.Kumar. 3 года назад
Great! Finally works. Can you do the same for java also. Thanks a lot
@motaharhossain4855
@motaharhossain4855 3 года назад
Use Geany. Its great. You can compile and run any programming language. I have tasted C/C++, Java and Python.
@unlucky9095
@unlucky9095 4 года назад
u save my life man tnk u
@ihate4chan
@ihate4chan 4 года назад
Do I have to do this everytime I create a project/ cpp file?
@LinuxHero
@LinuxHero 4 года назад
No.
@andresperezgomez9179
@andresperezgomez9179 3 года назад
ProAndroid's volume test song
@Abdurrahim-eo1kq
@Abdurrahim-eo1kq 6 лет назад
nice video..
@LinuxHero
@LinuxHero 6 лет назад
Thank You
@LinuxHero
@LinuxHero 6 лет назад
Thank You
@limitless9483
@limitless9483 3 года назад
HERO thanks
@maxmiau
@maxmiau 4 года назад
The easist method by far, but still i have no idea what the json file do :(.
@francescobassino2471
@francescobassino2471 5 лет назад
I love you
@sankalpgodghate7001
@sankalpgodghate7001 5 лет назад
The output console flashes for a second and then vanishes off. I will really appreciate if you could help that out.
@javierflores5727
@javierflores5727 3 года назад
figured it out?
@vanshbhardwaj4214
@vanshbhardwaj4214 5 лет назад
how to debug..explain please
@bjay6886
@bjay6886 4 года назад
f5
@fujiahermawan8
@fujiahermawan8 3 года назад
thx its work
@madihashabbir
@madihashabbir 5 лет назад
i couldn't find that json code file. is it present in the installer?
@SohelRana-hi7ec
@SohelRana-hi7ec 5 лет назад
Copy from video description.
@SohelRana-hi7ec
@SohelRana-hi7ec 5 лет назад
Copy from video description
@essamahmed1511
@essamahmed1511 4 года назад
/bin/bash: g++: command not found The terminal process terminated with exit code: 127 it gives me that every time i try to run the simple code however i followed the same steps !!
@areebmuzaffarsyed859
@areebmuzaffarsyed859 4 года назад
askubuntu.com/questions/583171/bin-bash-g-command-not-found-error-127
@SohelRana-hi7ec
@SohelRana-hi7ec 4 года назад
install g++ in your machine.
@akash-alam
@akash-alam 6 лет назад
wow thanks dear
@LinuxHero
@LinuxHero 6 лет назад
You Are Welcome...
@LinuxHero
@LinuxHero 6 лет назад
Welcome
@midas2570
@midas2570 5 лет назад
Do i have to do this every time i open a new file?
@LinuxHero
@LinuxHero 5 лет назад
No
@midas2570
@midas2570 5 лет назад
@@LinuxHero so how can i apply these as default or sth?
@akash-alam
@akash-alam 5 лет назад
just press ctrl+shift+b
@gosharevo
@gosharevo 4 года назад
thank u
@leandror6828
@leandror6828 4 года назад
2020 Tksss!!!!
@loeipm3953
@loeipm3953 5 лет назад
thank you
@LinuxHero
@LinuxHero 5 лет назад
Welcome
@shiwanshsingh4977
@shiwanshsingh4977 4 года назад
from where i get json code that you pasted??
@LinuxHero
@LinuxHero 4 года назад
Check Video description
@devpatel7916
@devpatel7916 3 года назад
app kon sa linux use karte ho?
@LinuxHero
@LinuxHero 3 года назад
Mainly I use Ubuntu, but I also use Manjaro and KDE Neon.
@j.nikhilsudhan1301
@j.nikhilsudhan1301 3 года назад
thx bro...
@photon2724
@photon2724 5 лет назад
wtf. This just confused me further. All i had to do for my previous ide was press a single button to compile and run. What is this shit...
@ankurbhatia24
@ankurbhatia24 5 лет назад
How to make the settings default.
@LinuxHero
@LinuxHero 5 лет назад
Do it once. and open the same folder everytime. it works
@Filipcorobivblenderi
@Filipcorobivblenderi 3 года назад
It worked until i tried to link more files... Any help? I cant move
@LinuxHero
@LinuxHero 3 года назад
Just copy your cpp or c file to your workplace folder.
@Filipcorobivblenderi
@Filipcorobivblenderi 3 года назад
@@LinuxHero its different then linking in projects. This works for me: #include "SecondPage.cpp "
Далее
Install and Run C++ in Visual Studio Code (Linux)
13:43
How A Steam Bug Deleted Someone’s Entire PC
11:49
Просмотров 892 тыс.
СКОЛЬКО МОИХ ТРЕКОВ ТЫ ЗНАЕШЬ?
00:41
Ozoda - JAVOHIR ( Official Music Video )
06:37
Просмотров 1,1 млн
What Should Be Next? 👀🤯
00:56
Просмотров 7 млн
I've never seen ANYTHING like this before... Temple OS
17:57
Should you learn C++?? | Prime Reacts
20:29
Просмотров 316 тыс.
Debugging C/C++ with Visual Studio Code
8:50
Просмотров 263 тыс.
How I customize my KDE Plasma
16:21
Просмотров 745 тыс.
7 AWESOME Linux Terminal Applications and Utilities
11:49
Warum Linux schöner ist als macOS und Windows
18:42
Просмотров 330 тыс.
Дени против умной колонки😁
0:40
iOS 18 превратилась в Android
0:49
Просмотров 703 тыс.
Эпоха Intel и AMD заканчивается?!
0:46