Skip to content

Commit

Permalink
fix: rename profile test->release
Browse files Browse the repository at this point in the history
Signed-off-by: Lohachov Mykhailo <[email protected]>
  • Loading branch information
aoyako committed Nov 12, 2024
1 parent 45df4a6 commit dc2034e
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 11 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/iroha2-dev-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ jobs:
steps:
- uses: actions/checkout@v4
- name: Build
run: ./scripts/build_wasm.sh --profile=test
run: ./scripts/build_wasm.sh --profile=release
- name: Upload all built WASMs
uses: actions/upload-artifact@v4
with:
Expand Down
6 changes: 3 additions & 3 deletions scripts/build_wasm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,11 @@ main() {
"deploy")
OPTIMIZE_FLAG="--optimize"
;;
"test")
"release")
OPTIMIZE_FLAG=""
;;
*)
echo "error: unrecognized profile: $PROFILE. Profile can be either [deploy, test]"
echo "error: unrecognized profile: $PROFILE. Profile can be either [deploy, release]"
exit 1
;;
esac
Expand Down Expand Up @@ -113,7 +113,7 @@ Usage: $0 [OPTIONS]
Options:
--profile=<value> Specify build profile (default: deploy)
Possible values: test, deploy
Possible values: release, deploy
--help Show help message
Positional Arguments:
Expand Down
4 changes: 0 additions & 4 deletions wasm/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,6 @@ lto = true # Link-time-optimization produces notable decrease in binary
opt-level = "z" # Optimize for size vs speed with "s"/"z"(removes vectorization)
codegen-units = 1 # Further reduces binary size but increases compilation time

[profile.test]
inherits = "release"
panic = "abort"

[workspace.dependencies]
iroha_smart_contract = { version = "=2.0.0-rc.1.0", path = "../crates/iroha_smart_contract", features = ["debug"] }
iroha_trigger = { version = "=2.0.0-rc.1.0", path = "../crates/iroha_trigger", features = ["debug"] }
Expand Down
6 changes: 3 additions & 3 deletions wasm/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,11 @@ bash scripts/build_wasm.sh samples
```

## WASM in specific profile
1. Release **(default)**
1. Deploy **(default)**
```bash
bash scripts/build_wasm.sh --profile=deploy
```
2. Test
2. Release (with debug information)
```bash
bash scripts/build_wasm.sh --profile=test
bash scripts/build_wasm.sh --profile=release
```

0 comments on commit dc2034e

Please sign in to comment.