Skip to content

Commit 3900be0

Browse files
committed
docs(readme): add migration instructions
Added a new section to the README with instructions for running database migrations using the `migrate` commands. Included details for both standard and fresh migrations, as well as a note about the migration reset behavior. This helps new contributors set up the database schema before starting the service.
1 parent 69129cc commit 3900be0

1 file changed

Lines changed: 14 additions & 0 deletions

File tree

README.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,20 @@ To set up your environment variables:
3030

3131
Make sure to replace placeholder values with actual data where necessary.
3232

33+
### Running Migrations
34+
35+
Before starting the service, you need to run the database migrations to set up the necessary tables and schema. The project uses `migrate` for managing database migrations.
36+
37+
```bash
38+
go run main.go migrate:up
39+
```
40+
Or if you want to run with seeder you can run this command
41+
42+
```bash
43+
go run main.go migrate:fresh
44+
```
45+
But it will be down your migration first
46+
3347
### Running the Service
3448

3549
To run `lms-be` on your local machine, you have two options:

0 commit comments

Comments
 (0)