2.0.1 • Published 4 years ago

prismafire v2.0.1

Weekly downloads
1
License
ISC
Repository
github
Last release
4 years ago

Prismafire

Commitizen friendly License: ISC _

Purpose

This package aims to reduce the pain of writing all datamodels on the prisma.yml file. It will regenerate it with populating datamodels field by intropecting your project.

This is the default structure where prismafire will work with zero conf

├── src
│   └── prisma
│       └── datamodels
│           └── **/*.graphql
├── prisma.yml ( default input and default ouput )
└── package.json

Installation

npm install -D prismafire

Options

input

If your prisma.yml is elsewhere, you can specify --input to indicate where to fetch the file.

output

If your prisma.yml should be elsewhere, you can specify --output to indicate where to write the file.

glob

You can also set a different glob to match your datamodels fils through the --glob option

how to use it

scripts

I suggest adding this script on the package json :

{
    // ...
    "scripts": {
        // ...
        "prisma:deploy":"prismafire && prisma deploy ", // you can pass options after prismafire 
        // or with options ( ex with --glob)
        "prisma:deploy":"prismafire --glob custom/**.glob && prisma deploy ",  
    }
}

or

then run prisma deploy via the script.

This way, you'll trigger the hook to generate the prisma file before asking for deployment

2.0.1

4 years ago

2.0.0

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago

0.2.0

4 years ago

0.1.0

4 years ago

0.0.10

4 years ago

0.0.9

4 years ago

0.0.8

4 years ago

0.0.7

4 years ago

0.0.6

4 years ago

0.0.5

4 years ago

0.0.4

4 years ago

0.0.3

4 years ago

0.0.2

4 years ago

0.0.1

4 years ago