Skip to content

Commit

Permalink
Implement PNI (#245)
Browse files Browse the repository at this point in the history
Still to do: #252

---------

Co-authored-by: boxdot <d@zerovolt.org>
  • Loading branch information
gferon and boxdot authored May 30, 2024
1 parent 6441fa8 commit 0c46be2
Show file tree
Hide file tree
Showing 13 changed files with 1,523 additions and 1,172 deletions.
22 changes: 6 additions & 16 deletions presage-cli/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
use core::fmt;
use std::convert::TryInto;
use std::path::Path;
use std::path::PathBuf;
Expand Down Expand Up @@ -492,7 +491,12 @@ async fn run<S: Store>(subcommand: Cmd, config_store: S) -> anyhow::Result<()> {
let stdin = io::stdin();
let reader = BufReader::new(stdin);
if let Some(confirmation_code) = reader.lines().next_line().await? {
manager.confirm_verification_code(confirmation_code).await?;
let registered_manager =
manager.confirm_verification_code(confirmation_code).await?;
println!(
"Account identifier: {}",
registered_manager.registration_data().aci()
);
}
}
Cmd::LinkDevice {
Expand Down Expand Up @@ -709,17 +713,3 @@ fn parse_base64_profile_key(s: &str) -> anyhow::Result<ProfileKey> {
.map_err(|_| anyhow!("profile key of invalid length"))?;
Ok(ProfileKey::create(bytes))
}

struct DebugGroup<'a>(&'a Group);

impl fmt::Debug for DebugGroup<'_> {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
let group = &self.0;
f.debug_struct("Group")
.field("title", &group.title)
.field("avatar", &group.avatar)
.field("revision", &group.revision)
.field("description", &group.description)
.finish()
}
}
1 change: 1 addition & 0 deletions presage-store-sled/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ thiserror = "1.0"
prost = "> 0.10, <= 0.12"
sha2 = "0.10"
quickcheck_macros = "1.0.0"
chrono = "0.4.35"

[dev-dependencies]
anyhow = "1.0"
Expand Down
Loading

0 comments on commit 0c46be2

Please sign in to comment.