Skip to content

Commit

Permalink
Add Migration CI (#128)
Browse files Browse the repository at this point in the history
* feat: add migration workflow

* temp: only for testing

* is it this?

* maybe not

* am i stupid

* fallback

* cooked

* me brain is fried

* im a dumbass

* only run on main branch
  • Loading branch information
RishikeshNK authored Feb 9, 2025
1 parent 403fd76 commit a26a6d1
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 2 deletions.
2 changes: 2 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ Closes #[ticket<!--replace this with the GitHub Issue number-->]
- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] Database migration
- [ ] Ran `pnpm db:generate` and verified generated SQL migration files in `packages/db/drizzle`

## Checklist:

Expand Down
23 changes: 23 additions & 0 deletions .github/workflows/migration.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Migration

on:
push:
branches: ["main"]

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}

jobs:
migrate:
runs-on: ubuntu-latest
env:
POSTGRES_URL: ${{ secrets.POSTGRES_URL }}
steps:
- uses: actions/checkout@v4

- name: Setup
uses: ./tooling/github/setup

- name: Migrate
run: pnpm db:migrate
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
Cooper is a tool for Northeastern students to both submit reviews of their co-ops and filter through reviews of co-ops left by other students.

## The Cooper Docs
Read our docs [cooper-docs-sandboxney.verce.app](https://cooper-docs-sandboxneu.vercel.app/) !

Read our docs [cooper-docs-sandboxneu.vercel.app](https://cooper-docs-sandboxneu.vercel.app/) !

## Features

Expand Down
2 changes: 1 addition & 1 deletion turbo.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
},
"migrate": {
"cache": false,
"interactive": true
"interactive": false
},
"studio": {
"cache": false,
Expand Down

0 comments on commit a26a6d1

Please sign in to comment.