-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
8d8f182
commit 6180c8f
Showing
15 changed files
with
244 additions
and
134 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,3 +10,5 @@ | |
.hc* | ||
.hc | ||
.running | ||
.gnupg | ||
*.asc |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
use hdi::prelude::*; | ||
#[hdk_entry_helper] | ||
#[derive(Clone, PartialEq)] | ||
pub struct GpgKeyDist { | ||
pub public_key: String, | ||
pub fingerprint: String, | ||
} | ||
|
||
pub fn validate_create_gpg_key_dist( | ||
_action: EntryCreationAction, | ||
_gpg_key: GpgKeyDist, | ||
) -> ExternResult<ValidateCallbackResult> { | ||
Ok(ValidateCallbackResult::Valid) | ||
} | ||
|
||
pub fn validate_update_gpg_key_dist( | ||
_action: Update, | ||
_gpg_key: GpgKeyDist, | ||
_original_action: EntryCreationAction, | ||
_original_gpg_key: GpgKeyDist, | ||
) -> ExternResult<ValidateCallbackResult> { | ||
Ok(ValidateCallbackResult::Invalid(String::from("Gpg key distributions cannot be updated"))) | ||
} | ||
|
||
pub fn validate_delete_gpg_key_dist( | ||
_action: Delete, | ||
_original_action: EntryCreationAction, | ||
_original_gpg_key: GpgKeyDist, | ||
) -> ExternResult<ValidateCallbackResult> { | ||
Ok(ValidateCallbackResult::Invalid(String::from("Gpg key distributions cannot be deleted"))) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.