Linux ua qauv piv txwv

Hauv Linux operating systems, muaj ntau ntau yam hauv kev tsim hluav taws xob, kev sib txuas nrog uas yog siv los ntawm kev nkag mus rau cov lus txib tsim nyog "Terminal" nrog ntau nqe lus. Tsaug rau qhov no, tus neeg siv yuav tswj tus OS nws tus kheej, ntau yam tsis muaj thiab muaj cov ntaub ntawv. Ib ntawm cov paab nrov yog miv, thiab nws ua hauj lwm nrog rau cov ntaub ntawv ntawm cov ntaub ntawv sib txawv. Tom ntej no, peb xav pom ob peb tus qauv ntawm kev siv tsab ntawv no siv cov ntaub ntawv yooj yim.

Siv cov lus txib hauv Linux

Cov pab pawg neeg saib hnub no yog muaj rau txhua qhov kev faib tawm raws Linux cov ntsiav, thiab zoo nkaus li tib qhov txhia chaw. Vim li no, qhov kev siv ua yog sob. Hnub no tus qauv yuav raug coj los ntawm lub computer khiav Ubuntu 18.04, thiab koj tsuas yuav paub txog cov lus sib cav thiab cov qauv ntawm lawv cov yeeb yam.

Kev npaj ua

Ua ntej, kuv xav kom muab lub sij hawm los ua cov txheej txheem ua ntej, vim tsis yog txhua tus neeg paub txog txoj cai ntawm lub console. Qhov tseeb yog tias thaum qhib ib cov ntaub ntawv, koj yuav tsum qhia txog txoj kev qhia kiag rau nws, lossis khiav qhov kev hais kom ua, ua ncaj qha rau hauv nws tus kheej hauv "Terminal". Yog li, peb qhia koj tias koj yuav tsum pib saib daim ntawv qhia no:

  1. Khiav tus thawj tswj xyuas cov ntaub ntawv thiab rov qab mus rau qhov chaw uas cov ntaub ntawv tsim nyog tau muab tseg.
  2. Nias rau ntawm ib tus nrog rau txoj kev nas khawm thiab xaiv "Cov khoom".
  3. Hauv tab "Yooj Yim" Nyeem cov ntaub ntawv hais txog niam txiv lub npe. Nco ntsoov txoj kev no, vim nws yog ib qho tseem ceeb ntxiv.
  4. Khiav mus "Terminal" ntawm cov zaub mov los yog shortcut Ctrl + Alt + T.
  5. Sau npe pab neegcd / tsev / neeg / khoobqhov twg tus neeg siv - username, thiab nplaub tshev - nplaub tshev qhov khoom khaws tseg. Qhov kev hais ua tus qauv yog lub luag haujlwm rau txav raws txoj kev.cd.

Qhov no yog siv los mus rau ib lub npe ntawm ib tus qauv console. Lwm cov kev ua yuav ntxiv los ntawm daim nplaub tshev no.

Saib cov ntsiab lus

Ib qho ntawm cov haujlwm tseem ceeb ntawm cov lus hais saum toj no yog saib cov ntsiab lus ntawm ntau cov ntaub ntawv. Tag nrho cov lus qhia muaj nyob rau hauv cov kab cais hauv "Terminal"thiab daim ntawv thov miv zoo li no:

  1. Hauv lub console, saumiv testfileqhov twg testfile - lub npe ntawm cov ntaub ntawv yuav tsum tau, thiab tom qab ntawd nias tus yuam sij Sau.
  2. Nyeem cov ntsiab lus ntawm qhov khoom.
  3. Koj tuaj yeem qhib tau ntau cov ntaub ntawv ntawm ib zaug, rau qhov no koj yuav tsum qhia tag nrho lawv cov npe, piv txwv li,miv testfile testfile1.
  4. Cov hlua tuaj yeem muab sau ua ke thiab tshwm sim ua ib qho.

Qhov no yog qhov nws ua haujlwm li cas. miv tsis tas siv cov lus sib cav. Yog tias koj cia li sau rau hauv "Terminal"miv, koj yuav tau txais ib qho kev sib raug zoo nrog cov ntawv ceeb toom nrog lub peev xwm los sau cov xov tooj ntawm cov kab thiab khaws lawv los ntawm txhaj rau Ctrl + D.

Kab naj npawb

