chore(): start moving some packages to the core directory (#7215)
This commit is contained in:
committed by
GitHub
parent
fdee748eed
commit
bbccd6481d
17
packages/cli/create-medusa-app/src/utils/postgres-client.ts
Normal file
17
packages/cli/create-medusa-app/src/utils/postgres-client.ts
Normal file
@@ -0,0 +1,17 @@
|
||||
import pg from "pg"
|
||||
const { Client } = pg
|
||||
|
||||
type PostgresConnection = {
|
||||
user?: string
|
||||
password?: string
|
||||
connectionString?: string
|
||||
database?: string
|
||||
}
|
||||
|
||||
export default async (connect: PostgresConnection) => {
|
||||
const client = new Client(connect)
|
||||
|
||||
await client.connect()
|
||||
|
||||
return client
|
||||
}
|
||||
Reference in New Issue
Block a user