staticSearch
staticSearch copied to clipboard
We should make `<versionFile>` mandatory and specify options for its behaviour
As suggested by @joeytakeda on #115:
I think empty
<versionFile/>
should just be "I don't want a version extension" and<versionFile>VERSION</versionFile>
(where VERSION doesn't actually exist) would be "I don't care what it is, so just make it for me"; otherwise, there's no way that someone could decide not to have VERSION'd files. In terms of what we'd generate as the version, we could just do [a-z0-9] (to avoid any potential conflicts). And since we're using Saxon 10, we can userandom-number-generator()
to generate a unique six character version code (I hadn't had a chance to use it yet, but just played around with it and it's great. Would send a xsltfiddle, but neither xsltfiddle nor xquery fiddle has support for Saxon 10 at the moment apparently).
This would go along with making the element mandatory in the schema.
The fix for issue #305 merged today into dev is an interim fix pending what we decide to do on this ticket.
Decisions:
-
<versionFile>
should be mandatory - If
<versionFile>
is empty, random string is generated - If
<versionFile>
is not empty, but can't find the file, then random string is generated - If
<versionFile>
is not empty and it can find the file and it has content:- Replace spaces with nothing
- Take the first 64 characters of this — but recommend shorter versions in the documentation
- Remove the automatic Git VERSION creation from the test build
- Make the documentation point to EDITION file for its own build