Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add nativeBindings option to better-sqlite3 options #5461

Merged
merged 3 commits into from
Mar 28, 2023

Conversation

beeequeue
Copy link
Contributor

I have a project where I'm bundling knex and better-sqlite3 into a single file and when running it the driver can't find the included binding file which is placed adjacent to the running file.

This can be fixed by setting new Database(path, { nativeBinding: "path/to/binding.node" }) but this is currently impossible to do with knex.

@kibertoad
Copy link
Collaborator

Is it possible to add test for this?

@coveralls
Copy link

Coverage Status

Coverage: 92.392%. Remained the same when pulling ece2587 on BeeeQueue:master into 0d27bcb on knex:master.

@undees
Copy link
Contributor

undees commented Mar 27, 2023

👍🏻 on this change because it also supports adding other better-sqlite3 options in later PRs (e.g., readonly).

Copy link
Collaborator

@OlivierCavadenti OlivierCavadenti left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you have made some documentation ? As soon as it's done, I will merge this.
@beeequeue

@undees
Copy link
Contributor

undees commented Mar 28, 2023

I don't mind putting together a quick docs PR.

@undees
Copy link
Contributor

undees commented Mar 28, 2023

PR open! knex/documentation#504. Happy to adjust the wording if needed.

@OlivierCavadenti OlivierCavadenti merged commit ac59ab7 into knex:master Mar 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants