Loading page...Загружаем страницу...正在加载页面...
AtlasRepo

What happens to your manual edits when you run a code generator again?

Описание и применение

При повторном запуске генератора Jostraca пользователь может потерять ручные изменения, сохранить их или объединить. В тестах показано, что режим overwrite удаляет изменения, а merge сохраняет их, если они находятся в разных строках.

Задача

When a code generator is rerun, manual edits to generated files may be lost, preserved, or merged, leading to uncertainty about file consistency.

Результат

Jostraca correctly implements both overwrite and merge behaviors as documented. Overwrite removes manual edits; merge preserves them when changes are on different lines.

Рабочий процесс

  • Generate initial file with Jostraca.
  • Manually edit the file (add DEBUG=1).
  • Re-run generator with overwrite policy (write:true, merge:false).
  • Re-run generator with merge policy (write:true, merge:true).

Доказательства

I tested version 0.39.0 with a small configuration file, comparing overwrite and merge behaviour after adding a manual change. Both cases worked as documented.

Источник

After regeneration: PORT=9090 HOST=localhost

Источник

The resulting file contained: PORT=9090 HOST=localhost DEBUG=1

Источник

The documentation describes a three-way merge using the previous generated version as a baseline.

Источник

  • Дата записи: 2026-10-14T13:41:05.662Z