Вы можете использовать diff
для создания патча с новыми, старыми и конфликтующими файлами.
diff -Naur Libc-825 Libc-1044
Состояние флагов -N
обрабатывает отсутствующие файлы как новые, -a
все файлы являются текстовыми, -u
отображать строки до и после diff для облегчения идентификации и -r
рекурсивный. Затем вы можете применить патч к старому каталогу и получить объединенные результаты.
Оказывается, подход (, инициирующий переменную «$filesystem _root _dir» в верхней части файла и присваивающий ей одно значение для каждой конфигурации ),:
nginx: [emerg] "set" directive is not allowed here in /etc/nginx/nginx.conf:1
)Variables should not be used as template macros. Variables are evaluated in the run-time during the processing of each request, so they are rather costly compared to plain static configuration. Using variables to store static strings is also a bad idea. Instead, a macro expansion and "include" directives should be used to generate configs more easily and it can be done with the external tools, e.g. sed + make or any other common template mechanism.
http://nginx.org/en/docs/faq/variables_in_config.html
Я думал о генераторе шаблонов, но затраты намного превышают выгоды, поэтому я либо оставлю файлы немного другими в будущем.