Theproblemthatyougettoitputinallthethingstogetherinto a serverthatitactuallydoessomethingthatyouneedthat's whereitallagainorlike, justfallsoff a cliff s o againusingthewhereiscommandandthefinecommandcanmakeyourlifeeasierfortryingtodothingslikefindthePHPdot I and I filesothefirstcommand I'llshowyou.
Um, bybeingabletodowhereisandpullupallthefolderswheretheconfigurationfilesandeverythingfortheapplicationarestored, youcanthennavigatetothosefoldersanddo a listcommand.
Seewhatshowsupgo.
Oh, okay.
That's probablywhattheconfigurationfileisn't thatyou'vebeentryingtogoedititthatway, s sothat's whatthewhereiscommandisrelativelysimple.
Actually, lookforwhateveritisyou'relookingforyouas a normaluser, evenasthepersonwhoinstalledtheoperatingsystem, theroute, accountorwhatever, I don't actuallyhavepermissiontogetinto a lotofthefolders.
Solowercase T t e s t dot t x t isdifferentthanuppercase.
T e s t t x t Right.
Soifyouputfindhyphennameandthen a singlequotationmarkon, thenlowercase t e s dot t x t closequotationmarkinthehitEnterthenitwillonlylookforlowercase T e s t not t X t.
Ifyouhaveuppercase t e s t t X t, itwillnotfinditbecauseremember, thatis a differentcasemattersintheLenoxworld.
Youmightsay, I wanttoknowalltheeyeand I filesonitlimitsmachineso I coulddofindhyphen, highnamesinglequotationmarksstaratdot I and I knowwhatthatwoulddois I wouldfindanythingthatendsindot i and I.
Oneofthings I trytodowithalltheseclassesisbasicallyjustshowyouthesmallestsubsetpossibletomakeyoufeelcomfortablewithwhatyou'redoingandthenyoucouldgogetgotomanpaidisn't figureouttofigureouteverythingelse.
Sowiththat, let's gooverthecomputerand I canshowyouhowthisworks.
Sohereweare, myAvantiserver.
Again, thisissimply a virtualmachinewithinvirtualbox.
Whereiswhereis a patchytoenterandagainforApachetoo.
WecanseetherearefewerfoldersforApachetoAndwegotthe s beenWegotthelivewegotthe e t c sharesosoforthwithWhereisyoucanevendosomethingassimpleisfineSowhereisfinedagain?
So, youknow, dependingonwhatyou'relookingfor, youyoumayrunintoissuesagain.
Dothewholecapitalizationissue s.
Sothefirstthingis, let's take a lookatusingname, right?
Soif I d'ohsimplyif I simplydofindif I simplydofind, umspace, uh, yourname.
Sowhen I usename, case, casematters, right?
Soitiscasesensitive, andthen I dosinglequotationmarkandthen I dotestnot T x t closedoublequotation.
A singlequotationmark.
Sowhatthisisgoingtodoisfromsofine?
I didnotgive a location.
I didnotgetlocationhere, sofindfromstartinginthisfoldergoingdown.
SoanythingLower.
Ah, fine.
Namecasesensitivetestdot T x t.
Sofindmeanyfinalcalledtestdot t x t fromthisfolderhit, Enter.
Andsoaswecanseehere, I havetestthat t X t.
Andsothisisthisonehere.
Sothisisinthefolder.
Sothisisn't a BobPorter, butthenwecanalsoseeinfolder.
Andthenthere's also a testdot t x t.
Soagain, thiscouldbeoneofthosethingsyourunintoanissueofYou'relookingfor a particularhighand I file, andyouliterallymightbemodifyingthewrongoneforsomereason.
Andsotheinterestingthinghereisthatweseethetestdot t x t aswesawbeforethetestout t X t andthefullherthatwesawbefore.
Andthenwealsoseetestfile, Doc T X t Soagain, thatkindofshowsyoulikeOh, yeahagain, Maybe, maybeifyoukindofyouknow, yourmisspellingin a littlebitYou'relike I kindofsortofknowhowtospellit, youknow, byplugginginthefirstcoupleofletters.
Thenyouthrowin a wildcardthatasteriskwildcardthatmightmakeyourlife a loteasier.
Thefinalthingthat I wanttoshowyouhereisusingmyname.
SoSowiththis, right, wekeepgettingtest.
Wekeepgettinglower.
Casetests.
Soclear.
Clear.
Justmakethiseasier.
See?
Soclear.
EsoNowwhat?
I'm goingtoIt's fine.
Andinsteadofname I'm goingto I namethatsinglequotationmarktestDoc T X t.
Andsowhen I dowiththisthistimenowwhen I hitinherright, I getalltheteston T x t s o theuppercasetestour t x t thelowercaseTextestonday 60 Thetestonlowercasetestdot t x t That's inthefolderandintheuppercase t therestlowercase e s t dot t x t.
Right, Sobyusing I namethatallowsmetofindthatSothosewerethoseweresomeofthethingstobethinkingaboutwhenyou'researchingforfilesnow, oneofthings I'm goingtoshowyouisthatyoucanalsosaywheretolookforfilesandwhyyouneedtousesuit.
My, I wanttoshowyouright, becausetheimportantthingtounderstandhereisthatsincewe'regoingtobesearchingfromroutewhenwedonotusesuitSowhatweneededitwasyoursuit.
Andunless I'm lookingforthePHPthat I and I filePHPDonnaand I fileon, Then I hitEnterandthiswillshowme.
Okay, Sorryabout e t c p 87.2 cli p h a b i e t c p h p 7.2 ApachetoPHPgonnadie.
Andsoagain, thisisoneofthoseimportantthingsThisis a reallyworldthingwithsomethinglikethePHPnotonfile.
SothePHPnot I and I filethatweneedtomodifywhenwe'reforwhenwe'redealingwithwebsitesiswhat's intheApachetosewtheApachetwoph.
PhbeDonnaand I fileistheeyeand I filethatwewanttomodify.
TheCLIisforusingPHPattheCLI.
Andsoagain, thisisoneofthoseissuesyoucanrunintoifyouifyou'resimplygoingtotheclientPHPDonnaand I fileondoingallkindsofmodificationsandthenthingsareworkingoutproperlyagain.
Thereasonisisbecauseyou'resimplynotgoingtowritePHP, not I and I file.
Andsothosearesomethingsthatthinkaboutsothatwe'vegotthose s o letmeshowyousomeotherjustjustrandomoncesothingsthatyoucanlookatisagainlikeuser, right?
Wecanseefolderonthefoldertestnot t x t blah, blah, blah.
So, basically, thisiswaytolookandsee, Youknowwhatfilesareownedbyparticularusers s?
Oh, thatcouldbe a usefulthing, thenthenextonethat I thinkisprettycoolisagain.
WehavetheCIAmythargumentsowecoulddofine.
Uh, then I coulddospaceandthat I coulddosemen.
Andsoit's seamen.
C m I n.
Don't benaughty.
Don't benaughtyhyphen.
SeewhatthisisIsbasicallyanyanyfilesthathavebeenmodifiedinthelasthoweverminuteseso I wascreatingsomefiles.
Solet's say I wanttoseefindfilesthathavebeenmodifiedinthelast 20 minutesfromthisfolderwherewe'reat, I hitEnterandso I canseethatfolder.
Sofolderinthelast 20 minuteswasmodifiedandthenfoldertestDoc T X t wasnot a modifiedinthelast 20 minutes, sothatgivesmeanideaofthedifferentfilesorfoldersthathavebeenmodifiedinthatamountoftime.
SoOh, soletmejustdosomethinghere.
Soletmejust d'ohletmedothemandthen I'll d'ohtestfileforusfileforClassStar T X t Allright, solet's notcreatethis.
Thisopensup.
Sothisisusingthemas I should.
Butyoubefore I'm notgonnaputanythinginhere.
I'm goingtowriteQuit.
Sothat's createdthefile, right?
Sowe'regoingtoclearthescreamif I do.
L s l justtoshowyou.
Sothisisthefilethat I createjustcreatedtestfileforclassDon t x t Novakwasclear.
Andwhat I willdoisallyoufindnewhyphenseamen.
Then I'lldooneminute.
Sofindmesomethingthat's beenmodifiedinlastminuteinnertestfileforclass, not t X t, andthiscouldbegreatagainforthingsthathavelongfinals.
Ifyou'regoingtodoandyou'regoingthroughanddoing a lotofmodifications, a lotofedits, youforgetwhatthehellyouwerejustworkingonoragain, likelikeoneofthebigproblems.
Whatifyou'reworkingonthewrongPHPdonand I fileyou'reworkingonthatandyousitthereandyou'reworking, you'retryingtofigureoutwhysomething's notworking.
You'relike, Oh, I wonderif I wasworkingontherightpHbehind I fileandyougoandyoucoulddotheseamen.
Youknow, wheneveritwasyoumodifiedthatthat I have I letyougo.