commit melhorias sgf

This commit is contained in:
2026-11-11 09:00:17 +02:00
parent 0b05a1192c
commit 1d11a5e57b
736 changed files with 40746 additions and 210 deletions
+10
View File
@@ -0,0 +1,10 @@
<?php
$book=$argv[1]??'regression';require __DIR__.'/sgf-single-bootstrap.php';
$p=App\Shared\Installation\SyntheticProfiles::policy();
$beforeUsers=$host->table('users')->orderBy('id')->get()->toJson();$beforeClients=$host->table('a_clients')->orderBy('id')->get()->toJson();
file_put_contents($work.'/before-users-private.json',$beforeUsers);
$result=(new App\Shared\Installation\SyntheticProfiles)->install();
if($beforeClients!==$host->table('a_clients')->orderBy('id')->get()->toJson())throw new LogicException('Client preservation failed');
file_put_contents($s['root'].'/single-profiles.json',json_encode($result,JSON_PRETTY_PRINT|JSON_THROW_ON_ERROR));
file_put_contents($work.'/profiles-result.json',json_encode(['passed'=>true,'profiles'=>$result['profiles'],'replayed'=>$result['replayed'],'source_hash'=>$result['source_hash'],'old_clients_preserved'=>true,'real_access'=>false,'new_database_roles'=>0],JSON_PRETTY_PRINT|JSON_THROW_ON_ERROR));
echo json_encode(['passed'=>true,'book'=>$book,'profiles'=>count($result['profiles']),'replayed'=>$result['replayed'],'proof'=>$work.'/profiles-result.json']).PHP_EOL;