ESPHome Code Versioning with git

Hi,
wich is the best way to version ESPHome node code with git, without interferencing with ESPHome? I use ESPHome HA addon latest version for both.

Many Thanks in Advance

You may be able to do something using the method linked below: