[mod] update

This commit is contained in:
Andy Bunce 2025-09-18 12:14:39 +01:00
parent 55233a3382
commit f499e888ae
11 changed files with 50989 additions and 220 deletions

24
scripts/update-sources.xq Normal file
View file

@ -0,0 +1,24 @@
(: update xq4 sources :)
declare variable $BASE:=file:base-dir() || "../";
declare variable $CAT:=(
{ "description":"XQ4 function catalog",
"src":"https://raw.githubusercontent.com/qt4cg/qtspecs/master/specifications/xpath-functions-40/src/function-catalog.xml",
"dest": "bundles/grammar/function-catalog.xml"},
{ "description":"XQ4 grammar",
"src":"https://raw.githubusercontent.com/GuntherRademacher/rex-parser-generator/refs/heads/main/docs/sample-grammars/XQuery-40.ebnf",
"dest": "bundles/grammar/XQuery-40.ebnf"}
);
declare function local:resolve($dest){
file:resolve-path($dest,$BASE)
};
declare function local:update($item as map(*)){
file:write-binary(
file:resolve-path($item?dest,$BASE),
fetch:binary($item?src)
)
};
$CAT!local:update(.)