Skip to content

Commit

Permalink
chore: improve release process (#10)
Browse files Browse the repository at this point in the history
Signed-off-by: Wenxuan Zhang <wenxuangm@gmail.com>
  • Loading branch information
wfxr authored Apr 14, 2024
1 parent 5c3b1a1 commit 967f711
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 5 deletions.
12 changes: 7 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,15 @@ rlt for various services, such as Http, gRPC, Thrift, Database, or other customi

### Quick Start

To use `rlt`, firstly add it as a dependency:
Run `cargo add rlt` to add `rlt` as a dependency to your `Cargo.toml`:

```toml
[dependencies]
rlt = "v0.1.1-rc.1"
```
$ cargo add rlt
```

Then create your bench suite by implementing the `BenchSuite` trait.
You can use `flatten` attribute provided by `clap` to embed the predefined `BenchCli` into your own.
`flatten` attribute can be used to embed the predefined `BenchCli` into your own.

```rust
#[derive(Parser, Clone)]
Expand Down Expand Up @@ -62,7 +64,7 @@ impl BenchSuite for HttpBench {
}
```

Note that you can create a separate struct to hold the cli options for more flexibility. There is an example in [examples/http_hyper.rs](examples/http_hyper.rs).
*You can also create a separate struct to hold the cli options for more flexibility. There is an example in [examples/http_hyper.rs](examples/http_hyper.rs).*

Finally, create the main function to run the load test:

Expand Down
7 changes: 7 additions & 0 deletions release.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
allow-branch = ["improve-release"]
pre-release-replacements = [
{ file = "README.md", search = "rlt = .*", replace = "{{crate_name}} = \"{{version}}\"" },
]
pre-release-hook = ["git", "cliff", "-o", "CHANGELOG.md", "--tag", "{{version}}" ]
pre-release-commit-message = "chore: release {{crate_name}} version {{version}}"
tag-message = "chore: release {{crate_name}} version {{version}}"

0 comments on commit 967f711

Please sign in to comment.