Ukufuna amafayela ku-Linux

Ngenkathi isebenza kunoma iyiphi uhlelo lokusebenza, ngezinye izikhathi kunesidingo sokusebenzisa amathuluzi ukuze uthole ngokushesha ifayela elithile. Lokhu kubuye kusetshenziswe ku-Linux, ngakho ngezansi kuzocatshangwa zonke izindlela zokusesha amafayela kule OS. Kokubili amathuluzi wemenenja yefayela kanye nemiyalo esetshenziselwa "Isikhumbuzo".

Bheka futhi:
Qamba kabusha amafayela ku-Linux
Dala futhi ususe amafayela ku-Linux

Isiphetho

Uma udinga ukucacisa imingcele eminingi yokusesha ukuthola ifayela oyifunayo, umyalo thola kubalulekile. Ngaphambi kokucubungula konke ukuhluka kwayo, kufanelekile ukuhamba nge-syntax nezinketho. Iqukethe i-syntax elandelayo:

thola inketho yendlela

kuphi indlela - yilona lwemibhalo lapho kusesha khona. Kunezinketho ezintathu eziyinhloko zokucacisa indlela:

  • / - cinga ngezimpande kanye nezinkomba eziseduze;
  • ~ - cinga ngomhlahlandlela wasekhaya;
  • ./ - cinga ku-directory lapho umsebenzisi okwamanje etholakala khona.

Ungabuye ucacise indlela ngqo kwisiqondisi lapho ifayela kufanele khona.

Izinketho thola okuningi, futhi kubonga kubo ukuthi ungenza ukusetha ngokusesha okuguquguqukayo ngokubeka iziguquguquko ezidingekayo:

  • -name - ukuqhuba usesho, ngokusekelwe egameni lento okumele isetshenziswe;
  • -user - cinga amafayela angowomsebenzisi othize;
  • -group - ukucinga iqembu elithile labasebenzisi;
  • -perm - bonisa amafayela ngemodi yokufinyelela ecacisiwe;
  • -size n - cinga, ngokusekelwe ngobukhulu bezinto;
  • -mtime + n -n - cinga amafayela ashintshile ngaphezulu (+ n) noma ngaphansi (-na) izinsuku ezedlule;
  • -yodwa - cinga amafayela ohlobo oluthile.

Kunezinhlobo eziningi zezinto ezidingekayo futhi. Nasi uhlu lwazo:

  • b - vimba;
  • f - evamile;
  • p - ipayipi egama;
  • d - ikhathalogu;
  • l - isixhumanisi;
  • s - isokhethi;
  • c - umlingiswa.

Ngemuva kokuchazwa okuningiliziwe kwe-syntax nokukhethwa komyalo thola Ungaya ngqo ezibonisweni zokubonisa. Ngenxa yobuningi bezinketho zokusebenzisa umyalo, izibonelo ngeke zinikezwe zonke iziguquko, kodwa kuphela ezisebenzisekayo kakhulu.

Bheka futhi: Imiyalo edumile ku-"Terminal" Linux

Indlela 1: Sesha ngegama (inketho-igama)

Ngokuvamile, abasebenzisi basebenzisa lolu khetho ukucinga uhlelo. -namengakho ake siqale ngakho. Ake sihlole izibonelo ezimbalwa.

Sesha ngandiso

Ake sithi udinga ukuthola ifayela ngokunwetshwa ohlelweni ".xlsx"okukulo lwemibhalo I-Dropbox. Ukwenza lokhu, sebenzisa umyalo olandelayo:

thola / ekhaya / umsebenzisi / i-Dropbox-igama "* .xlsx" -print

Kusuka ku-syntax yayo, singasho ukuthi ukusesha kwenziwa ku-directory I-Dropbox ("/ ikhaya / umsebenzisi / i-Dropbox"), futhi into efunayo kumele ibe nesandiso ".xlsx". I-asterisk ibonisa ukuthi ukusesha kuzokwenziwa kuwo wonke amafayela walesi sandiso, hhayi ukubheka igama labo. "-print" ibonisa ukuthi imiphumela yokusesha izoboniswa.

Isibonelo:

Sesha ngegama lefayela

Isibonelo, ufuna ukuthola ku-directory "/ ekhaya" ifayela eliqanjwe "i-lumpics"kodwa isandiso salo asikwazi. Kulokhu, yenza okulandelayo:

