netlify / git-gateway

A Gateway to Git APIs
MIT License
404 stars 89 forks source link

'git-gateway migrate' command will now actually migrate #64

Closed KatamariJr closed 2 years ago

KatamariJr commented 3 years ago

- Summary

Fixes #25. migrate command would do nothing except Dial the sql connection and hang up. It now calls db.Automigrate() explicitly.

Dial does potentially call Automigrate() if you have the right environment variables set, but if you are explicitly attempting to migrate then you shouldn't need to set any other variables.

- Test plan

All tests pass, and the db tables all get created. Tested with sqlite3 and mysql.

- Description for the changelog

git-gateway migrate command will now function as expected.

- A picture of a cute animal (not mandatory but encouraged) 🐮

CamilleScholtz commented 2 years ago

Could this be merged?

mraerino commented 2 years ago

sorry about the messed up history, something was weird with that merge