Replace emoji/Unicode characters with ASCII in migration commands

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
root
2025-10-21 06:45:05 +00:00
parent d531c69c17
commit 9d44fcff55
8 changed files with 94 additions and 94 deletions

View File

@@ -20,7 +20,7 @@ class Migrate_Commit_Command extends Command
{
// Check if in migration mode
if (!file_exists($this->flag_file)) {
$this->error('⚠️ No migration session in progress!');
$this->error('[WARNING] No migration session in progress!');
$this->info('Nothing to commit.');
return 1;
}
@@ -28,13 +28,13 @@ class Migrate_Commit_Command extends Command
$session_info = json_decode(file_get_contents($this->flag_file), true);
$started_at = $session_info['started_at'] ?? 'unknown';
$this->info('📝 Migration session started at: ' . $started_at);
$this->info(' Migration session started at: ' . $started_at);
// Check for unran migrations
$this->info("\n🔍 Checking for unran migrations...");
$this->info("\n Checking for unran migrations...");
$unran_migrations = $this->check_unran_migrations();
if (!empty($unran_migrations)) {
$this->error(' Found unran migration files:');
$this->error('[ERROR] Found unran migration files:');
foreach ($unran_migrations as $migration) {
$this->error(' - ' . $migration);
}
@@ -44,17 +44,17 @@ class Migrate_Commit_Command extends Command
$this->warn(' 2. Remove the migration files');
return 1;
}
$this->info(' All migrations have been executed.');
$this->info('[OK] All migrations have been executed.');
// Run schema inspection in development mode
if (app()->environment() !== 'production') {
$this->info("\n🔍 Running database schema standards check...");
$this->info("\n Running database schema standards check...");
$checker = new SchemaQualityChecker();
$violations = $checker->check();
if ($checker->has_violations()) {
$this->error(' Schema standards check failed with ' . $checker->get_violation_count() . ' violation(s):');
$this->error('[ERROR] Schema standards check failed with ' . $checker->get_violation_count() . ' violation(s):');
$this->info('');
// Display violations
@@ -69,20 +69,20 @@ class Migrate_Commit_Command extends Command
}
$this->info('');
$this->error(' Rolling back migration session due to schema violations...');
$this->error('[ERROR] Rolling back migration session due to schema violations...');
// Execute rollback
$this->call('migrate:rollback');
$this->info('');
$this->warn('⚠️ Migration has been rolled back. Fix the schema violations and try again.');
$this->warn('[WARNING] Migration has been rolled back. Fix the schema violations and try again.');
return 1;
}
$this->info(' Schema standards check passed.');
$this->info('[OK] Schema standards check passed.');
}
$this->info("\n🔄 Committing migration changes...");
$this->info("\n Committing migration changes...");
try {
// Step 1: Remove backup directory
@@ -97,7 +97,7 @@ class Migrate_Commit_Command extends Command
// Success
$this->info('');
$this->info(' Migration changes committed successfully!');
$this->info('[OK] Migration changes committed successfully!');
$this->info('');
$this->line('• The backup has been deleted');
$this->line('• Migration mode has been disabled');
@@ -115,7 +115,7 @@ class Migrate_Commit_Command extends Command
return 0;
} catch (\Exception $e) {
$this->error(' Failed to commit: ' . $e->getMessage());
$this->error('[ERROR] Failed to commit: ' . $e->getMessage());
return 1;
}
}