Skip to content

Commit 2e6ab7c

Browse files
authored
Make whoami optional, and only pull it in for postgres (launchbadge#1571)
sqlx-core uses whoami to provide the fallback for postgres username. If not building postgres support, omit the dependency on whoami.
1 parent f2b3cc8 commit 2e6ab7c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

sqlx-core/Cargo.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ postgres = [
3232
"futures-util/sink",
3333
"json",
3434
"dirs",
35+
"whoami",
3536
]
3637
mysql = [
3738
"sha-1",
@@ -158,7 +159,7 @@ url = { version = "2.1.1", default-features = false }
158159
uuid = { version = "0.8.1", default-features = false, optional = true, features = ["std"] }
159160
webpki = { version = "0.21.0", optional = true }
160161
webpki-roots = { version = "0.21.0", optional = true }
161-
whoami = "1.0.1"
162+
whoami = { version = "1.0.1", optional = true }
162163
stringprep = "0.1.2"
163164
bstr = { version = "0.2.14", default-features = false, features = ["std"], optional = true }
164165
git2 = { version = "0.13.20", default-features = false, optional = true }

0 commit comments

Comments
 (0)