|
From: | Jack Bates |
Subject: | Keeping Makefile.am in sync with Git repository |
Date: | Fri, 19 Sep 2014 11:23:25 -0700 |
User-agent: | Mozilla/5.0 (X11; Linux i686; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 |
http://nottheoilrig.com/autotidy/201409190/autotidy Does something similar already exist?Everyone on our project is comfortable adding/removing files from Git but the Makefile.am-s sometimes get overlooked or new project members are unfamiliar with Automake. Now if a file is removed from the repository but not from a Makefile.am the script rewrites the Makefile.am, dropping the file from it as well. If a file is added to the repository the script also adds it to the appropriate Makefile.am's EXTRA_DIST variable. This isn't always the correct edit: Sometimes it should get added to a different primary or sometimes the file isn't to be distributed. The script takes a configurable list of files which aren't distributed. On one hand we now have another list of files to keep up-to-date, just shifting the problem, but we're more commonly adding/removing files that are distributed, so the list of files which aren't changes less frequently than the Makefile.am-s. Also the script hopefully gets the developer's attention whereupon she can intervene with a better edit, whereas without it, forgetting to distribute a new file can sometimes go unnoticed for a long time.
[Prev in Thread] | Current Thread | [Next in Thread] |