vim Lesson 2.5 , 2.6 , 2.7 , Lesson Summary
Thohi
Contributor
2 min read
Lesson 2.5: USING A COUNT TO DELETE MORE
**operator နှင့်အတူ နံပါတ်များထည့်၍ သုံးခြင်း**
delete operator နဲ့ motion တွေသုံးတာကိုအထက်မှာပြပြီးခဲ့သည့်အတိုင်းလုပ်ဆောင်မှုအပြင် နံပါတ်များကို motion အရှေ့မှာထည့်၍အသုံးပြုနိုင်ပါသည်။
d number motion
၁။ –> this ABC DE line FGHI JK LMN OP of words is Q RS TUV cleaned up. ဒီစာလေးရိုက်ကြည့်လိုက်ပါ။
၂။ cursor ကို စာလုံးအကြီးတွေနဲ့ရိုက်ထားတဲ့စာလုံးတွေရှေ့ပို့လိုက်ပါ။
၃။ ထို့နောက် စာလုံး၂ လုံးဖကျ်ခငျ်လျှင် d2w command ရိုက်ပါ။ ၄လုံးဖကျ်ခငျ်လျှင် d4w ရိုက်ပါ။ စာကြောင်းလေးဒီလိုဖြစ်အောင်ရိုက်ကြည့်ပါ။
–> this line of words is cleaned up.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lesson 2.6: OPERATING ON LINES
** dd command သုံး၍ စာတကြောင်းလုံးဖကျ်ခြင်း**
ဒီစာကြောင်းလေးတွေရိုက်ကြည့်ပါ။
–> 1) Roses are red,
–> 2) Mud is fun,
–> 3) Violets are blue,
–> 4) I have a car,
–> 5) Clocks tell time,
–> 6) Sugar is sweet,
–> 7) And so are you.
၁။ ပြီးရင် cursor ကို –>2) ရှေ့မှာထားပါ။
၂။ dd command ကိုရိုက်လိုက်ပါ။
၃။ ပြီးရင် cursor ကို –>4) ရှေ့မှာထားလိုက်ပါ။
၄။ 2dd command ကိုရိုက်လိုက်ပါ။
အဖြေတွေမှာပါ။
Rose are red
Violets are blue
Sugar is sweet
And so are you .
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lesson 2.7: THE UNDO COMMAND
** နောက်ဆုံး command ကို undo လုပ်ရန် u ကိုသုံး ၊ U ကတော့ တကြောင်းလုံးပြင်ခဲ့သမျှကို undo လုပ်**
၁။ –> Fiix the errors oon thhis line and reeplace them witth undo. ဒီစာလေးရိုက်ကြည့်ပါ။
၂။ မှားနတေဲ့ စာလုံးတှရှေေ့မှာ cursor ကိုခပျြီး ပြင်ကြည့်ရအောင်။
၃။ မလိုတဲ့ character တလုံးခြင်းရှေ့မှာ cursor ခပျြီး x နဲ့ဖကျ်ရအောင်။
၄။ u command ရိုက်လိုက်ရင် ဖကျ်ထားတာတွေ undo ဖြစ်နေပါလိမ့်မယ်။
၅။ အခုတခါ မှားနတောတှကေို x ရိုက်ပြီးပြန်ပြင်ပါ။
၆။ ပြီးရင် U = (shift+u) ရိုက်လိုက်တာနဲ့ နဂိုအရင်အတိုင်း တကြောင်းလုံးပြန်ဖြစ်နေပါမယ်။
၇။ redo အတွက်ကတော့ Ctrl+r command နဲ့ ပြုလုပ်နိုင်ပါတယ်။
ဒီ command တွေကတော့ အသုံးဝင်တဲ့ အသုံးများတဲ့ command တှပေါ။
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lesson 2 SUMMARY
၁။ cursor မှနေ၍ နောက်စာလုံးထိဖကျ်လျှင် dw
၂။ cursor မှ စာကြောင်းအဆုံးထိဖကျ်လျှင် d$
၃။ စာတကြောင်းလုံးဖကျ်လျှင် dd
၄။ motion တွေကို အကြိမ်ရေတိုးလုပ်လိုလျှင် နံပါတ်တတ် 2w
၅။ command တွေအတွက် format ကတော့
operator [ number ] motion
ဒီနရောမှာ
– operator က ဘာလုပ်စေခငျ်တာ ဥပမာ d က delete
– [ number ] က motion ကို ဘယ်လောက်ထိ လုပ်စေခငျ်လည်းဆိုတာ
– motion ကတော့ text ရဲ့ ဘယ်နားလောက်ထိရှေ့မယ်ဆိုတာရွေးတာပါ။ w (word) , $ ( to the end of line) , စသည်ဖြင့် လုပ်ဆောင်ပါတယ်။
၆။ စာကြောင်းရဲ့ အစကိုရှေ့ခငျ်လျှင် zero (0) နှိပ်ပါ။
၇။ undo ပြန်လုပ်ရန် u (lowercase)
စာကြောင်းတခုလုံး ပြောင်းလဲမှုကို undo ပြန်လုပ်ရန် U (capital)
redo လုပ်ရန်ကတော့ Ctrl+r ပါ။
Related posts
3.Working with Ubuntu,All the applications you need
13.04 version အတှကျရေးထားပွီး ဘယျမှာမှ မတငျထားမိတာ အခုဒီနရောမှာ တငျလိုကျပါတယျ။ manual ဘာသာပွနျမယျဆိုပွီး ယူထားတဲ့ အပိုငျးထဲကပါ။ ဖတျရတာ အဆငျမပွလြှေငျတော့ ဘာသာပွနျတာ အားနညျးလို့ပါ။…
4 min read
vim Lesson 5.1 ,5.2 , 5.3 , 5.4 , summary
Lesson 5.1: HOW TO EXECUTE AN EXTERNAL COMMAND \ \ :! နောက်မှာ command ရိုက်ပြီးအသုံးပြုခြင်း။ \ \ ၁။ : (column) ဆိုတဲ့ သုံးနေကြ command ရိုက်လိုက်လျှင် screen ရဲ့အောက်မှာ cursor…
2 min read
vim Lesson 4.1 , 4.2 , 4.3 , 4.4 , Summary
Lesson 4.1: CURSOR LOCATION AND FILE STATUS \ \ Ctrl+g နှိပ်လျှင် သင့်ဖိုင်ရဲ့ နေရာနဲ့ဖိုင်အခြေအနေကိုပြသပါမည်။ လိုင်းနံပါတ်နှိပ်ပြီးရင် G (shift+g) နှိပ်ပါက…
3 min read
