While I am launching vim under xp with the following command, I have to push ENTER Key to confirm it to quit. vim -c "argdo myScrip.vim" -c "saveas! newInputFile" -c "qal!l" myInputFile
If you can avoid me to put ENTER Key, I will thank you. On 20 nov, 10:13, epanda <[email protected]> wrote: > -c "saveas!" -c "qall"seems to work but it let vim opened into the cmd > window. > > On 20 nov, 08:42, epanda <[email protected]> wrote: > > > > > Thank you for all > > > Now can you respond to this post "sql commands from Vim" > > > Best Regards > > Thanks > > Epanda > > > On 20 nov, 00:02, Gary Johnson <[email protected]> wrote: > > > > On 2009-11-19, epanda wrote: > > > > Hi, > > > > > I am lauching vim by a batch into windows. > > > > > cd C:\Users\Admin\Documents\scripts > > > > vim -c "source C:\Users\Admin\Documents\scripts\myScript.vim" -c > > > > "argdo call Func()" -c "exec 'saveas '.expand('%%:p:h') . '\new_' . > > > > expand('%%:t')" -c q aFile > > > > > The calling func does well its job but vim is still opened after the > > > > job. I would like vim to be closed after the job. > > > > Note that I open aFile and save the result into new_aFile > > > > > I have got those errors : > > > > > Erreur détectée en traitant command line : > > > > E13: Le fichier existe déjà (ajoutez ! pour passer outre) > > > > That one is warning you that you are attempting to overwrite an > > > existing file. A new_aFile apparently already existed when you ran > > > your batch. If it's OK to overwrite it, change "saveas" to > > > "saveas!". > > > > > E37: Modifications non enregistrées (ajoutez ! pour passer outre) > > > > That one is warning you that you have modified aFile but not saved > > > those changes. That error happened because the saveas failed. If > > > you fix that problem, you shouldn't get this error either. To tell > > > vim to quit in spite of having unsaved changes, change "-c q" to > > > "-c q!". > > > > Regards, > > > Gary- Masquer le texte des messages précédents - > > > - Afficher le texte des messages précédents -- Masquer le texte des > > messages précédents - > > - Afficher le texte des messages précédents - --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_use" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~---
