Add comment about why --as=clearsigned and --no-armor are incompatible

This commit is contained in:
Paul Schaub 2023-04-17 13:13:36 +02:00
parent 7743f15e72
commit 6ec62560ba
Signed by: vanitasvitae
GPG Key ID: 62BEE9264BF17311
1 changed files with 1 additions and 0 deletions

View File

@ -41,6 +41,7 @@ public class InlineSignCmd extends AbstractSopCmd {
InlineSign inlineSign = throwIfUnsupportedSubcommand(
SopCLI.getSop().inlineSign(), "inline-sign");
// Clearsigned messages are inherently armored, so --no-armor makes no sense.
if (!armor && type == InlineSignAs.clearsigned) {
String errorMsg = getMsg("sop.error.usage.incompatible_options.clearsigned_no_armor");
throw new SOPGPException.IncompatibleOptions(errorMsg);