Skip to content

Commit b16b5a3

Browse files
committed
team_repo: Add basic example
1 parent 6275dc0 commit b16b5a3

File tree

3 files changed

+13
-0
lines changed

3 files changed

+13
-0
lines changed

Cargo.lock

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

crates/crates_io_team_repo/Cargo.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,6 @@ async-trait = "=0.1.83"
1313
mockall = "=0.13.0"
1414
reqwest = { version = "=0.12.8", features = ["gzip", "json"] }
1515
serde = { version = "=1.0.210", features = ["derive"] }
16+
17+
[dev-dependencies]
18+
tokio = { version = "=1.40.0", features = ["macros", "rt-multi-thread"] }
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
use crates_io_team_repo::{TeamRepo, TeamRepoImpl};
2+
3+
#[tokio::main]
4+
async fn main() -> anyhow::Result<()> {
5+
let team_repo = TeamRepoImpl::default();
6+
let permission = team_repo.get_permission("crates_io_admin").await?;
7+
println!("{permission:#?}");
8+
Ok(())
9+
}

0 commit comments

Comments
 (0)