Answer the question
In order to leave comments, you need to log in
How to make sql dump to folder from localhost before commit in windows?
I’m making a small self-written site, php + mysql, I’m already tired of the database manually every time I come home to forget at work ... I’m
already looking to place the database somewhere on the hosting even ..
is there any way to put the database dump in the specified folder and commit the changes?
I know how to do it in linux but how to do it in windows?
p.s. i only use git bash and phpstorm
Answer the question
In order to leave comments, you need to log in
Pavel, I will offer you a completely different option. ;)
It is obvious that the contents of the database you use for testing. You want to get a database with consistent and familiar data at any time in order to continue working.
I don’t know if you are using any framework or not, but if you are making a site not quite on your knee, then look at the documentation on the word Seed.
The suggestion is to write a seeder that will populate your database with consistent data. You will know for sure that everything is fine in the database and will add new data to the seeder as the project develops.
Thus, you will not need a dump, because. at any time you can create a consistent base from scratch.
As an example, the link to the Laravel doc:https://laravel.com/docs/5.7/seeding
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question