A
A
arruah2017-01-12 19:04:19
vim
arruah, 2017-01-12 19:04:19

How to add one block of text to the end of a file in multiple files?

There is a multilingual project in which it is necessary to add or change some text over time. Localization is tied to the English text, so when the English text changes, you have to change this block in all localization files.
Is it possible in vim to append text to the end of a file in multiple files at the same time?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
N
nekipelov, 2017-01-17
@nekipelov

For example:
* bufdo - for all open buffers (you can use argdo, tabdo, windo)
* execute - execute the command
* normal - "normal" mode commands
* G - go to the end
* p - paste the text from the buffer (copied by the y command)

A
Andrey Burov, 2017-01-12
@BuriK666

echo "your text here" | tee -a *.txt

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question