Skip to content

Commit

Permalink
Merge pull request #107 from public-awesome/update-versions3
Browse files Browse the repository at this point in the history
Update to version 0.11.0
  • Loading branch information
shanev authored Oct 25, 2022
2 parents c4d8fe5 + 1c461c0 commit ba62db3
Show file tree
Hide file tree
Showing 14 changed files with 94 additions and 75 deletions.
42 changes: 21 additions & 21 deletions Cargo.lock

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

6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@ members = ["packages/*", "contracts/*"]
resolver = "2"

[workspace.package]
version = "0.10.0"
version = "0.11.0"
edition = "2021"
homepage = "https://stargaze.zone"
repository = "https://github.com/public-awesome/names"
license = "Apache-2.0"

[workspace.dependencies]
cosmwasm-schema = "1.1.4"
cosmwasm-std = "1.1.4"
cosmwasm-schema = "1.1.5"
cosmwasm-std = "1.1.5"
cw2 = "0.15.1"
cw721 = "0.15.0"
cw721-base = "0.15.0"
Expand Down
14 changes: 8 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,11 @@
lint:
cargo clippy --all-targets -- -D warnings

types:
cd contracts/marketplace && cargo schema && cd ../..
cd contracts/name-minter && cargo schema && cd ../..
cd contracts/sg721-name && cargo schema && cd ../..
cd contracts/whitelist-updatable && cargo schema && cd ../..
cd ts && yarn codegen && cd ..
optimize:
sh scripts/optimize.sh

publish:
sh scripts/publish.sh

