mirror of
https://seed.radicle.dev/rad:z3gqcJUoA1n9HaHKufZs5FCSGazv5.git
synced 2026-11-29 22:10:31 +08:00
Rust 1.67 was announced[0]. Update the necessary files for running 1.67 and fix the clippy suggestions for string interpolation. [0]: https://blog.rust-lang.org/2023/01/26/Rust-1.67.0.html Signed-off-by: Fintan Halpenny <fintan.halpenny@gmail.com> X-Clacks-Overhead: GNU Terry Pratchett
24 lines
541 B
Rust
24 lines
541 B
Rust
use std::path::Path;
|
|
|
|
use radicle::{git, Profile};
|
|
|
|
fn main() -> anyhow::Result<()> {
|
|
let cwd = Path::new(".").canonicalize()?;
|
|
let name = cwd.file_name().unwrap().to_string_lossy().to_string();
|
|
let repo = radicle::git::raw::Repository::open(cwd)?;
|
|
let profile = Profile::load()?;
|
|
let signer = profile.signer()?;
|
|
let (id, _, _) = radicle::rad::init(
|
|
&repo,
|
|
&name,
|
|
"",
|
|
git::refname!("master"),
|
|
&signer,
|
|
&profile.storage,
|
|
)?;
|
|
|
|
println!("ok: {id}");
|
|
|
|
Ok(())
|
|
}
|