mirror of
https://github.com/launchbadge/sqlx.git
synced 2025-12-30 05:11:13 +00:00
* feat: create `sqlx.toml` format * feat: add support for ignored_chars config to sqlx_core::migrate * chore: test ignored_chars with `U+FEFF` (ZWNBSP/BOM) https://en.wikipedia.org/wiki/Byte_order_mark * refactor: make `Config` always compiled simplifies usage while still making parsing optional for less generated code * refactor: add origin information to `Column` * feat(macros): implement `type_override` and `column_override` from `sqlx.toml` * refactor(sqlx.toml): make all keys kebab-case, create `macros.preferred-crates` * feat: make macros aware of `macros.preferred-crates` * feat: make `sqlx-cli` aware of `database-url-var` * feat: teach macros about `migrate.table-name`, `migrations-dir` * feat: teach macros about `migrate.ignored-chars` * chore: delete unused source file `sqlx-cli/src/migration.rs` * feat: teach `sqlx-cli` about `migrate.defaults` * feat: teach `sqlx-cli` about `migrate.migrations-dir` * feat: teach `sqlx-cli` about `migrate.table-name` * feat: introduce `migrate.create-schemas` * WIP feat: create multi-tenant database example * fix(postgres): don't fetch `ColumnOrigin` for transparently-prepared statements * feat: progress on axum-multi-tenant example * feat(config): better errors for mislabeled fields * WIP feat: filling out axum-multi-tenant example * feat: multi-tenant example No longer Axum-based because filling out the request routes would have distracted from the purpose of the example. * chore(ci): test multi-tenant example * fixup after merge * fix(ci): enable `sqlx-toml` in CLI build for examples * fix: CI, README for `multi-tenant` * fix: clippy warnings * fix: multi-tenant README * fix: sequential versioning inference for migrations * fix: migration versioning with explicit overrides * fix: only warn on ambiguous crates if the invocation relies on it * fix: remove unused imports * fix: doctest * fix: `sqlx mig add` behavior and tests * fix: restore original type-checking order * fix: deprecation warning in `tests/postgres/macros.rs` * feat: create postgres/multi-database example * fix: examples/postgres/multi-database * fix: cargo fmt * chore: add tests for config `migrate.defaults` * fix: sqlx-cli/tests/add.rs * feat(cli): add `--config` override to all relevant commands * chore: run `sqlx mig add` test with `RUST_BACKTRACE=1` * fix: properly canonicalize config path for `sqlx mig add` test * fix: get `sqlx mig add` test passing * fix(cli): test `migrate.ignored-chars`, fix bugs * feat: create `macros.preferred-crates` example * fix(examples): use workspace `sqlx` * fix: examples * fix(sqlite): unexpected feature flags in `type_checking.rs` * fix: run `cargo fmt` * fix: more example fixes * fix(ci): preferred-crates setup * fix(examples): enable default-features for workspace `sqlx` * fix(examples): issues in `preferred-crates` * chore: adjust error message for missing param type in `query!()` * doc: mention new `sqlx.toml` configuration * chore: add `CHANGELOG` entry Normally I generate these when cutting the release, but I wanted to take time to editorialize this one. * doc: fix new example titles * refactor: make `sqlx-toml` feature non-default, improve errors * refactor: eliminate panics in `Config` read path * chore: remove unused `axum` dependency from new examples * fix(config): restore fallback to default config for macros * chore(config): remove use of `once_cell` (to match `main`)
77 lines
2.8 KiB
TOML
77 lines
2.8 KiB
TOML
[package]
|
|
name = "sqlx-macros-core"
|
|
description = "Macro support core for SQLx, the Rust SQL toolkit. Not intended to be used directly."
|
|
version.workspace = true
|
|
license.workspace = true
|
|
edition.workspace = true
|
|
authors.workspace = true
|
|
repository.workspace = true
|
|
rust-version.workspace = true
|
|
|
|
[features]
|
|
default = []
|
|
|
|
# for conditional compilation
|
|
_rt-async-std = ["async-std", "sqlx-core/_rt-async-std"]
|
|
_rt-tokio = ["tokio", "sqlx-core/_rt-tokio"]
|
|
|
|
_tls-native-tls = ["sqlx-core/_tls-native-tls"]
|
|
_tls-rustls-aws-lc-rs = ["sqlx-core/_tls-rustls-aws-lc-rs"]
|
|
_tls-rustls-ring-webpki = ["sqlx-core/_tls-rustls-ring-webpki"]
|
|
_tls-rustls-ring-native-roots = ["sqlx-core/_tls-rustls-ring-native-roots"]
|
|
|
|
_sqlite = []
|
|
|
|
# SQLx features
|
|
derive = []
|
|
macros = []
|
|
migrate = ["sqlx-core/migrate"]
|
|
|
|
sqlx-toml = ["sqlx-core/sqlx-toml"]
|
|
|
|
# database
|
|
mysql = ["sqlx-mysql"]
|
|
postgres = ["sqlx-postgres"]
|
|
sqlite = ["_sqlite", "sqlx-sqlite/bundled"]
|
|
sqlite-unbundled = ["_sqlite", "sqlx-sqlite/unbundled"]
|
|
|
|
# type integrations
|
|
json = ["sqlx-core/json", "sqlx-mysql?/json", "sqlx-postgres?/json", "sqlx-sqlite?/json"]
|
|
|
|
bigdecimal = ["sqlx-core/bigdecimal", "sqlx-mysql?/bigdecimal", "sqlx-postgres?/bigdecimal"]
|
|
bit-vec = ["sqlx-core/bit-vec", "sqlx-postgres?/bit-vec"]
|
|
chrono = ["sqlx-core/chrono", "sqlx-mysql?/chrono", "sqlx-postgres?/chrono", "sqlx-sqlite?/chrono"]
|
|
ipnet = ["sqlx-core/ipnet", "sqlx-postgres?/ipnet"]
|
|
ipnetwork = ["sqlx-core/ipnetwork", "sqlx-postgres?/ipnetwork"]
|
|
mac_address = ["sqlx-core/mac_address", "sqlx-postgres?/mac_address"]
|
|
rust_decimal = ["sqlx-core/rust_decimal", "sqlx-mysql?/rust_decimal", "sqlx-postgres?/rust_decimal"]
|
|
time = ["sqlx-core/time", "sqlx-mysql?/time", "sqlx-postgres?/time", "sqlx-sqlite?/time"]
|
|
uuid = ["sqlx-core/uuid", "sqlx-mysql?/uuid", "sqlx-postgres?/uuid", "sqlx-sqlite?/uuid"]
|
|
|
|
[dependencies]
|
|
sqlx-core = { workspace = true, features = ["offline"] }
|
|
sqlx-mysql = { workspace = true, features = ["offline", "migrate"], optional = true }
|
|
sqlx-postgres = { workspace = true, features = ["offline", "migrate"], optional = true }
|
|
sqlx-sqlite = { workspace = true, features = ["offline", "migrate"], optional = true }
|
|
|
|
async-std = { workspace = true, optional = true }
|
|
tokio = { workspace = true, optional = true }
|
|
|
|
dotenvy = { workspace = true }
|
|
|
|
hex = { version = "0.4.3" }
|
|
heck = { version = "0.5" }
|
|
either = "1.6.1"
|
|
proc-macro2 = { version = "1.0.79", default-features = false }
|
|
serde = { version = "1.0.132", features = ["derive"] }
|
|
serde_json = { version = "1.0.73" }
|
|
sha2 = { version = "0.10.0" }
|
|
syn = { version = "2.0.52", default-features = false, features = ["full", "derive", "parsing", "printing", "clone-impls"] }
|
|
quote = { version = "1.0.26", default-features = false }
|
|
url = { version = "2.2.2" }
|
|
|
|
[lints.rust.unexpected_cfgs]
|
|
level = "warn"
|
|
# 1.80 will warn without this
|
|
check-cfg = ['cfg(sqlx_macros_unstable)', 'cfg(procmacro2_semver_exempt)']
|