On 03/07/2012 03:41 PM, Ulrich Mueller wrote:
*** Proposal 2: "EAPI in header comment" ***
A different approach would be to specify the EAPI in a specially
formatted comment in the ebuild's header. No syntax has been suggested
yet, but I believe that the following would work as a specification:
- The EAPI must be declared in a special comment in the first line of
the ebuild's header, as follows:
- The first line of the ebuild must contain the word "ebuild",
followed by whitespace, followed by the EAPI, followed by
end-of-line or whitespace.
Someone suggested using a standard shebang the last time this came up,
and if I remember correctly it was one of the least-disagreeable
solutions proposed. We could of course define our own custom format, but
I think something like,
#!/usr/bin/eapi5
would be perfect if we could hand off the interpretation of the ebuild
to that program. That solves the problem with new bash features, too,
since you could point that command at a specific version.