Mainos / Advertisement:

Ero sivun ”Vi/en” versioiden välillä

Kohteesta Taisto
Siirry navigaatioon Siirry hakuun
(Ak: Uusi sivu: == Basic commands ==)
(Ak: Uusi sivu: ESC and then :wq)
 
(9 välissä olevaa versiota samalta käyttäjältä ei näytetä)
Rivi 4: Rivi 4:
 
== Basic commands ==
 
== Basic commands ==
  
Avaa Vi tekstieditori komennolla
+
Open the vi text editor using the command
  
 
   vi  
 
   vi  
  
   vi "tiedosto"
+
   vi ''file''
  
Tiedosto avautuu yleensä lukutilaan. Pääset kirjoitustilaan:
+
In most cases the file will be opened in read state. You can access the write state with:
  
 
   i
 
   i
  
Tallenna tiedosto:
+
Save file:
  
   ESC ja sen jälkeen :w
+
   ESC and then :w
  
Sulje tiedosto tallentamatta:
+
Close file without saving:
  
   ESC ja sen jälkeen :q
+
   ESC and then :q
  
Sulje tiedosto ja tallenna
+
Close file and save:
  
   ESC ja sen jälkeen :wq
+
   ESC and then :wq

Nykyinen versio 23. heinäkuuta 2015 kello 07.47

Muut kielet:
English • ‎suomi

Vi is a commonly used text editor for Linux and comes installed by stock in various Linux based operating systems.

Basic commands

Open the vi text editor using the command

 vi 
 vi file

In most cases the file will be opened in read state. You can access the write state with:

 i

Save file:

 ESC and then :w

Close file without saving:

 ESC and then :q

Close file and save:

 ESC and then :wq
Mainos / Advertisement: