updateRelationshipsAfterMigration(); }); } private function updateRelationshipsAfterMigration(): void { try { // 논리적 관계 문서 자동 업데이트 Artisan::call('db:update-relationships'); // Git에 자동 커밋 (선택사항) if (config('database.auto_commit_relationships', false)) { $this->autoCommitRelationships(); } \Log::info('✅ 마이그레이션 후 논리적 관계 문서 업데이트 완료'); } catch (\Exception $e) { \Log::error('❌ 논리적 관계 문서 업데이트 실패: ' . $e->getMessage()); } } private function autoCommitRelationships(): void { $commands = [ 'git add LOGICAL_RELATIONSHIPS.md', 'git commit -m "docs: 마이그레이션 후 논리적 관계 자동 업데이트 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude "' ]; foreach ($commands as $command) { exec($command, $output, $returnCode); if ($returnCode !== 0) { \Log::warning("Git 명령 실행 실패: {$command}"); break; } } } }