schema:
sh scripts/schema.sh
2 changes: 1 addition & 1 deletion contracts/marketplace/schema/name-marketplace.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"contract_name": "name-marketplace",
"contract_version": "0.10.0",
"contract_version": "0.11.0",
"idl_version": "1.0.0",
"instantiate": {
"$schema": "http://json-schema.org/draft-07/schema#",
Expand Down
2 changes: 1 addition & 1 deletion contracts/name-minter/schema/name-minter.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"contract_name": "name-minter",
"contract_version": "0.10.0",
"contract_version": "0.11.0",
"idl_version": "1.0.0",
"instantiate": {
"$schema": "http://json-schema.org/draft-07/schema#",
Expand Down
9 changes: 3 additions & 6 deletions contracts/name-minter/src/integration_tests.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
use crate::contract::{execute, instantiate, reply};
use crate::msg::{ExecuteMsg, InstantiateMsg};
use crate::query::query;
use anyhow::Result as AnyResult;
use cosmwasm_std::{coins, Addr, Uint128};
use cw721::{NumTokensResponse, OwnerOfResponse};
Expand All @@ -14,12 +16,7 @@ use sg_name::{NameMarketplaceResponse, SgNameQueryMsg};
use sg_std::{StargazeMsgWrapper, NATIVE_DENOM};

pub fn contract_minter() -> Box<dyn Contract<StargazeMsgWrapper>> {
let contract = ContractWrapper::new(
crate::contract::execute,
crate::contract::instantiate,
crate::query::query,
)
.with_reply(crate::contract::reply);
let contract = ContractWrapper::new(execute, instantiate, query).with_reply(reply);
Box::new(contract)
}

Expand Down
2 changes: 1 addition & 1 deletion contracts/sg721-name/schema/sg721-name.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"contract_name": "sg721-name",
"contract_version": "0.10.0",
"contract_version": "0.11.0",
"idl_version": "1.0.0",
"instantiate": {
"$schema": "http://json-schema.org/draft-07/schema#",
Expand Down
18 changes: 9 additions & 9 deletions packages/sg-name-market/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
[package]
name = "sg-name-market"
version = "0.9.0"
authors = ["Shane Vitarana <s@noreply.publicawesome.com>"]
edition = "2021"
description = "Rust definition of Stargaze Name Marketplace"
license = "Apache-2.0"
repository = "https://github.com/public-awesome/names"
homepage = "https://stargaze.zone"
version = { workspace = true }
edition = { workspace = true }
homepage = { workspace = true }
repository = { workspace = true }
license = { 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.
Expand All @@ -20,7 +20,7 @@ exclude = [
crate-type = ["cdylib", "rlib"]

[dependencies]
cosmwasm-schema = "1.1.4"
schemars = "0.8.11"
serde = { version = "1.0.145", default-features = false, features = ["derive"] }
cosmwasm-std = "1.1.4"
cosmwasm-schema = { workspace = true }
cosmwasm-std = { workspace = true }
schemars = { workspace = true }
serde = { workspace = true }
18 changes: 9 additions & 9 deletions packages/sg-name-minter/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
[package]
name = "sg-name-minter"
version = "0.9.0"
authors = ["Shane Vitarana <s@noreply.publicawesome.com>"]
edition = "2021"
description = "Rust definition of name service metadata, used by Stargaze Names"
license = "Apache-2.0"
repository = "https://github.com/public-awesome/names"
homepage = "https://stargaze.zone"
version = { workspace = true }
edition = { workspace = true }
homepage = { workspace = true }
repository = { workspace = true }
license = { 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.
Expand All @@ -20,7 +20,7 @@ exclude = [
crate-type = ["cdylib", "rlib"]

[dependencies]
cosmwasm-schema = "1.1.4"
schemars = "0.8.11"
serde = { version = "1.0.145", default-features = false, features = ["derive"] }
cosmwasm-std = "1.1.4"
cosmwasm-schema = { workspace = true }
cosmwasm-std = { workspace = true }
schemars = { workspace = true }
serde = { workspace = true }
18 changes: 9 additions & 9 deletions packages/sg-name/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
[package]
name = "sg-name"
version = "0.9.0"
authors = ["Shane Vitarana <s@noreply.publicawesome.com>"]
edition = "2021"
description = "Rust definition of name service metadata, used by Stargaze Names"
license = "Apache-2.0"
repository = "https://github.com/public-awesome/names"
homepage = "https://stargaze.zone"
version = { workspace = true }
edition = { workspace = true }
homepage = { workspace = true }
repository = { workspace = true }
license = { 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.
Expand All @@ -20,7 +20,7 @@ exclude = [
crate-type = ["cdylib", "rlib"]

[dependencies]
cosmwasm-schema = "1.1.4"
schemars = "0.8.11"
serde = { version = "1.0.145", default-features = false, features = ["derive"] }
cosmwasm-std = "1.1.4"
cosmwasm-schema = { workspace = true }
cosmwasm-std = { workspace = true }
schemars = { workspace = true }
serde = { workspace = true }
18 changes: 9 additions & 9 deletions packages/sg-whitelist-basic/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
[package]
name = "sg-whitelist-basic"
version = "0.9.0"
authors = ["Shane Vitarana <s@noreply.publicawesome.com>"]
edition = "2021"
description = "Rust definition of a basic Stargaze whitelist"
license = "Apache-2.0"
repository = "https://github.com/public-awesome/names"
homepage = "https://stargaze.zone"
version = { workspace = true }
edition = { workspace = true }
homepage = { workspace = true }
repository = { workspace = true }
license = { 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.
Expand All @@ -20,7 +20,7 @@ exclude = [
crate-type = ["cdylib", "rlib"]

[dependencies]
cosmwasm-schema = "1.1.4"
schemars = "0.8.11"
serde = { version = "1.0.145", default-features = false, features = ["derive"] }
cosmwasm-std = "1.1.4"
cosmwasm-schema = { workspace = true }
cosmwasm-std = { workspace = true }
schemars = { workspace = true }
serde = { workspace = true }
4 changes: 4 additions & 0 deletions scripts/optimize.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
docker run --rm -v "$(pwd)":/code --platform linux/amd64 \
--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.9
7 changes: 7 additions & 0 deletions scripts/publish.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
for d in packages/*; do
if [ -d "$d" ]; then
cd $d
cargo publish
cd ../..
fi
done
9 changes: 9 additions & 0 deletions scripts/schema.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
for d in contracts/*; do
if [ -d "$d" ]; then
cd $d
cargo schema
cd ../..
fi
done

cd ts && yarn codegen

0 comments on commit ba62db3

Please sign in to comment.