Tam sim no cia peb sib tham nrog pawg neeg nug txog ntau yam lus. Nws yuav tsum pib nrog tus lej ntawm cov kab, thiab yog lub luag hauj lwm rau qhov no-b.

  1. Nyob rau hauv lub console, saumiv -b testfileqhov twg testfile - lub npe ntawm yam khoom txaus siab.
  2. Raws li koj tau pom, tag nrho cov kab uas tsis yog khoob tam sim no raug suav.
  3. Koj tuaj yeem siv qhov kev sib cav no nrog cov zis ntawm ntau cov ntaub ntawv, raws li qhia saum toj no. Hauv qhov no, tus lej yuav ua mus ntxiv.
  4. Yog tias koj xav hais kom tag nrho cov kab, nrog rau cov khoom tsis muaj txhij, koj yuav tsum siv qhov kev sib cav-nthiab tom qab ntawd ces pab neeg no yuav siv daim ntawv:miv -n testfile.

Tshem tawm cov kab xev thij du

Nws tshwm sim hais tias nyob rau hauv ib daim ntawv muaj ib txheej ntawm cov kab tas uas tau tshwm sim hauv qee txoj kev. Manually Hmong Hmong los ntawm tus editor tsis yog yooj yim txhua lub sijhawm, yog li koj tuaj yeem tiv tauj tau qhov hais kom ua ntawm no. mivlos ntawm kev thov sib cav-S. Tom qab ntawd cov hlua yuav siv daim ntawvmiv-s testfile(kev sau npe ntawm ntau cov ntaub ntawv tseem muaj).

Ntxiv $ kos npe

Kos npe $ nyob rau hauv cov kab hais kom ua ntawm lub Linux operating systems, txhais tau hais tias cov lus txib nkag hauv qab no yuav raug tua sawv cev ntawm ib tus tib neeg siv, uas tsis tau muab cov cai-txoj cai. Qee lub sij hawm nws yog ib qho tsim nyog kom ntxiv qhov kos npe rau tag nrho cov kab ntawm cov ntaub ntawv, thiab qhov no koj yuav tsum tau thov-E. Qhov tshwm sim yogmiv -E testfile(tsab ntawv E yuav tsum tau muab sau ua lus qis dua).

Merge ntau cov ntaub ntawv rau hauv ib lub tshiab

Miv tso cai rau koj kom sai thiab yooj yim ua ke ntau yam khoom rau hauv ib lub tshiab, uas yuav tau txais kev cawm dim rau hauv tib daim ntawv teev los ntawm tag nrho cov kev ua. Koj tsuas yog yuav tsum tau ua cov hauv qab no:

  1. Nyob rau hauv lub console, saumiv testfile testfile1> testfile2(Cov npe ntawm lub npe ua ntej > tej zaum yuav unlimited). Tom qab nkag mus Sau.
  2. Qhib cov npe ntawm tus neeg saib xyuas cov ntaub ntawv thiab xa cov ntaub ntawv tshiab.
  3. Nws pom tias nws muaj tag nrho cov kab ntawm tag nrho cov teev cov ntaub ntawv.

Ob peb ntau nqe lus siv tsawg dua, tab sis lawv yuav tsum tau hais:

  • -v- muab cov qauv ntawm qhov chaw ua dej num nug;
  • -h- qhia txog kev pabcuam nrog cov ntaub ntawv yooj yim;
  • -T- ntxiv tabs tabs ua cim ^ Kuv.

Koj tau raug paub txog cov ntaub ntawv cov txheej txheem editing, uas tuaj yeem siv tau los sib koom ua ke cov ntawv nyeem cov ntaub ntawv lossis cov qauv ntaub ntawv. Txawm li cas los xij, yog tias koj xav tsim cov khoom tshiab, peb qhia koj kom xa mus rau peb cov tshooj cai ntawm qhov txuas nram qab no.

Nyeem ntxiv: Tsim thiab rho cov ntaub ntawv hauv Linux

Tsis tas li ntawd, muaj ntau tus nquag siv thiab nquag siv commands hauv Linux operating systems, kawm ntxiv txog lawv nyob rau hauv ib tsab xov xwm cais hauv qab no.

Saib kuj: Nquag Siv Commands hauv Linux Terminal

Tam sim no koj paub txog tus txheej txheem pab pawg. miv txhua yam uas yuav tuaj yeem ua ke thaum ua haujlwm "Terminal". Nws tsis muaj dab tsi nyuaj rau kev sib raug zoo nrog nws, qhov tseem ceeb tshaj plaws yog sib koom ua ke rau cov syntax thiab kev teev npe ntawm cov cwj pwm.