https://github.com/mrowa44/yolo-cli
Easily drop & migrate local database
https://github.com/mrowa44/yolo-cli
Last synced: about 1 year ago
JSON representation
Easily drop & migrate local database
- Host: GitHub
- URL: https://github.com/mrowa44/yolo-cli
- Owner: mrowa44
- Created: 2017-04-03T15:22:49.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2018-01-06T14:48:40.000Z (over 8 years ago)
- Last Synced: 2025-03-27T07:21:19.605Z (about 1 year ago)
- Language: JavaScript
- Homepage:
- Size: 338 KB
- Stars: 4
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
yolo-cli
========
> Easily drop & migrate local database

wut?
----
I usually screw up my local database in development and end up dropping it and
migrating from scratch, which requires a lot of commands. I would normally
define an alias in my shell but that becomes a problem if I work on many
projects.
This package simplifies that by letting you define `yolo.js` file with
`drop`, `build` and `post` commands for each project.
It will look for `yolo.js` in parent directories if one isn't present in
current folder and run defined commands in sequence.
And it's pretty :sparkles:
Installation
------------
```bash
npm -g install yolo-cli
```
Usage
-----
Run `yolo init` in project root to initialize example `yolo.js` file and fill
it with proper commands.
Then you can run `yolo` in any project directory to rebuild database.
Example `yolo.js`
------------------
```js
module.exports = {
drop: 'dropdb yolo',
build: 'createdb yolo',
post: 'sequelize db:migrate',
};
```
License
-------
MIT © [Justyna Rachowicz](https://github.com/mrowa44)