Skip to content

Commit

Permalink
stripe_* to async-stripe-* crate naming
Browse files Browse the repository at this point in the history
  • Loading branch information
mzeitlin11 committed Jul 7, 2024
1 parent 8dff545 commit 4efa17a
Show file tree
Hide file tree
Showing 1,278 changed files with 496 additions and 462 deletions.
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,9 @@ to run `cargo fmt` to make sure it conforms to the standard.
This library is (mostly) authored via code generation by parsing the OpenAPI specification for Stripe.
It consists of 3 main pieces:
- `async-stripe`: The definition of the `Stripe` client
- `stripe_types`: Core type definitions, used a ton in generated code
- `async-stripe-types`: Core type definitions, used a ton in generated code
- `generated/*`: Generated crates which implement `Stripe` API requests and related types.
- `stripe_webhook`: Glue code for parsing and validating `Stripe` webhook events and generated
- `async-stripe-webhook`: Glue code for parsing and validating `Stripe` webhook events and generated
code for deserializing the events themselves.

No changes should be made to code in a `generated/*` folder. If you'd like to change that
Expand Down
10 changes: 5 additions & 5 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
[workspace]
members = [
"stripe_types",
"stripe_webhook",
"async-stripe-types",
"async-stripe-webhook",
"tests",
"generated/*",
"examples/*",
"stripe_client_core",
"async-stripe-client-core",
"async-stripe",
"stripe_async_std"
"async-stripe-async-std"
]

# Skip "examples/*" when running default commands since that adds a bunch of deps that makes
# development feedback loop slower.
default-members = ["async-stripe", "stripe_types", "stripe_webhook", "stripe_client_core", "generated/*", "stripe_async_std"]
default-members = ["async-stripe", "async-stripe-types", "async-stripe-webhook", "async-stripe-client-core", "generated/*", "async-stripe-async-std"]
resolver = "2"
# Makes dependency management simpler to allow codegen crate to use whichever dep versions
# it wants without affecting dependency resolution of the user-facing library crates
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[package]
name = "stripe_async_std"
name = "async-stripe-async-std"
version.workspace = true
description.workspace = true
rust-version.workspace = true
Expand All @@ -13,18 +13,21 @@ keywords.workspace = true
categories.workspace = true
edition.workspace = true

[lib]
name = "stripe_async_std"

[dependencies]
async-std = { version = "1.12.0" }
http-types = { version = "2.12.0", default-features = false }
surf = { version = "2.1" }
thiserror = "1.0.58"
miniserde.workspace = true
bytes = "1.6.0"
stripe_shared = { path = "../generated/stripe_shared" }
stripe_client_core = { path = "../stripe_client_core" }
async-stripe-shared = { path = "../generated/async-stripe-shared" }
async-stripe-client-core = { path = "../async-stripe-client-core" }

[features]
uuid = ["stripe_client_core/uuid"]
uuid = ["async-stripe-client-core/uuid"]

[dev-dependencies]
serde.workspace = true
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[package]
name = "stripe_client_core"
name = "async-stripe-client-core"
version.workspace = true
description.workspace = true
rust-version.workspace = true
Expand All @@ -13,9 +13,12 @@ keywords.workspace = true
categories.workspace = true
edition.workspace = true

[lib]
name = "stripe_client_core"

[dependencies]
stripe_shared = { path = "../generated/stripe_shared" }
stripe_types = { path = "../stripe_types" }
async-stripe-shared = { path = "../generated/async-stripe-shared" }
async-stripe-types = { path = "../async-stripe-types" }
serde_json.workspace = true
serde.workspace = true
serde_qs.workspace = true
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
5 changes: 4 additions & 1 deletion stripe_types/Cargo.toml → async-stripe-types/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[package]
name = "stripe_types"
name = "async-stripe-types"
version.workspace = true
description.workspace = true
edition.workspace = true
Expand All @@ -11,6 +11,9 @@ repository.workspace = true
keywords.workspace = true
categories.workspace = true

[lib]
name = "stripe_types"

[dependencies]
serde.workspace = true
smol_str.workspace = true
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
17 changes: 10 additions & 7 deletions stripe_webhook/Cargo.toml → async-stripe-webhook/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[package]
name = "stripe_webhook"
name = "async-stripe-webhook"
version.workspace = true
description.workspace = true
edition.workspace = true
Expand All @@ -11,9 +11,12 @@ repository.workspace = true
keywords.workspace = true
categories.workspace = true

[lib]
name = "stripe_webhook"

[dependencies]
stripe_types = { path = "../stripe_types" }
stripe_shared = { path = "../generated/stripe_shared" }
async-stripe-types = { path = "../async-stripe-types" }
async-stripe-shared = { path = "../generated/async-stripe-shared" }
hmac = "0.12"
sha2 = "0.10"
hex = "0.4"
Expand All @@ -22,12 +25,12 @@ thiserror = "1.0.24"
miniserde.workspace = true
serde.workspace = true

stripe_core = { path = "../generated/stripe_core", optional = true }
stripe_checkout = { path = "../generated/stripe_checkout", optional = true }
stripe_billing = { path = "../generated/stripe_billing", optional = true }
async-stripe-core = { path = "../generated/async-stripe-core", optional = true }
async-stripe-checkout = { path = "../generated/async-stripe-checkout", optional = true }
async-stripe-billing = { path = "../generated/async-stripe-billing", optional = true }

[dev-dependencies]
serde_json.workspace = true

[package.metadata.docs.rs]
features = ["stripe_core", "stripe_checkout", "stripe_billing"]
features = ["async-stripe-core", "async-stripe-checkout", "async-stripe-billing"]
File renamed without changes.
Loading

0 comments on commit 4efa17a

Please sign in to comment.