Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add stargate and cosmwasm 1.1-1.1 features to CW3 contracts #1

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 35 additions & 0 deletions .github/workflows/artifacts.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Artifacts

on:
push:
branches:
- master
- main
pull_request:
branches:
- master
- main
workflow_dispatch:

env:
RUST_BACKTRACE: 1
CARGO_TERM_COLOR: always

jobs:
artifacts:
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v3

- name: Install cargo make
uses: davidB/rust-cargo-make@v1

- name: Compile contracts to wasm
run: cargo make rust-optimizer

- name: Upload artifacts
uses: actions/upload-artifact@v3
with:
name: artifacts
path: artifacts/
76 changes: 0 additions & 76 deletions Cargo.lock

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

16 changes: 0 additions & 16 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,6 @@ members = ["packages/*", "contracts/*"]
# Resolver has to be set explicitely in workspaces, see https://github.com/rust-lang/cargo/issues/9956
resolver = "2"

[profile.release.package.cw1-subkeys]
codegen-units = 1
incremental = false

[profile.release.package.cw1-whitelist]
codegen-units = 1
incremental = false

[profile.release.package.cw3-fixed-multisig]
codegen-units = 1
incremental = false
Expand All @@ -24,18 +16,10 @@ incremental = false
codegen-units = 1
incremental = false

[profile.release.package.cw4-stake]
codegen-units = 1
incremental = false

[profile.release.package.cw20-base]
codegen-units = 1
incremental = false

[profile.release.package.cw20-ics20]
codegen-units = 1
incremental = false

[profile.release]
rpath = false
lto = true
Expand Down
42 changes: 42 additions & 0 deletions Makefile.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
[config]
default_to_workspace = false
skip_core_tasks = true

[env]
# If you bump this version, verify RUST_VERSION correctness
RUST_OPTIMIZER_VERSION = "0.13.0"
# Use rust version from rust-optimizer Dockerfile (see https://github.com/CosmWasm/rust-optimizer/blob/main/Dockerfile#L1)
# to be sure that we compile / test against the same version
RUST_VERSION = "1.69.0"
NIGHTLY_VERSION = "nightly-2023-08-29"

[tasks.install-stable]
script = '''
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal --default-toolchain ${RUST_VERSION}
rustup target add wasm32-unknown-unknown --toolchain ${RUST_VERSION}
rustup component add rustfmt --toolchain ${RUST_VERSION}
rustup component add clippy --toolchain ${RUST_VERSION}
rustup component add llvm-tools-preview --toolchain ${RUST_VERSION}
'''

[tasks.install-nightly]
script = '''
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal --default-toolchain ${NIGHTLY_VERSION}
rustup target add wasm32-unknown-unknown --toolchain ${NIGHTLY_VERSION}
rustup component add rustfmt --toolchain ${NIGHTLY_VERSION}
rustup component add clippy --toolchain ${NIGHTLY_VERSION}
'''

[tasks.rust-optimizer]
cwd = "${CARGO_MAKE_WORKSPACE_WORKING_DIRECTORY}"
script = """
if [[ $(arch) == "arm64" ]]; then
image="cosmwasm/workspace-optimizer-arm64:${RUST_OPTIMIZER_VERSION}"
else
image="cosmwasm/workspace-optimizer:${RUST_OPTIMIZER_VERSION}"
fi
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 \
${image}
"""
6 changes: 0 additions & 6 deletions contracts/cw1-subkeys/.cargo/config

This file was deleted.

40 changes: 0 additions & 40 deletions contracts/cw1-subkeys/Cargo.toml

This file was deleted.

93 changes: 0 additions & 93 deletions contracts/cw1-subkeys/README.md

This file was deleted.

13 changes: 0 additions & 13 deletions contracts/cw1-subkeys/src/bin/schema.rs

This file was deleted.

Loading