Skip to content

Commit

Permalink
Merge pull request #50 from Shopify/v0-5-0
Browse files Browse the repository at this point in the history
Bump to version 0.5.0
  • Loading branch information
dphm authored Nov 30, 2023
2 parents fa58e24 + 5fa77ae commit 4816796
Show file tree
Hide file tree
Showing 7 changed files with 50 additions and 7 deletions.
4 changes: 2 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion example/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ edition = "2021"
license = "MIT"

[dependencies]
shopify_function = { path = "../shopify_function", version = "0.4.0" }
shopify_function = { path = "../shopify_function", version = "0.5.0" }
serde = { version = "1.0.13", features = ["derive"] }
serde_json = "1.0"
graphql_client = "0.13.0"
2 changes: 1 addition & 1 deletion example_with_targets/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ edition = "2021"
license = "MIT"

[dependencies]
shopify_function = { path = "../shopify_function", version = "0.4.0" }
shopify_function = { path = "../shopify_function", version = "0.5.0" }
serde = { version = "1.0.13", features = ["derive"] }
serde_json = "1.0"
graphql_client = "0.13.0"
4 changes: 4 additions & 0 deletions example_with_targets/a.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,8 @@ query Input {
id
num
name
date
dateTime
dateTimeWithoutTimezone
timeWithoutTimezone
}
39 changes: 39 additions & 0 deletions example_with_targets/schema.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,34 @@ Only allow the field to be queried when targeting one of the specified targets.
"""
directive @restrictTarget(only: [String!]!) on FIELD_DEFINITION

"""
Represents an [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)-encoded date string.
For example, September 7, 2019 is represented as `"2019-07-16"`.
"""
scalar Date

"""
Represents an [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)-encoded date and time string.
For example, 3:50 pm on September 7, 2019 in the time zone of UTC (Coordinated Universal Time) is
represented as `"2019-09-07T15:50:00Z`".
"""
scalar DateTime

"""
A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that
includes the date and time but not the timezone which is determined from context.
For example, "2018-01-01T00:00:00".
"""
scalar DateTimeWithoutTimezone

"""
A signed decimal number, which supports arbitrary precision and is serialized as a string.
Example values: `"29.99"`, `"29.999"`.
"""
scalar Decimal

"""
Represents a unique identifier, often used to refetch an object.
The ID type appears in a JSON response as a String, but it is not intended to be human-readable.
Expand All @@ -16,6 +44,13 @@ Example value: `"gid://shopify/Product/10079785100"`
"""
scalar ID

"""
A subset of the [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format that
includes the time but not the date or timezone which is determined from context.
For example, "05:43:21".
"""
scalar TimeWithoutTimezone

"""
A void type that can be used to return a null value from a mutation.
"""
Expand All @@ -28,6 +63,10 @@ type Input {
id: ID!
num: Int
name: String
date: Date
dateTime: DateTime
dateTimeWithoutTimezone: DateTimeWithoutTimezone
timeWithoutTimezone: TimeWithoutTimezone
targetAResult: Int @restrictTarget(only: ["test.target-b"])
}

Expand Down
4 changes: 2 additions & 2 deletions shopify_function/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "shopify_function"
version = "0.4.0"
version = "0.5.0"
edition = "2021"
authors = ["Surma <[email protected]>", "Delta Pham <[email protected]>"]
license = "MIT"
Expand All @@ -10,7 +10,7 @@ description = "Crate to write Shopify Functions in Rust."
serde = { version = "1.0.13", features = ["derive"] }
serde_json = "1.0"
anyhow = "1.0.62"
shopify_function_macro = { version = "0.4.0", path = "../shopify_function_macro" }
shopify_function_macro = { version = "0.5.0", path = "../shopify_function_macro" }

[dev-dependencies]
graphql_client = "0.13.0"
2 changes: 1 addition & 1 deletion shopify_function_macro/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "shopify_function_macro"
version = "0.4.0"
version = "0.5.0"
edition = "2021"
authors = ["Surma <[email protected]>", "Delta Pham <[email protected]>"]
license = "MIT"
Expand Down

0 comments on commit 4816796

Please sign in to comment.