@ttoss/postgresdb-cli 0.1.12 → 0.1.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/esm/index.js +45 -43
  2. package/package.json +1 -1
package/dist/esm/index.js CHANGED
@@ -3,13 +3,56 @@
3
3
  // src/index.ts
4
4
  import { Command } from "commander";
5
5
 
6
+ // package.json
7
+ var package_default = {
8
+ name: "@ttoss/postgresdb-cli",
9
+ version: "0.1.12",
10
+ description: "A library to handle PostgreSQL database actions through the command line",
11
+ license: "MIT",
12
+ author: "ttoss",
13
+ contributors: ["Pedro Arantes <pedro@arantespp.com> (https://arantespp.com)"],
14
+ repository: {
15
+ type: "git",
16
+ url: "https://github.com/ttoss/ttoss.git",
17
+ directory: "packages/postgresdb-cli"
18
+ },
19
+ type: "module",
20
+ bin: {
21
+ "ttoss-postgresdb": "./bin/cli.js"
22
+ },
23
+ files: ["bin", "dist"],
24
+ scripts: {
25
+ "build-config": "tsup-node"
26
+ },
27
+ sideEffects: false,
28
+ dependencies: {
29
+ commander: "^12.1.0",
30
+ dotenv: "^16.4.5",
31
+ esbuild: "^0.24.0",
32
+ "sequelize-erd": "^1.3.1"
33
+ },
34
+ devDependencies: {
35
+ "@ttoss/config": "workspace:^",
36
+ jest: "^29.7.0",
37
+ tsup: "^8.3.5"
38
+ },
39
+ keywords: ["database", "postgres", "postgresql"],
40
+ publishConfig: {
41
+ access: "public",
42
+ provenance: true
43
+ }
44
+ };
45
+
6
46
  // src/erd.ts
7
47
  import * as fs from "node:fs";
48
+ import sequelizeErd from "sequelize-erd";
8
49
 
9
50
  // src/getDbDynamically.ts
10
51
  import "dotenv/config";
11
- import * as esbuild from "esbuild";
52
+ import * as builtinModules from "node:module";
12
53
  import path from "node:path";
54
+ import * as esbuild from "esbuild";
55
+ var nodeBuiltins = builtinModules.builtinModules;
13
56
  var getDbDynamically = async ({
14
57
  dbPath
15
58
  }) => {
@@ -20,7 +63,7 @@ var getDbDynamically = async ({
20
63
  const result = esbuild.buildSync({
21
64
  bundle: true,
22
65
  entryPoints: [entryPoint],
23
- external: ["@ttoss/postgresdb"],
66
+ external: ["@ttoss/postgresdb", ...nodeBuiltins],
24
67
  format: "esm",
25
68
  outfile,
26
69
  platform: "node",
@@ -38,7 +81,6 @@ var getDbDynamically = async ({
38
81
  };
39
82
 
40
83
  // src/erd.ts
41
- import sequelizeErd from "sequelize-erd";
42
84
  var erd = async ({
43
85
  dbPath
44
86
  }) => {
@@ -73,46 +115,6 @@ var sync = async ({
73
115
  db.sequelize.close();
74
116
  };
75
117
 
76
- // package.json
77
- var package_default = {
78
- name: "@ttoss/postgresdb-cli",
79
- version: "0.1.11",
80
- description: "A library to handle PostgreSQL database actions through the command line",
81
- license: "MIT",
82
- author: "ttoss",
83
- contributors: ["Pedro Arantes <pedro@arantespp.com> (https://arantespp.com)"],
84
- repository: {
85
- type: "git",
86
- url: "https://github.com/ttoss/ttoss.git",
87
- directory: "packages/postgresdb-cli"
88
- },
89
- type: "module",
90
- bin: {
91
- "ttoss-postgresdb": "./bin/cli.js"
92
- },
93
- files: ["bin", "dist"],
94
- scripts: {
95
- "build-config": "tsup-node"
96
- },
97
- sideEffects: false,
98
- dependencies: {
99
- commander: "^12.1.0",
100
- dotenv: "^16.4.5",
101
- esbuild: "^0.24.0",
102
- "sequelize-erd": "^1.3.1"
103
- },
104
- devDependencies: {
105
- "@ttoss/config": "workspace:^",
106
- jest: "^29.7.0",
107
- tsup: "^8.3.5"
108
- },
109
- keywords: ["database", "postgres", "postgresql"],
110
- publishConfig: {
111
- access: "public",
112
- provenance: true
113
- }
114
- };
115
-
116
118
  // src/index.ts
117
119
  var program = new Command();
118
120
  program.name("ttoss-postgresdb").version(package_default.version).description("ttoss postgresdb CLI");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ttoss/postgresdb-cli",
3
- "version": "0.1.12",
3
+ "version": "0.1.13",
4
4
  "description": "A library to handle PostgreSQL database actions through the command line",
5
5
  "license": "MIT",
6
6
  "author": "ttoss",