diff --git a/.circleci/config.yml b/.circleci/config.yml index 6e5615f33..e136e6684 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -21,7 +21,7 @@ workflows: jobs: contract_cw721_base: docker: - - image: rust:1.60.0 + - image: rust:1.64.0 working_directory: ~/project/contracts/cw721-base steps: - checkout: @@ -31,7 +31,7 @@ jobs: command: rustc --version; cargo --version; rustup --version - restore_cache: keys: - - cargocache-cw721-base-rust:1.60.0-{{ checksum "~/project/Cargo.lock" }} + - cargocache-cw721-base-rust:1.64.0-{{ checksum "~/project/Cargo.lock" }} - run: name: Unit Tests environment: @@ -53,11 +53,11 @@ jobs: paths: - /usr/local/cargo/registry - target - key: cargocache-cw721-base-rust:1.60.0-{{ checksum "~/project/Cargo.lock" }} + key: cargocache-cw721-base-rust:1.64.0-{{ checksum "~/project/Cargo.lock" }} contract_cw721_metadata_onchain: docker: - - image: rust:1.60.0 + - image: rust:1.64.0 working_directory: ~/project/contracts/cw721-metadata-onchain steps: - checkout: @@ -67,7 +67,7 @@ jobs: command: rustc --version; cargo --version; rustup --version - restore_cache: keys: - - cargocache-cw721-metadata-onchain-rust:1.60.0-{{ checksum "~/project/Cargo.lock" }} + - cargocache-cw721-metadata-onchain-rust:1.64.0-{{ checksum "~/project/Cargo.lock" }} - run: name: Unit Tests environment: @@ -89,11 +89,11 @@ jobs: paths: - /usr/local/cargo/registry - target - key: cargocache-cw721-metadata-onchain-rust:1.60.0-{{ checksum "~/project/Cargo.lock" }} + key: cargocache-cw721-metadata-onchain-rust:1.64.0-{{ checksum "~/project/Cargo.lock" }} contract_cw721_fixed_price: docker: - - image: rust:1.60.0 + - image: rust:1.64.0 working_directory: ~/project/contracts/cw721-fixed-price steps: - checkout: @@ -103,7 +103,7 @@ jobs: command: rustc --version; cargo --version; rustup --version - restore_cache: keys: - - cargocache-cw721-fixed-price-rust:1.60.0-{{ checksum "~/project/Cargo.lock" }} + - cargocache-cw721-fixed-price-rust:1.64.0-{{ checksum "~/project/Cargo.lock" }} - run: name: Unit Tests environment: @@ -125,11 +125,11 @@ jobs: paths: - /usr/local/cargo/registry - target - key: cargocache-cw721-fixed-price-rust:1.60.0-{{ checksum "~/project/Cargo.lock" }} + key: cargocache-cw721-fixed-price-rust:1.64.0-{{ checksum "~/project/Cargo.lock" }} package_cw721: docker: - - image: rust:1.60.0 + - image: rust:1.64.0 working_directory: ~/project/packages/cw721 steps: - checkout: @@ -139,7 +139,7 @@ jobs: command: rustc --version; cargo --version; rustup --version; rustup target list --installed - restore_cache: keys: - - cargocache-v2-cw721:1.60.0-{{ checksum "~/project/Cargo.lock" }} + - cargocache-v2-cw721:1.64.0-{{ checksum "~/project/Cargo.lock" }} - run: name: Build library for native target command: cargo build --locked @@ -162,11 +162,11 @@ jobs: paths: - /usr/local/cargo/registry - target - key: cargocache-v2-cw721:1.60.0-{{ checksum "~/project/Cargo.lock" }} + key: cargocache-v2-cw721:1.64.0-{{ checksum "~/project/Cargo.lock" }} lint: docker: - - image: rust:1.60.0 + - image: rust:1.64.0 steps: - checkout - run: @@ -174,7 +174,7 @@ jobs: command: rustc --version; cargo --version; rustup --version; rustup target list --installed - restore_cache: keys: - - cargocache-v2-lint-rust:1.60.0-{{ checksum "Cargo.lock" }} + - cargocache-v2-lint-rust:1.64.0-{{ checksum "Cargo.lock" }} - run: name: Add rustfmt component command: rustup component add rustfmt @@ -193,7 +193,7 @@ jobs: - target/debug/.fingerprint - target/debug/build - target/debug/deps - key: cargocache-v2-lint-rust:1.60.0-{{ checksum "Cargo.lock" }} + key: cargocache-v2-lint-rust:1.64.0-{{ checksum "Cargo.lock" }} # This runs one time on the top level to ensure all contracts compile properly into wasm. # We don't run the wasm build per contract build, and then reuse a lot of the same dependencies, so this speeds up CI time @@ -201,7 +201,7 @@ jobs: # We also sanity-check the resultant wasm files. wasm-build: docker: - - image: rust:1.60.0 + - image: rust:1.64.0 steps: - checkout: path: ~/project @@ -210,7 +210,7 @@ jobs: command: rustc --version; cargo --version; rustup --version - restore_cache: keys: - - cargocache-wasm-rust:1.60.0-{{ checksum "~/project/Cargo.lock" }} + - cargocache-wasm-rust:1.64.0-{{ checksum "~/project/Cargo.lock" }} - run: name: Add wasm32 target command: rustup target add wasm32-unknown-unknown @@ -230,7 +230,7 @@ jobs: paths: - /usr/local/cargo/registry - target - key: cargocache-wasm-rust:1.60.0-{{ checksum "~/project/Cargo.lock" }} + key: cargocache-wasm-rust:1.64.0-{{ checksum "~/project/Cargo.lock" }} - run: name: Check wasm contracts command: cosmwasm-check ./target/wasm32-unknown-unknown/release/*.wasm diff --git a/Cargo.lock b/Cargo.lock index d604b7353..df47ff461 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -247,19 +247,6 @@ dependencies = [ "serde", ] -[[package]] -name = "cw3" -version = "0.15.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "961f6959e04de1bc61f4fc3f333bc039998e2aedeab4aa79ba48239cf2d3edfa" -dependencies = [ - "cosmwasm-schema", - "cosmwasm-std", - "cw-utils", - "schemars", - "serde", -] - [[package]] name = "cw721" version = "0.15.0" @@ -296,7 +283,6 @@ dependencies = [ "cw-utils", "cw2", "cw20", - "cw3", "cw721-base", "prost", "schemars", @@ -507,9 +493,9 @@ dependencies = [ [[package]] name = "itertools" -version = "0.10.4" +version = "0.10.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8bf247779e67a9082a4790b45e71ac7cfd1321331a5c856a74a9faebdab78d0" +checksum = "b0fd2260e829bddf4cb6ea802289de2f86d6a7a690192fbe91b3f46e0f2c8473" dependencies = [ "either", ] diff --git a/Cargo.toml b/Cargo.toml index e6f0e6e0a..c24f89369 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,27 @@ [workspace] members = ["packages/*", "contracts/*"] +[workspace.package] +version = "0.15.0" +edition = "2021" +license = "Apache-2.0" +repository = "https://github.com/CosmWasm/cw-nfts" +homepage = "https://cosmwasm.com" +documentation = "https://docs.cosmwasm.com" + +[workspace.dependencies] +cosmwasm-schema = "1.1.0" +cosmwasm-std = "1.1.0" +cw2 = "0.15.0" +cw20 = "0.15.0" +cw721 = { version = "0.15.0", path = "./packages/cw721" } +cw721-base = { version = "0.15.0", path = "./contracts/cw721-base" } +cw-storage-plus = "0.15.0" +cw-utils = "0.15.0" +schemars = "0.8.10" +serde = { version = "1.0.140", default-features = false, features = ["derive"] } +thiserror = "1.0.31" + [profile.release.package.cw721-base] codegen-units = 1 incremental = false diff --git a/build.sh b/build.sh index b0487b8b0..9be75594b 100755 --- a/build.sh +++ b/build.sh @@ -3,4 +3,4 @@ docker run --rm -v "$(pwd)":/code \ --mount type=volume,source="$(basename "$(pwd)")_cache",target=/code/target \ --mount type=volume,source=registry_cache,target=/usr/local/cargo/registry \ - cosmwasm/workspace-optimizer:0.12.6 + cosmwasm/workspace-optimizer:0.12.9 diff --git a/contracts/cw2981-royalties/Cargo.toml b/contracts/cw2981-royalties/Cargo.toml index 9c81f4eec..4c265b469 100644 --- a/contracts/cw2981-royalties/Cargo.toml +++ b/contracts/cw2981-royalties/Cargo.toml @@ -1,20 +1,14 @@ [package] -name = "cw2981-royalties" -version = "0.15.0" -authors = ["Alex Lynham "] -edition = "2021" -description = "Basic implementation of royalties for cw721 NFTs with token level royalties" -license = "Apache-2.0" -repository = "https://github.com/CosmWasm/cw-nfts" -homepage = "https://cosmwasm.com" -documentation = "https://docs.cosmwasm.com" +name = "cw2981-royalties" +description = "Basic implementation of royalties for cw721 NFTs with token level royalties" +authors = ["Alex Lynham "] +version = { workspace = true } +edition = { workspace = true } +license = { workspace = true } +repository = { workspace = true } +homepage = { workspace = true } +documentation = { workspace = true } -exclude = [ - # Those files are rust-optimizer artifacts. You might want to commit them for convenience but they should not be part of the source code publication. - "artifacts/*", -] - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [lib] crate-type = ["cdylib", "rlib"] @@ -25,12 +19,10 @@ backtraces = ["cosmwasm-std/backtraces"] library = [] [dependencies] -cosmwasm-schema = "1.1.0" -cosmwasm-std = "1.1.0" -cw2 = "0.15.0" -cw721 = { path = "../../packages/cw721", version = "0.15.0" } -cw721-base = { path = "../cw721-base", version = "0.15.0", features = [ - "library", -] } -schemars = "0.8.10" -serde = { version = "1.0.140", default-features = false, features = ["derive"] } +cosmwasm-schema = { workspace = true } +cosmwasm-std = { workspace = true } +cw2 = { workspace = true } +cw721 = { workspace = true } +cw721-base = { workspace = true, features = ["library"] } +schemars = { workspace = true } +serde = { workspace = true } diff --git a/contracts/cw721-base/Cargo.toml b/contracts/cw721-base/Cargo.toml index b2fbe8976..6e307b2e0 100644 --- a/contracts/cw721-base/Cargo.toml +++ b/contracts/cw721-base/Cargo.toml @@ -1,23 +1,17 @@ [package] -name = "cw721-base" -version = "0.15.0" -authors = [ +name = "cw721-base" +description = "Basic implementation cw721 NFTs" +authors = [ "Ethan Frey ", "Orkun Külçe ", ] -edition = "2021" -description = "Basic implementation cw721 NFTs" -license = "Apache-2.0" -repository = "https://github.com/CosmWasm/cw-nfts" -homepage = "https://cosmwasm.com" -documentation = "https://docs.cosmwasm.com" +version = { workspace = true } +edition = { workspace = true } +license = { workspace = true } +repository = { workspace = true } +homepage = { workspace = true } +documentation = { workspace = true } -exclude = [ - # Those files are rust-optimizer artifacts. You might want to commit them for convenience but they should not be part of the source code publication. - "artifacts/*", -] - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [lib] crate-type = ["cdylib", "rlib"] @@ -28,12 +22,12 @@ backtraces = ["cosmwasm-std/backtraces"] library = [] [dependencies] -cosmwasm-schema = "1.1.0" -cosmwasm-std = "1.1.0" -cw-utils = "0.15.0" -cw2 = "0.15.0" -cw721 = { path = "../../packages/cw721", version = "0.15.0" } -cw-storage-plus = "0.15.0" -schemars = "0.8.10" -serde = { version = "1.0.140", default-features = false, features = ["derive"] } -thiserror = "1.0.31" +cosmwasm-schema = { workspace = true } +cosmwasm-std = { workspace = true } +cw-utils = { workspace = true } +cw2 = { workspace = true } +cw721 = { workspace = true } +cw-storage-plus = { workspace = true } +schemars = { workspace = true } +serde = { workspace = true } +thiserror = { workspace = true } diff --git a/contracts/cw721-fixed-price/Cargo.toml b/contracts/cw721-fixed-price/Cargo.toml index 5342dd564..f47aeddb7 100644 --- a/contracts/cw721-fixed-price/Cargo.toml +++ b/contracts/cw721-fixed-price/Cargo.toml @@ -1,59 +1,33 @@ [package] -name = "cw721-fixed-price" -version = "0.15.0" -authors = ["Vernon Johnson "] -edition = "2021" - -exclude = [ - # Those files are rust-optimizer artifacts. You might want to commit them for convenience but they should not be part of the source code publication. - "contract.wasm", - "hash.txt", -] - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +name = "cw721-fixed-price" +authors = ["Vernon Johnson "] +version = { workspace = true } +edition = { workspace = true } +license = { workspace = true } +repository = { workspace = true } +homepage = { workspace = true } +documentation = { workspace = true } [lib] crate-type = ["cdylib", "rlib"] -[profile.release] -opt-level = 3 -debug = false -rpath = false -lto = true -debug-assertions = false -codegen-units = 1 -panic = 'abort' -incremental = false -overflow-checks = true - [features] # for more explicit tests, cargo test --features=backtraces backtraces = ["cosmwasm-std/backtraces"] # use library feature to disable all instantiate/execute/query exports library = [] -[package.metadata.scripts] -optimize = """docker run --rm -v "$(pwd)":/code \ - --mount type=volume,source="$(basename "$(pwd)")_cache",target=/code/target \ - --mount type=volume,source=registry_cache,target=/usr/local/cargo/registry \ - cosmwasm/rust-optimizer:0.12.6 -""" - [dependencies] -cosmwasm-schema = "1.1.0" -cosmwasm-std = "1.1.0" -cw-storage-plus = "0.15.0" -cw2 = "0.15.0" -schemars = "0.8.10" -cw721-base = { path = "../cw721-base", version = "0.15.0", features = [ - "library", -] } -cw20 = "0.15.0" -serde = { version = "1.0.140", default-features = false, features = ["derive"] } -thiserror = { version = "1.0.31" } -cw-utils = "0.15.0" -prost = "0.10.4" -cw3 = "0.15.0" +cosmwasm-schema = { workspace = true } +cosmwasm-std = { workspace = true } +cw2 = { workspace = true } +cw20 = { workspace = true } +cw721-base = { workspace = true, features = ["library"] } +cw-storage-plus = { workspace = true } +cw-utils = { workspace = true } +schemars = { workspace = true } +serde = { workspace = true } +thiserror = { workspace = true } [dev-dependencies] prost = "0.10" diff --git a/contracts/cw721-metadata-onchain/Cargo.toml b/contracts/cw721-metadata-onchain/Cargo.toml index 051c7f61a..75944e575 100644 --- a/contracts/cw721-metadata-onchain/Cargo.toml +++ b/contracts/cw721-metadata-onchain/Cargo.toml @@ -1,23 +1,17 @@ [package] -name = "cw721-metadata-onchain" -version = "0.15.0" -authors = [ +name = "cw721-metadata-onchain" +description = "Example extending CW721 NFT to store metadata on chain" +authors = [ "Ethan Frey ", "Orkun Külçe ", ] -edition = "2021" -description = "Example extending CW721 NFT to store metadata on chain" -license = "Apache-2.0" -repository = "https://github.com/CosmWasm/cw-nfts" -homepage = "https://cosmwasm.com" -documentation = "https://docs.cosmwasm.com" +version = { workspace = true } +edition = { workspace = true } +license = { workspace = true } +repository = { workspace = true } +homepage = { workspace = true } +documentation = { workspace = true } -exclude = [ - # Those files are rust-optimizer artifacts. You might want to commit them for convenience but they should not be part of the source code publication. - "artifacts/*", -] - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [lib] crate-type = ["cdylib", "rlib"] @@ -28,12 +22,10 @@ backtraces = ["cosmwasm-std/backtraces"] library = [] [dependencies] -cosmwasm-schema = "1.1.0" -cosmwasm-std = "1.1.0" -cw2 = "0.15.0" -cw721 = { path = "../../packages/cw721", version = "0.15.0" } -cw721-base = { path = "../cw721-base", version = "0.15.0", features = [ - "library", -] } -schemars = "0.8.10" -serde = { version = "1.0.140", default-features = false, features = ["derive"] } +cosmwasm-schema = { workspace = true } +cosmwasm-std = { workspace = true } +cw2 = { workspace = true } +cw721 = { workspace = true } +cw721-base = { workspace = true, features = ["library"] } +schemars = { workspace = true } +serde = { workspace = true } diff --git a/contracts/cw721-non-transferable/Cargo.toml b/contracts/cw721-non-transferable/Cargo.toml index 74258efee..ce1ac9eaa 100644 --- a/contracts/cw721-non-transferable/Cargo.toml +++ b/contracts/cw721-non-transferable/Cargo.toml @@ -1,14 +1,14 @@ [package] -name = "cw721-non-transferable" -authors = [ - "Eliseo Cohen ", -] -version = "0.15.0" -edition = "2021" -description = "Non-transferable CW721 NFT example" -license = "Apache-2.0" +name = "cw721-non-transferable" +authors = ["Eliseo Cohen "] +description = "Non-transferable CW721 NFT example" +version = { workspace = true } +edition = { workspace = true } +license = { workspace = true } +repository = { workspace = true } +homepage = { workspace = true } +documentation = { workspace = true } -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [lib] crate-type = ["cdylib", "rlib"] @@ -18,21 +18,12 @@ backtraces = ["cosmwasm-std/backtraces"] # use library feature to disable all instantiate/execute/query exports library = [] -[package.metadata.scripts] -optimize = """docker run --rm -v "$(pwd)":/code \ - --mount type=volume,source="$(basename "$(pwd)")_cache",target=/code/target \ - --mount type=volume,source=registry_cache,target=/usr/local/cargo/registry \ - cosmwasm/rust-optimizer:0.12.6 -""" - [dependencies] -cosmwasm-schema = "1.1.0" -cosmwasm-std = "1.1.0" -cw-storage-plus = "0.15.0" -cw2 = "0.15.0" -cw721 = { path = "../../packages/cw721", version = "0.15.0" } -cw721-base = { path = "../cw721-base", version = "0.15.0", features = [ - "library", -] } -schemars = "0.8.10" -serde = { version = "1.0.140", default-features = false, features = ["derive"] } +cosmwasm-schema = { workspace = true } +cosmwasm-std = { workspace = true } +cw-storage-plus = { workspace = true } +cw2 = { workspace = true } +cw721 = { workspace = true } +cw721-base = { workspace = true, features = ["library"] } +schemars = { workspace = true } +serde = { workspace = true } diff --git a/packages/cw721/Cargo.toml b/packages/cw721/Cargo.toml index a2dfa00c8..0f5967cff 100644 --- a/packages/cw721/Cargo.toml +++ b/packages/cw721/Cargo.toml @@ -1,20 +1,20 @@ [package] -name = "cw721" -version = "0.15.0" -authors = [ - "Ethan Frey ", - "Orkun Külçe ", +name = "cw721" +description = "Definition and types for the CosmWasm-721 NFT interface" +authors = [ + "Ethan Frey ", + "Orkun Külçe ", ] -edition = "2021" -description = "Definition and types for the CosmWasm-721 NFT interface" -license = "Apache-2.0" -repository = "https://github.com/CosmWasm/cw-nfts" -homepage = "https://cosmwasm.com" -documentation = "https://docs.cosmwasm.com" +version = { workspace = true } +edition = { workspace = true } +license = { workspace = true } +repository = { workspace = true } +homepage = { workspace = true } +documentation = { workspace = true } [dependencies] -cosmwasm-schema = "1.1.0" -cosmwasm-std = "1.1.0" -cw-utils = "0.15.0" -schemars = "0.8.10" -serde = { version = "1.0.140", default-features = false, features = ["derive"] } +cosmwasm-schema = { workspace = true } +cosmwasm-std = { workspace = true } +cw-utils = { workspace = true } +schemars = { workspace = true } +serde = { workspace = true }