Skip to content

Commit

Permalink
Test
Browse files Browse the repository at this point in the history
  • Loading branch information
Lucas Bozzo authored and Lucas Bozzo committed Apr 28, 2024
1 parent e111e59 commit 224aeab
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
1 change: 0 additions & 1 deletion .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ jobs:
node-version: 20
cache: 'npm'
- run: npm ci
- run: npm run db:generate
- run: npm run db:migrate
env:
TURSO_DATABASE_URL: ${{ secrets.TURSO_DATABASE_URL }}
Expand Down
13 changes: 9 additions & 4 deletions src/data/migrate.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
// migrate.ts

import { config } from 'dotenv';
import { migrate } from 'drizzle-orm/libsql/migrator';
import { createDbConnection } from './index';
Expand All @@ -13,10 +15,13 @@ const main = async () => {
});
console.log('Migration complete!');
} catch (error) {
console.error('Migration failed');
console.error(error);
console.log(error);
}
process.exit(1);
process.exit(0);
};

main();
main().catch((e) => {
console.error('Migration failed');
console.error(e);
process.exit(1);
});

0 comments on commit 224aeab

Please sign in to comment.