diff options
author | Justus Winter <justus@sequoia-pgp.org> | 2019-05-15 16:28:11 +0200 |
---|---|---|
committer | Justus Winter <justus@sequoia-pgp.org> | 2019-05-15 16:29:55 +0200 |
commit | a25ef6974e0ba3989f6205c19a1f9ccfc81db584 (patch) | |
tree | 4ce3b386923515a662051c40f67a135ee15681f6 /examples | |
parent | 36e2d97ac013e023feb27df939c3f6d6e32d8669 (diff) |
core, store, tool: Use realm instead of domain.
- Remove the domain parameter from core::Context.
- Replace it with a realm to be passed in when opening a store.
- For sq, merge store name and realm into the --store parameter.
- Fixes #105.
Diffstat (limited to 'examples')
-rw-r--r-- | examples/guide-the-keystore.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/examples/guide-the-keystore.rs b/examples/guide-the-keystore.rs index b4c5b15b..4748ad6b 100644 --- a/examples/guide-the-keystore.rs +++ b/examples/guide-the-keystore.rs @@ -39,13 +39,14 @@ fn main() { -----END PGP PUBLIC KEY BLOCK-----"; // Provide some context. - let ctx = core::Context::new("org.sequoia-pgp.guide").unwrap(); + let ctx = core::Context::new().unwrap(); // Parse TPK. let tpk = openpgp::TPK::from_bytes(tpk).unwrap(); // Open a store. - let store = store::Store::open(&ctx, "default").unwrap(); + let store = + store::Store::open(&ctx, store::REALM_CONTACTS, "default").unwrap(); // Store the TPK. store.import("Ἀριστοτέλης", &tpk).unwrap(); |