Thisiswhy I'm goingtogooverthe 10 mostimportantkeyboardshortcutsthateveryprogrammershouldknow, because I'veseenfartoomanypeoplenotknowthesesimplecommands, whichwouldsaythemhoursoftimeovertheirlifetime.
Solet's getstartednowbeforewegetstarted.
I wanttoprefacethisvideobysayingthatifyouareanexperiencedprogrammer, thenyoumayalreadyknowalltheshortcutsonthislist.
I wouldstillrecommendwashingbecausetheremaybeoneortwothatyouarenotfamiliarwith.
Butjustbeawarethatyouprobablyknowmostoftheitemsonthislist, and I havethemallLinkedIndescriptionbelow, soyoucouldjumpdirectlytotheonesthatyoudon't knowandskipovertheonesyoudoknow.
I alsowanttomentionthatwhiletheseareverycommonkeyboardshortcuts, theymaynotworkineverysingleeditor.
Thefirstshortcutthat I wanttotalkaboutisdefinitelytheeasiestoneandonethatyouprobablythemostfamiliarwith, andthat's copycutandpaste, butin a waythatyoumaynotbeusedtousingitasyouallprobablyknowyoucanusecontrol C tocopysomethingthatyou'vehighlighted.
Youcanthenusecontrol V topastethatthingthatyouhighlighted.
Andthen, ifyouwanttosearchthroughoutyourentireproject, youcanusecontrolShift F, whichwillopenup a searchbaroverhere.
Andif I searchforassets, forexample, overhere, it'llshowmeallthedifferentfileswhere I'veusedthatwordassetsand a lotofmajorsclickonitandgoexactlythatlineinthatfile, whichisincrediblyuseful.
Anotheramazingextensionthatsavesmetonsoftimeistheabilitytoindentanduninventmultiplelinesat a time.
So, forexample, if I wantedtoinventthesethreelines, oneindentationfurther, all I doishighlightthemandthenclicktabandwe'llenditallthoselinesbyonetab.
I didthisasmanytimesas I want, butif I wanted a newindented, I justholddownshiftandclicktabagain, and I willdotheexactoppositeanduninventedbyonetackeverysingletimethat I clickit.
Thenextshortcutmaynotbethemostusefulinlargerprojectswhereyouwanttospecificallysaywhereyouneedyourfilestogo, butwhenyouneedtojustcreate a newfilequickly, youcanjusthitcontrolandandopenup a brandnewfileforyouthatyoucanthensaveanddesignatewhereyouwanttosaveto.
Thisnextshortcutisincrediblyusefulwhenyouneedtochangethingsinsideof a linewhilewritingcode.
Forexample, if I wantedtochangethistobeassetinsteadofassets, I gohere, Dowepassit?
Andthen, if I wantedtoadd a newlineafterit, normally I wouldhavetoarrowoverorclickontheendofthelineandthenclickentertogettothenextline.
Butif I'm overinthemiddleofmylinehereand I wanttocreate a newone, all I candoishitcontrolandenterautomaticallycreate a newlineandputmycursoronit, nomatterwheremycursorisinthelineaboveit.
Andwefinallygottothelastshortcutourlist, whichisactually a collectionofthreedifferentshortcutsthatareallverysimpletouse, andyouprobablyalreadyknowthem.
Butthey'reincrediblyusefulwhenyourprogramming, the 1st 1 ismyfavoriteshortcut, which I literallyuseallthetime.
It's just a habitrightnow, andthatiscontrol s inordertosaveyourfileallthetime, as I'm writingdifferentcode, justtakecontroluseverysingletime.
I stoppedcuttingjusttomakesure I haveeverythingsaved.
It's a habitofmine, andit's incrediblyusefulincaseyourcomputerdiesoryourtexteditorcloseswithoutsomethingbeingsaved.
I coulddeleteit, forexample, toremoveeverythinginthatfile, whichisthemostcommonusecase I useforcontrol A.
Or I useitinordertocopyanentirefinal, which I alsouseallthetime.
Asyousawthere.
Thenextsetofshortcutsistheundokey, whichisControl Z.
Socontrol Z lawsmeanundosomething.
Soif I deletethis, I couldjusthitcontrol Z andit'llundothatandallowmetohaveeverythingasitwas, andthenthereverseofthatisgoingtobecontrolledshipdizzy, whichallowsyoutoredosomethingthatyou'veundone.
Sometexteditorswillhavecontrol.
Whybetheundokey?
Soyoujusthavetomakesureandseewhichoneitis.
Inyourtext.
Editor, I'm usingvisualstodo a codewhereyoucanuseeithercontrol Z control, shift C orcontrol.
Soif I putthishereand I usecontrol, whyyou'llsee a ndezitorif I usecontrolstrip, seeitundoesitaswell.
The 1st 1 istobuild a cutcopyandpastelinesat a timebynothighlightinganythingandthatchoosingcontrol C forcopycontrol, expertcutandcontrol V forpaste.
ThenextthingthatwetalkedaboutwasusingcontrolplustheFordSlashinordercommentoutanyCodyofhighlightedorthelinethatyourcursorisonandthatallowsyoutocommentanduncommonsoitessentiallyworksis a tacowhichisincrediblyuseful.
Thenextthingthatwetalkedaboutisusingcontrol p tosearchfor a filebynamethat's insideofyourproject.
AndthenwewentonandwetalkedaboutusingcontrolleftandcontrolShiftattosearchforeitherinsideofyourfilewithcontrol F orinsideofyourentireprojectusingcontrolShift F.
Thencontrolenterallowsyoutocreate a newlinethat's belowwhateverlineyourcursoriswithoutactuallymatteringwhereyourcursorisinsideoftheline, whetherit's inthemiddleoflinebeginningonthelineendoftheline, italwayscreates a newlinethat's completelyblankforyouafterthelineyou'recursorson.
Thenwetalkedaboutusingcontrol, plusthearrowkeysinordertomoveentirewordsat a timeandshiftplusthearrowkeysinordertobuild a highway.
Anentirefilecontrol s tosavethecurrentfilethatyouhaveopenedandincontrol Z toe, undoandcontrol, sip, seeorcontrol.
Why?
Toredowhateveryou'veundone.
So I reallyhopeyouguysenjoyedthisquickvideoaboutthedifferentshortcutsthatareincrediblyusefulwillsaveyoutonsoftimeoveryourcareeras a programmer.
Ifyoudidenjoyit, pleasemakesuretoleave a lightdownbelowsothat I knowyou'reenjoyingthecontentandletmeknowinthecommentsbelowwhatshortcutsthatyouthinkthat I'vemissed.
I wanttomake a followupvideotothisinthefuture, goingovervisualstudiocodespecificshortcuts.