sqlx icon indicating copy to clipboard operation
sqlx copied to clipboard

CLi: made cli-lib modules publicly available for other crates

Open silvestrpredko opened this issue 7 months ago • 2 comments

Made modules database, metadata, ... publicly available for users that want to include sqlx-cli into their own helper binary or other library. (It's easier to use migrate::run directly without building Opt).

PR doesn't contain any significant changes.

silvestrpredko avatar Jun 03 '25 14:06 silvestrpredko

sqlx-cli is not meant to be used as a library. I don't want to have to think of downstream API users when making changes to it.

abonander avatar Jun 05 '25 01:06 abonander

sqlx-cli is not meant to be used as a library. I don't want to have to think of downstream API users when making changes to it.

There is nothing wrong with opening these modules; even if there will be breaking changes, it's not a problem for the project, I think.

For now, I want to have a custom behaviour for certain operations with migration revert, and I need to write all the logic for the rest of the CLI by myself, or build a whole Opt.

silvestrpredko avatar Jun 05 '25 12:06 silvestrpredko