Fresh production baseline [skip ci]

This commit is contained in:
DuneRealms 2026-11-27 23:43:05 +00:00
commit 0a11a18274

View file

@ -0,0 +1,8 @@
import {MASTER_KEY_TEMPLATES} from '../control-panel/public/jarvis-master-keys.mjs';
import {readFileSync,writeFileSync} from 'node:fs';import {createHash} from 'node:crypto';
export function devRequestCatalogue(){
return {schemaVersion:1,sourceHash:createHash('sha256').update(readFileSync(new URL('../control-panel/public/jarvis-master-keys.mjs',import.meta.url),'utf8').replaceAll('\r\n','\n')).digest('hex'),actions:MASTER_KEY_TEMPLATES.flatMap(t=>t.actions.map(a=>({id:a.id,label:t.label+' · '+a.label,version:a.version,keyType:a.keyType,fields:a.fields,effect:a.effect||'',fixedTargets:a.fixedTargets||[],webIssue:a.webIssue===true,recordOnly:a.recordOnly===true})))};
}
if(process.argv[1]&&import.meta.url.endsWith('/'+process.argv[1].replaceAll('\\','/').split('/').pop())){
const data=JSON.stringify(devRequestCatalogue(),null,2)+'\n';if(process.argv[2])writeFileSync(process.argv[2],data);else process.stdout.write(data);
}