Although AEM stores the content in local file system organized in nodes, sometimes there maybe requirement to store or manage the content in your GIT. This may sound weird, but atleast for development (and QA) purposes this maybe useful.
Here are the steps:
Step 1: Create a project that has (we can use Archetype10 to build the folder structure)
Step 2: Manage this project “project-name” in Git
Step 3: As you know whatever components/content we add to the page “contactus” will append to “.content.xml”
How do we get the updates that we did on AEM into Git:
A) On local aem, whatever we add the content.. we can use either Brackets’ “import from server” (or ValutClipse in Eclipse) feature to get the updates into “.content.xml”
B) On dev/other servers.. we may have to create a package, bring it into local-aem, then into our local file system then push to GIT.