nest-knexjs 0.0.29 → 0.0.31

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 (3) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +44 -62
  3. package/package.json +16 -23
package/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2021-2025 Tony133
3
+ Copyright (c) 2021-2026 Tony133
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
package/README.md CHANGED
@@ -1,71 +1,57 @@
1
- <p align="center">
2
- <a href="http://nestjs.com/" target="blank"><img src="https://nestjs.com/img/logo-small.svg" width="200" alt="Nest Logo" /></a>
3
- </p>
4
-
5
- [circleci-image]: https://img.shields.io/circleci/build/github/nestjs/nest/master?token=abc123def456
6
- [circleci-url]: https://circleci.com/gh/nestjs/nest
7
-
8
- <p align="center">A progressive <a href="http://nodejs.org" target="_blank">Node.js</a> framework for building efficient and scalable server-side applications.</p>
9
- <p align="center">
10
- <a href="https://www.npmjs.com/~nestjscore" target="_blank"><img src="https://img.shields.io/npm/v/@nestjs/core.svg" alt="NPM Version" /></a>
11
- <a href="https://www.npmjs.com/~nestjscore" target="_blank"><img src="https://img.shields.io/npm/l/@nestjs/core.svg" alt="Package License" /></a>
12
- <a href="https://www.npmjs.com/~nestjscore" target="_blank"><img src="https://img.shields.io/npm/dm/@nestjs/common.svg" alt="NPM Downloads" /></a>
13
- <a href="https://circleci.com/gh/nestjs/nest" target="_blank"><img src="https://img.shields.io/circleci/build/github/nestjs/nest/master" alt="CircleCI" /></a>
14
- <a href="https://coveralls.io/github/nestjs/nest?branch=master" target="_blank"><img src="https://coveralls.io/repos/github/nestjs/nest/badge.svg?branch=master#9" alt="Coverage" /></a>
15
- <a href="https://discord.gg/G7Qnnhy" target="_blank"><img src="https://img.shields.io/badge/discord-online-brightgreen.svg" alt="Discord"/></a>
16
- <a href="https://opencollective.com/nest#backer" target="_blank"><img src="https://opencollective.com/nest/backers/badge.svg" alt="Backers on Open Collective" /></a>
17
- <a href="https://opencollective.com/nest#sponsor" target="_blank"><img src="https://opencollective.com/nest/sponsors/badge.svg" alt="Sponsors on Open Collective" /></a>
18
- <a href="https://paypal.me/kamilmysliwiec" target="_blank"><img src="https://img.shields.io/badge/Donate-PayPal-ff3f59.svg"/></a>
19
- <a href="https://opencollective.com/nest#sponsor" target="_blank"><img src="https://img.shields.io/badge/Support%20us-Open%20Collective-41B883.svg" alt="Support us"></a>
20
- <a href="https://twitter.com/nestframework" target="_blank"><img src="https://img.shields.io/twitter/follow/nestframework.svg?style=social&label=Follow"></a>
21
- </p>
22
- <!--[![Backers on Open Collective](https://opencollective.com/nest/backers/badge.svg)](https://opencollective.com/nest#backer)
23
- [![Sponsors on Open Collective](https://opencollective.com/nest/sponsors/badge.svg)](https://opencollective.com/nest#sponsor)-->
1
+ # nest-knexjs
2
+
3
+ > Warning - This package will no longer be supported in the future
24
4
 
25
5
  ## Description
26
6
 
27
- Knexjs module for Nest framework (node.js) 😻
7
+ Knexjs module for Nest framework (node.js)
28
8
 
29
9
  ## Installation
30
10
 
31
11
  First install the module via `yarn` or `npm` or `pnpm` and do not forget to install the driver package as well:
32
12
 
33
-
34
13
  ```bash
35
- $ npm i --save nest-knexjs knex mysql # for mysql/mariadb
36
- $ npm i --save nest-knexjs knex pg # for postgresql
37
- $ npm i --save nest-knexjs knex sqlite # for sqlite
38
- $ npm i --save nest-knexjs knex oracledb # for oracledb
14
+ npm i --save nest-knexjs knex mysql # for mysql/mariadb
15
+ npm i --save nest-knexjs knex pg # for postgresql
16
+ npm i --save nest-knexjs knex sqlite # for sqlite
17
+ npm i --save nest-knexjs knex oracledb # for oracledb
39
18
  ```
19
+
40
20
  or
41
21
 
42
22
  ```bash
43
- $ yarn add nest-knexjs knex mysql # for mysql/mariadb
44
- $ yarn add nest-knexjs knex pg # for postgresql
45
- $ yarn add nest-knexjs knex sqlite # for sqlite
46
- $ yarn add nest-knexjs knex oracledb # for oracledb
23
+ yarn add nest-knexjs knex mysql # for mysql/mariadb
24
+ yarn add nest-knexjs knex pg # for postgresql
25
+ yarn add nest-knexjs knex sqlite # for sqlite
26
+ yarn add nest-knexjs knex oracledb # for oracledb
47
27
  ```
48
- or
28
+
29
+ or
49
30
 
50
31
  ```bash
51
- $ pnpm add nest-knexjs knex mysql # for mysql/mariadb
52
- $ pnpm add nest-knexjs knex pg # for postgresql
53
- $ pnpm add nest-knexjs knex sqlite # for sqlite
54
- $ pnpm add nest-knexjs knex oracledb # for oracledb
32
+ pnpm add nest-knexjs knex mysql # for mysql/mariadb
33
+ pnpm add nest-knexjs knex pg # for postgresql
34
+ pnpm add nest-knexjs knex sqlite # for sqlite
35
+ pnpm add nest-knexjs knex oracledb # for oracledb
55
36
  ```
56
37
 
57
38
  ## Table of Contents
58
39
 
59
- - [Description](#description)
60
- - [Table of Contents](#table-of-contents)
61
- - [Usage](#usage)
62
- - [KnexModule](#knexmodule)
63
- - [ExampleOfUse](#example-of-use)
64
- - [MultiConnectionsDatabase](#multi-connections-database)
65
- - [CreateMigrations](#create-migrations)
66
- - [RunMigrations](#run-migrations)
67
- - [CreateSeeds](#create-seeds)
68
- - [RunSeeds](#run-seeds)
40
+ - [nest-knexjs](#nest-knexjs)
41
+ - [Description](#description)
42
+ - [Installation](#installation)
43
+ - [Table of Contents](#table-of-contents)
44
+ - [Usage](#usage)
45
+ - [KnexModule](#knexmodule)
46
+ - [Example of use](#example-of-use)
47
+ - [Multi Connections Database](#multi-connections-database)
48
+ - [Create Migrations](#create-migrations)
49
+ - [Run Migrations](#run-migrations)
50
+ - [Create Seeds](#create-seeds)
51
+ - [Run Seeds](#run-seeds)
52
+ - [Contribute](#contribute)
53
+ - [License](#license)
54
+
69
55
  ## Usage
70
56
 
71
57
  ### KnexModule
@@ -90,6 +76,7 @@ KnexModule is the primary entry point for this package and can be used synchrono
90
76
  ],
91
77
  })
92
78
  ```
79
+
93
80
  or asynchronously
94
81
 
95
82
  ```typescript
@@ -270,7 +257,6 @@ export class UsersService {
270
257
  }
271
258
  ```
272
259
 
273
-
274
260
  In `knexfile.js` update with your database configuration settings:
275
261
 
276
262
  ```javascript
@@ -313,16 +299,16 @@ module.exports = {
313
299
  Run Migrations:
314
300
 
315
301
  ```bash
316
- $ npx knex migrate:latest --env development
302
+ npx knex migrate:latest --env development
317
303
 
318
- $ npx knex migrate:latest --env developmentTwo
304
+ npx knex migrate:latest --env developmentTwo
319
305
  ```
320
306
 
321
307
  ## Create Migrations
322
308
 
323
309
  ```bash
324
- $ npx knex init
325
- $ npx knex migrate:make [name_migrations]
310
+ npx knex init
311
+ npx knex migrate:make [name_migrations]
326
312
  ```
327
313
 
328
314
  Example file migrations:
@@ -365,16 +351,16 @@ module.exports = {
365
351
  }
366
352
  ```
367
353
 
368
- then we run the following command from the terminal
354
+ then we run the following command from the terminal
369
355
 
370
356
  ```bash
371
- $ npx knex migrate:latest
357
+ npx knex migrate:latest
372
358
  ```
373
359
 
374
360
  ## Create Seeds
375
361
 
376
362
  ```bash
377
- $ npx knex seed:make [name_seed]
363
+ npx knex seed:make [name_seed]
378
364
  ```
379
365
 
380
366
  Example file seeds
@@ -396,18 +382,14 @@ exports.seed = function (knex) {
396
382
  ## Run Seeds
397
383
 
398
384
  ```
399
- $ npx knex seed:run
385
+ npx knex seed:run
400
386
  ```
401
387
 
402
388
  For more information on `Knex.js` see [here](http://knexjs.org/)
403
389
 
404
390
  ## Contribute
405
- Feel free to help this library, I'm quite busy with also another Nestjs packages, but the community will appreciate the effort of improving this library. Make sure you follow the guidelines
406
391
 
407
- ## Stay in touch
408
-
409
- - Author - [Tony133](https://github.com/Tony133)
410
- - Framework - [https://nestjs.com](https://nestjs.com/)
392
+ Feel free to help this library, I'm quite busy with also another Nestjs packages, but the community will appreciate the effort of improving this library. Make sure you follow the guidelines
411
393
 
412
394
  ## License
413
395
 
package/package.json CHANGED
@@ -1,8 +1,7 @@
1
1
  {
2
2
  "name": "nest-knexjs",
3
- "version": "0.0.29",
4
- "description": "Knexjs module for Nest framework (node.js) 😻",
5
- "author": "Tony133",
3
+ "version": "0.0.31",
4
+ "description": "Knexjs module for Nest framework (node.js)",
6
5
  "license": "MIT",
7
6
  "scripts": {
8
7
  "build": "rm -rf dist && tsc -p tsconfig.json",
@@ -15,40 +14,38 @@
15
14
  "test:e2e": "jest --config ./tests/jest-e2e.json --detectOpenHandles --forceExit",
16
15
  "test:e2e:dev": "jest --config ./tests/jest-e2e.json --runInBand --watch",
17
16
  "prerelease": "npm run build",
18
- "release": "release-it",
19
17
  "prepare": "husky"
20
18
  },
21
19
  "devDependencies": {
22
- "@commitlint/cli": "20.2.0",
23
- "@commitlint/config-angular": "20.2.0",
20
+ "@commitlint/cli": "20.4.2",
21
+ "@commitlint/config-angular": "20.4.2",
24
22
  "@eslint/eslintrc": "3.3.3",
25
- "@eslint/js": "9.39.2",
26
- "@nestjs/common": "11.1.9",
27
- "@nestjs/core": "11.1.9",
28
- "@nestjs/platform-fastify": "11.1.9",
29
- "@nestjs/testing": "11.1.9",
23
+ "@eslint/js": "9.39.3",
24
+ "@nestjs/common": "11.1.14",
25
+ "@nestjs/core": "11.1.14",
26
+ "@nestjs/platform-fastify": "11.1.14",
27
+ "@nestjs/testing": "11.1.14",
30
28
  "@types/jest": "30.0.0",
31
- "@types/node": "24.10.3",
29
+ "@types/node": "24.10.13",
32
30
  "@types/supertest": "6.0.3",
33
- "eslint": "9.39.2",
31
+ "eslint": "9.39.3",
34
32
  "eslint-config-prettier": "10.1.8",
35
33
  "eslint-plugin-import": "2.32.0",
36
- "eslint-plugin-prettier": "5.5.4",
37
- "globals": "16.5.0",
34
+ "eslint-plugin-prettier": "5.5.5",
35
+ "globals": "17.3.0",
38
36
  "husky": "9.1.7",
39
37
  "jest": "30.2.0",
40
38
  "knex": "3.1.0",
41
39
  "mysql": "2.18.1",
42
- "prettier": "3.7.4",
40
+ "prettier": "3.8.1",
43
41
  "reflect-metadata": "0.2.2",
44
- "release-it": "19.1.0",
45
42
  "rxjs": "7.8.2",
46
- "supertest": "7.1.4",
43
+ "supertest": "7.2.2",
47
44
  "ts-jest": "29.4.6",
48
45
  "ts-node": "10.9.2",
49
46
  "tsconfig-paths": "4.2.0",
50
47
  "typescript": "5.9.3",
51
- "typescript-eslint": "8.49.0"
48
+ "typescript-eslint": "8.56.0"
52
49
  },
53
50
  "peerDependencies": {
54
51
  "@nestjs/common": "^9.0.0 || ^10.0.0 || ^11.0.0",
@@ -59,9 +56,5 @@
59
56
  },
60
57
  "lint-staged": {
61
58
  "**/*.{ts,json}": []
62
- },
63
- "repository": {
64
- "type": "git",
65
- "url": "https://github.com/tony133/nestjs-knexjs"
66
59
  }
67
60
  }