thola ~ -name "lumpics *" -print

Njengoba ungabona, uphawu lusetshenziswe lapha. "~", okusho ukuthi ukusesha kuzokwenzeka kwirekhodi lasekhaya. Emva kokukhetha "-name" Igama lefayela oyifunayo ("i-lumpics *"). I-asterisk ekugcineni kusho ukuthi ukusesha kuzokwenzeka kuphela ngamagama, hhayi ukufaka isandiso.

Isibonelo:

Sesha ngegama lokuqala ngegama

Uma ukhumbule kuphela incwadi yokuqala igama eliqala ngayo igama, kukhona i-syntax ekhethekile yomyalo ezokusiza ukuthi uyithole. Isibonelo, ufuna ukuthola ifayela eliqala ngencwadi evela "g" kuze kube "l"futhi awukwazi ukuthi iyiphi isiqondisi esitholakala kuyo. Khona-ke udinga ukuqhuba umyalo olandelayo:

thola / -name "[g-l] *" -print

Ukubheka uphawu "/" oluza masinyane emva komyalo oyinhloko, ukucwaninga kuzoqhutshwa kusukela kwirekhodi lommpande, okungukuthi, kuyo yonke uhlelo. Ngaphezu kwalokho, ingxenye "[g-l] *" kusho ukuthi igama lokusesha lizoqala ngencwadi ethile. Esikhathini sethu kusuka "g" kuze kube "l".

Ngendlela, uma wazi isandiso sefayela, bese ulandela uphawu "*" angacacisa. Isibonelo, udinga ukuthola ifayela elifanayo, kodwa uyazi ukuthi linwetshwa ".odt". Khona-ke ungasebenzisa umyalo olandelayo:

thola / -name "[g-l] * odt" -print

Isibonelo:

Indlela 2: Ukusesha ngemodi yokufinyelela (ukhetho -i-inthanethi)

Ngezinye izikhathi kuyadingeka ukuthola into ongaziwa igama lakho, kodwa wazi ukuthi imodi yokufinyelela inayo. Khona-ke udinga ukusebenzisa le nketho "-perm".

Kuyinto elula ukuyisebenzisa, udinga nje ukucacisa indawo yokucinga nemodi yokufinyelela. Nasi isibonelo somyalo onjalo:

thola ~ -perm 775 -print

Okusho ukuthi, ukucwaningwa kuqhutshwa esigabeni sasekhaya, futhi izinto ozifunayo zizokwazi ukufinyelela. 775. Ungakwazi futhi ukubeka "uhlamvu" - "phambi kwale nombolo, khona-ke izinto ezitholakalayo zizoba nemigomo yemvume kusuka ku-zero kuya kwi-value ecacisiwe.

Indlela ye-3: Usesho ngezinketho zomsebenzisi noma zeqembu (-user and -group)

Kunoma iyiphi uhlelo lokusebenza kukhona abasebenzisi namaqembu. Uma ufuna ukuthola into eqondene nenye yalezi zigaba, ngakho-ke ungasebenzisa inketho "-user" noma "-group", ngokulandelana.

Sesha ifayela ngegama lomsebenzisi

Isibonelo, udinga ukuthola ku-directory I-Dropbox ifayela "Lampics", kodwa awukwazi ukuthi kubizwa ngani, futhi wazi kuphela ukuthi kungokomsebenzisi "umsebenzisi". Khona-ke udinga ukuqhuba umyalo olandelayo:

thola / umsebenzisi / umsebenzisi / i-Dropbox -user -print yomsebenzisi

Kulo myalo ucacise isiqondisi esidingekayo (/ ekhaya / umsebenzisi / i-Dropbox), kubonise ukuthi udinga ukucinga ifayela elinikezwe umsebenzisi (-user), futhi ubonise ukuthi iyiphi umsebenzisi leli fayela lingelabo (umsebenzisi).

Isibonelo:

Bheka futhi:
Indlela yokubuka uhlu lwabasebenzisi ku-Linux
Indlela yokwengeza umsebenzisi eqenjini ku-Linux

Sesha ifayela ngegama leqembu laso

Ukusesha ifayela eliseqenjini elithile kulula nje-nje kudingeka udlulisele esikhundleni. "-user" on option "-group" futhi ubonise igama laleli qembu:

