Merge pull request #285 from Kijewski/pr-tomlfmt

Use cargo reference manifest section order
This commit is contained in:
Guillaume Gomez 2024-12-13 11:55:18 +01:00 committed by GitHub
commit 63a96256d3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
11 changed files with 62 additions and 39 deletions

View File

@ -1,8 +1,3 @@
[workspace] [workspace]
members = [ members = ["rinja", "rinja_derive", "rinja_parser", "testing"]
"rinja",
"rinja_derive",
"rinja_parser",
"testing",
]
resolver = "2" resolver = "2"

View File

@ -1,7 +1,3 @@
# In a real application you would not need this section. It is only used in here, so that this
# example can have a more lenient MSRV (minimum supported rust version) than rinja as a whole.
[workspace]
members = ["."]
[package] [package]
name = "actix-web-app" name = "actix-web-app"
@ -28,3 +24,8 @@ env_logger = "0.11.3"
log = "0.4.22" log = "0.4.22"
pretty-error-debug = "0.3.0" pretty-error-debug = "0.3.0"
thiserror = "2.0.3" thiserror = "2.0.3"
# In a real application you would not need this section. It is only used in here, so that this
# example can have a more lenient MSRV (minimum supported rust version) than rinja as a whole.
[workspace]
members = ["."]

View File

@ -1,6 +1,3 @@
[workspace]
members = [".", "fuzz"]
[package] [package]
name = "rinja_fuzzing" name = "rinja_fuzzing"
version = "0.1.0" version = "0.1.0"
@ -17,3 +14,6 @@ thiserror = "2.0.3"
[profile.release] [profile.release]
debug = 1 debug = 1
[workspace]
members = [".", "fuzz"]

1
rinja_derive/.rustfmt.toml Symbolic link
View File

@ -0,0 +1 @@
../.rustfmt.toml

View File

@ -17,12 +17,6 @@ rustdoc-args = ["--generate-link-to-definition", "--cfg=docsrs"]
[lib] [lib]
proc-macro = true proc-macro = true
[features]
code-in-doc = ["dep:pulldown-cmark"]
config = ["dep:serde", "dep:basic-toml", "parser/config"]
urlencode = []
serde_json = []
[dependencies] [dependencies]
parser = { package = "rinja_parser", version = "=0.3.5", path = "../rinja_parser" } parser = { package = "rinja_parser", version = "=0.3.5", path = "../rinja_parser" }
@ -44,6 +38,12 @@ prettyplease = "0.2.20"
similar = "2.6.0" similar = "2.6.0"
syn = { version = "2.0.3", features = ["full"] } syn = { version = "2.0.3", features = ["full"] }
[features]
code-in-doc = ["dep:pulldown-cmark"]
config = ["dep:serde", "dep:basic-toml", "parser/config"]
urlencode = []
serde_json = []
[lints.rust] [lints.rust]
# Used in `rinja_derive_standalone` which uses the same source folder, but is not a proc-macro. # Used in `rinja_derive_standalone` which uses the same source folder, but is not a proc-macro.
unexpected_cfgs = { level = "allow", check-cfg = ['cfg(feature, values("__standalone"))'] } unexpected_cfgs = { level = "allow", check-cfg = ['cfg(feature, values("__standalone"))'] }

1
rinja_derive/_typos.toml Symbolic link
View File

@ -0,0 +1 @@
../_typos.toml

1
rinja_derive/deny.toml Symbolic link
View File

@ -0,0 +1 @@
../deny.toml

1
rinja_derive/tomlfmt.toml Symbolic link
View File

@ -0,0 +1 @@
../tomlfmt.toml

View File

@ -1,5 +1,3 @@
[workspace]
members = ["."]
[package] [package]
name = "rinja_derive_standalone" name = "rinja_derive_standalone"
@ -17,14 +15,10 @@ publish = false
all-features = true all-features = true
rustdoc-args = ["--generate-link-to-definition", "--cfg=docsrs"] rustdoc-args = ["--generate-link-to-definition", "--cfg=docsrs"]
[features] [[bench]]
default = ["__standalone"] name = "derive-template"
__standalone = [] harness = false
required-features = ["__standalone"]
code-in-doc = ["dep:pulldown-cmark"]
config = ["dep:serde", "dep:basic-toml", "parser/config"]
urlencode = []
serde_json = []
[dependencies] [dependencies]
parser = { package = "rinja_parser", version = "=0.3.5", path = "../rinja_parser" } parser = { package = "rinja_parser", version = "=0.3.5", path = "../rinja_parser" }
@ -48,7 +42,14 @@ prettyplease = "0.2.20"
similar = "2.6.0" similar = "2.6.0"
syn = { version = "2.0.3", features = ["full"] } syn = { version = "2.0.3", features = ["full"] }
[[bench]] [features]
name = "derive-template" default = ["__standalone"]
harness = false __standalone = []
required-features = ["__standalone"]
code-in-doc = ["dep:pulldown-cmark"]
config = ["dep:serde", "dep:basic-toml", "parser/config"]
urlencode = []
serde_json = []
[workspace]
members = ["."]

View File

@ -17,8 +17,9 @@ rust-version = "1.80"
all-features = true all-features = true
rustdoc-args = ["--generate-link-to-definition", "--cfg=docsrs"] rustdoc-args = ["--generate-link-to-definition", "--cfg=docsrs"]
[features] [[bench]]
config = ["dep:serde"] name = "from_str"
harness = false
[dependencies] [dependencies]
memchr = "2" memchr = "2"
@ -28,6 +29,5 @@ winnow = "0.4"
[dev-dependencies] [dev-dependencies]
criterion = "0.5" criterion = "0.5"
[[bench]] [features]
name = "from_str" config = ["dep:serde"]
harness = false

View File

@ -1 +1,23 @@
table_order = ["workspace", "package", "badges", "lib", "features", "dependencies", "build-dependencies", "dev-dependencies", "bench"] # Keep in the same order as <https://doc.rust-lang.org/cargo/reference/manifest.html>
table_order = [
"package",
# targets
"lib",
"bin",
"example",
"test",
"bench",
# dependencies
"dependencies",
"dev-dependencies",
"build-dependencies",
"target",
# misc
"badges",
"features",
"lints",
"patch",
"replace",
"profile",
"workspace",
]