2012-12-12 17 views
9

Utilizzo sempre :wq per salvare un file. Oggi, sono venuto a sapere che :x può essere usato per farlo. Ma non l'ho notato in alcun vi-tutorial o vi-quick-reference. C'è qualche differenza tra questi due comandi?Differenza tra wq e x in vi

risposta

18

Da

help :x 

    *:x* *:xit* 
:[range]x[it][!] [++opt] [file] 
      Like ":wq", but write only when changes have been 
      made. 
      When 'hidden' is set and there are more windows, the 
      current buffer becomes hidden, after writing the file. 
Problemi correlati