thola / umgudu wezivakashi -print

Okungukuthi, uye wabonisa ukuthi ufuna ukuthola ifayela elivela eqenjini ohlelweni "isivakashi". Ukusesha kuzokwenzeka kulo lonke uhlelo, lokhu kuboniswa uphawu "/".

Indlela 4: Sesha ifayela ngohlobo lwayo (okukhethwa kukho)

Ukuthola into ethile ngohlobo oluthile lwe-Linux kulula, udinga nje ukucacisa okukhethwa kukho okufanele (-yodwa) bese uphawula uhlobo. Ekuqaleni kwalesi sihloko babhalwe ohlwini lonke uhlobo lwezinhlamvu ezingasetshenziselwa ukusesha.

Isibonelo, ufuna ukuthola wonke amafayela okuvimba ekuqondeni kwakho ekhaya. Kulesi simo, ithimba lakho lizobukeka kanje:

thola ~ -type b -print

Ngakho-ke, ubonise ukuthi usesha ngohlobo lwefayela, njengoba kuboniswe yi-option "-uphawu", bese unquma uhlobo lwayo ngokubeka uphawu lwefayela lokuvimba - "b".

Isibonelo:

Ngokufanayo, ungabonisa zonke izinkomba kulolu hlu oluthandayo ngokuthayipha umyalo "d":

thola / ekhaya / umsebenzisi -type d -print

Indlela yesi-5: Sesha ifayili ngosayizi (okukhethwa kukho)

Uma kusuka kulo lonke ulwazi mayelana nefayela owaziyo kuphela ubukhulu bayo, khona-ke lokhu kungase kube ngokwanele ukukuthola. Isibonelo, ufuna ukuthola ifayela le-120 MB kusiqondisi esithile ngokwenza lokhu okulandelayo:

thola / ekhaya / umsebenzisi / i-Dropbox -siza i-120M -print

Isibonelo:

Bheka futhi: Indlela yokuthola usayizi wefolda ku-Linux

Njengoba ubona, ifayela esiyidingayo litholakala. Kodwa uma ungazi ukuthi iyiphi isiqondisi esitholakala, ungasesha lonke uhlelo ngokucacisa isiqondisi somsuka ekuqaleni komyalo:

thola / -siza i-120M -print

Isibonelo:

Uma wazi usayizi wefayela cishe, khona-ke kuleli cala kukhona umyalo okhethekile. Udinga ukubhalisa ku "Isikhumbuzo" into efanayo, ngaphambi nje kokucacisa usayizi wefayela ufake uphawu "-" (uma udinga ukuthola amafayela amancane kunesayizi ecacisiwe) noma "+" (uma ubukhulu befayela elidingekayo bukhulu kunalokho okushiwo). Nasi isibonelo somyalo onjalo:

thola / ekhaya / umsebenzisi / i-Dropbox + 100M -print

Isibonelo:

Indlela 6: Ifayela lokusesha ngelanga lokushintsha (okukhethwa kukho-isikhathi esithile)

Kukhona amacala uma kulula kakhulu ukucinga ifayela ngedethi eguquliwe. Ku-Linux, inketho isetshenziswa. "-ngakholelwa". Kuyinto elula ukuyisebenzisa, sizocabangela konke kulesi sibonelo.

Ake sithi kufolda "Izithombe" sidinga ukuthola izinto eziguquliwe ezinsukwini ezingu-15 zokugcina. Nansi okudingeka ubhalise ku "Isikhumbuzo":

thola / ekhaya / umsebenzisi / izithombe -i-timetime -15 -print

Isibonelo:

Njengoba ubona, le nketho ayikhombisi kuphela amafayela ashintshile esikhathini esithile, kodwa futhi namafolda. Isebenza ngokuphambene - ungathola izinto ezashintshwa kamuva kunesikhathi esibekiwe. Ukwenza lokhu, faka uphawu phambi kwenani ledijithali. "+":

thola / ekhaya / umsebenzisi / Izithombe -mtime +10 -print

I-GUI

Isikrini esibonakalayo esibucayi senza kakhulu izimpilo zabasha abasanda kufaka ukusabalalisa kwe-Linux. Le ndlela yokusesha ifana kakhulu neyayisetshenziswa ku-Windows OS, nakuba ingenakuhlinzeka zonke izinzuzo ezinikezayo. "Isikhumbuzo". Kodwa izinto zokuqala kuqala. Ngakho-ke, ake sibheke ukuthi singakwenza kanjani ukusesha ifayela ku-Linux besebenzisa isikhombimsebenzisi esibonakalayo sesistimu.

Indlela 1: Sesha ngokusebenzisa imenyu yesistimu

Manje sizobuka indlela yokuthola amafayela ngokusebenzisa imenyu ye-Linux system. Izenzo zenzelwe ukusabalalisa kwe-Ubuntu 16.04 LTS, noma kunjalo, imfundo iyajwayelekile kubo bonke.

Bheka futhi: Indlela yokuthola ukuhanjiswa kwe-Linux

Ake sithi udinga ukuthola amafayela ohlelweni ngaphansi kwegama "Ngithole"Kukhona namafayela amabili ohlelweni: eyodwa kufomathi ".txt"futhi okwesibili ".odt". Ukuze uzithole, kufanele uqale uqhafaze isithonjana semenyu (1)futhi ngokukhethekile insimu yokufaka (2) ucacise umbuzo wosesho "Ngithole".

Umphumela wokusesha uboniswa, ubonisa amafayela oyifunayo.

Kodwa uma kunamafayela amaningi kulesi simiso futhi zonke ziyizandiso ezihlukile, ukusesha kuyoba nzima nakakhulu. Ukuze ukhiphe amafayela angadingekile, isibonelo, izinhlelo, ekukhiqizeni imiphumela, kungcono ukusebenzisa isihlungi.

Itholakala ngakwesokudla imenyu. Ungakwazi ukuhlunga ngezindlela ezimbili: "Izigaba" futhi "Imithombo". Nweba lezi zinhlu ezimbili ngokuchofoza umcibisholo obhekene negama, futhi kwimenyu, susa ukhetho kusuka ezintweni ezingadingekile. Kulesi simo, kungaba ukuhlakanipha ukushiya kuphela ukuseshwa "Amafayela namafolda", njengoba sifuna ngqo amafayela.

Ungakwazi ukuphawula ngokushesha ukungabi nalutho kwalendlela - awukwazi ukulungisa imifanekiso ngokuningiliziwe, njengangaphakathi "Isikhumbuzo". Ngakho-ke, uma ufuna idokhumenti yombhalo ngegama elithile, ungabonisa izithombe, amafolda, amarekhodi, njll kumkhiqizo. Kodwa uma wazi igama eliqondile lefayela oyidingayo, ungayithola ngokushesha ngaphandle kokufunda izindlela eziningi umyalo "thola".

Indlela 2: Sesha ngokusebenzisa imenenja yefayela

Indlela yesibili inenzuzo enkulu. Ukusebenzisa ithuluzi lemenenja yefayela, ungasesha kuhla lwemibhalo ecacisiwe.

Yenza lo msebenzi lula. Udinga kumphathi wefayela, ku-Nautilus yethu, ukufaka ifolda lapho ifayela oyifunayo kufanele libe khona, bese uchofoza "Sesha"ekhoneni elingenhla elingakwesokudla kwewindi.

Enkambu yokufaka efakiwe udinga ukungena igama lefayela elilinganisiwe. Futhi ungakhohlwa ukuthi ukusesha kungenziwa ngegama lonke lefayela, kodwa kuphela ngengxenye yalo, njengoba kuboniswe kusibonelo ngezansi.

Njengendlela yangaphambilini, ngale ndlela ungasebenzisa isihlungi. Ukuze uyivule, chofoza inkinobho ngesibonakaliso "+"itholakala engxenyeni efanele yenkambu yokungena yombuzo wokucinga. I-submenu ivula lapho ungakhetha khona uhlobo lwefayili olufunayo ukusuka ohlwini lokudonsa phansi.

Isiphetho

Kusukela kulokhu okushiwo ngaphambili, kungaphetha ngokuthi indlela yesibili, eboshwe ekusebenziseni isikhombimsebenzisi esibonakalayo, iphelele ekuqhubeni okusesheshayo ngokusebenzisa uhlelo. Uma udinga ukusetha imingcele eminingi yokusesha, khona-ke umyalo uzoba obalulekile thola ku "Isikhumbuzo".