Skip to content

Commit 22eca60

Browse files
authored
Cleanup migrations (#240)
1 parent 79f3315 commit 22eca60

File tree

2 files changed

+1
-21
lines changed

2 files changed

+1
-21
lines changed

migrations/Version20201103191534.php

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,10 @@
77
use Doctrine\DBAL\Schema\Schema;
88
use Doctrine\Migrations\AbstractMigration;
99

10-
/**
11-
* Auto-generated Migration: Please modify to your needs!
12-
*/
1310
final class Version20201103191534 extends AbstractMigration
1411
{
15-
public function getDescription() : string
16-
{
17-
return '';
18-
}
19-
2012
public function up(Schema $schema) : void
2113
{
22-
// this up() migration is auto-generated, please modify it to your needs
2314
$this->addSql('CREATE SEQUENCE task_id_seq INCREMENT BY 1 MINVALUE 1 START 1');
2415
$this->addSql('CREATE TABLE task (id INT NOT NULL, repository_full_name VARCHAR(255) NOT NULL, number INT NOT NULL, action INT NOT NULL, created_at TIMESTAMP(0) WITHOUT TIME ZONE NOT NULL, updated_at TIMESTAMP(0) WITHOUT TIME ZONE NOT NULL, verify_after TIMESTAMP(0) WITHOUT TIME ZONE NOT NULL, PRIMARY KEY(id))');
2516
$this->addSql('COMMENT ON COLUMN task.created_at IS \'(DC2Type:datetime_immutable)\'');
@@ -29,7 +20,6 @@ public function up(Schema $schema) : void
2920

3021
public function down(Schema $schema) : void
3122
{
32-
// this down() migration is auto-generated, please modify it to your needs
3323
$this->addSql('DROP SEQUENCE task_id_seq CASCADE');
3424
$this->addSql('DROP TABLE task');
3525
}

migrations/Version20201112220914.php

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -7,20 +7,10 @@
77
use Doctrine\DBAL\Schema\Schema;
88
use Doctrine\Migrations\AbstractMigration;
99

10-
/**
11-
* Auto-generated Migration: Please modify to your needs!
12-
*/
1310
final class Version20201112220914 extends AbstractMigration
1411
{
15-
public function getDescription(): string
16-
{
17-
return '';
18-
}
19-
2012
public function up(Schema $schema): void
2113
{
22-
// this up() migration is auto-generated, please modify it to your needs
23-
2414
$this->addSql(<<<SQL
2515
create table lock_keys
2616
(
@@ -36,6 +26,6 @@ public function up(Schema $schema): void
3626

3727
public function down(Schema $schema): void
3828
{
39-
// this down() migration is auto-generated, please modify it to your needs
29+
$this->throwIrreversibleMigrationException();
4030
}
4131
}

0 commit comments

Comments
 (0)