lilypond-user
[Top][All Lists]
Advanced

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

Re: [openlilylib] Rename 'snippet-' to 'module-'


From: Paul Morris
Subject: Re: [openlilylib] Rename 'snippet-' to 'module-'
Date: Fri, 18 Jul 2014 06:51:03 -0700 (PDT)

Urs Liska wrote
> Hi all openlilylib users,
> 
> when updating information on a few snippets (to test the documentation 
> generator) I think I realized something.
> 
> Currently we call the files we have ready for inclusion "snippets", 
> which is partially true but also a 'historic' thing.
> 
> But I think such a file can provide one of the following:
> 
> - one distinct object (e.g. function, shorthand, engraver, stylesheet)
>    that is available after inclusion
> - some functionality that is processed immediately on inclusion
> - a number of objects (e.g. functions) that are made available
>    through inclusion.
> 
> I think "snippet" doesn't match that list, and I suggest to rename it, 
> which would also make the library even more different from the LSR.
> 
> My suggestion is to think of the files as 'modules'. I think this is the 
> most consistent naming, also consistent with the use in programming 
> languages.
> Say I "include the module 'git-commands'", then I have the contained 
> commands availabe from within the LilyPond input file. If I "include a 
> module 'stylesheets/henle/concert/piano'" the included stylesheets are 
> immediately applied.

I agree that snippet is probably not the best word here.  Module seems ok to
me, but what about just calling them "files"?  That fits with the existing
language of "including files".  It would avoid any potential confusion about
the difference between "including modules" vs "including files," which are
the same thing here.  Calling them modules might be taken to imply that
there's something special about these files that makes them modules, when
they're actually just files like any other LilyPond file.


Urs Liska wrote
> This would imply changing the header field names from "snippet-title" to 
> "module-title" etc., meaning some more work when restructuring the 
> library. But I think it's worth the work.
> 
> What do you think?

I would suggest using "oll-" as the prefix for these header fields. 
(oll-title, oll-tags, oll-author, etc.)  It's shorter and it decouples the
field names from what we're calling these things, whether snippets, modules,
files, etc.

Cheers,
-Paul



--
View this message in context: 
http://lilypond.1069038.n5.nabble.com/openlilylib-Rename-snippet-to-module-tp164591p164611.html
Sent from the User mailing list archive at Nabble.com.



reply via email to

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