[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Coverage check for data files inclusion in dist

From: Alan D. Salewski
Subject: Re: Coverage check for data files inclusion in dist
Date: Thu, 02 Jul 2009 08:16:10 -0400
User-agent: Mutt/1.5.13 (2006-08-11)

On Thu, Jul 02, 2009 at 12:15:22PM +0200, Christian Egli spake thus:
> Hi all
> I work in a project where we ship a lot of data files. These files sit
> in a subdirectory where lists them explicitly as follows:
> table_files = \
>       ar-ar-g1.utb \
>         ...
>       zh-tw.ctb
> tablesdir = $(datadir)/liblouis/tables
> tables_DATA = $(table_files)
> EXTRA_DIST = $(table_files)
> Now as we get a lot of these files contributed the maintenance of this
> list becoming hard to manage. There are currently around 120 entries.
> The main developer has been asking for some automated maintenance of
> this list. I read the entry about wildcards in the FAQ and generally
> agree with it, so I'd rather not generate the list in an automated way. 
> But as a compromise would it maybe be possible to have some form of
> coverage check that takes the table_files variable and checks if there
> are files in the directory that are not listed (aside from the obvious
> and Makefile)? Anyone have some code snippets to share? I
> checked gnulib but it doesn't seem to contain anything like that.
> Thanks
> Christian

Hi Christian,

This isn't a direct answer to your question, but an alternative approach
might be to have the developer lean on his editor to generate the list
in the

For example, using emacs, one could:

   * mark the region as the list of file names
   * C-w (`kill-region') to remove the current list contents
   * C-u M-! l s    |    s o r t    |    s e d - e ' s / $ /   \ \ / ' RET
   * jump to the last line of the file list and remove the extraneous backslash

It seems like an elaborate approach when written out as above, but in
practice it really roles right off the fingers.

I do this type of thing[0] on some projects that have a large number of
data files.


[0] The actual thing that I do invokes a find(1) wrapper script that
    lists all files in the current directory (-maxdepth 1), and the sed
    invocation is a bit more elaborate to clean it up and format it
    better, but the idea is the same.

a l a n   d.   s a l e w s k i             address@hidden
                        All that I can see
                  looks like a giant fishbowl....
                     Glass eyes' in backwards.
Generated from Haiku-O-Matic: 

reply via email to

[Prev in Thread] Current Thread [Next in Thread]