Change sq cert lint to not read from stdin by default.

- Reading from stdin by default has caused confusion.  If the user
    wants to read from stdin, then they should explicitly opt-in.
This commit is contained in:
Neal H. Walfield 2024-05-28 09:17:03 +02:00
parent 5f8ef02cd4
commit 22cc90e11f
No known key found for this signature in database
GPG Key ID: 6863C9AD5B4D22D3
3 changed files with 2 additions and 5 deletions

1
NEWS
View File

@ -29,6 +29,7 @@
certificate store. certificate store.
- The user ID argument to `sq key userid revoke` is no longer a - The user ID argument to `sq key userid revoke` is no longer a
positional argument, but must be specified with `--userid`. positional argument, but must be specified with `--userid`.
- Change `sq cert lint` to not read from stdin by default.
* Changes in 0.36.0 * Changes in 0.36.0
- Missing - Missing
* Changes in 0.35.0 * Changes in 0.35.0

View File

@ -95,6 +95,7 @@ pub struct Command {
#[clap( #[clap(
help = FileOrStdin::HELP_OPTIONAL, help = FileOrStdin::HELP_OPTIONAL,
value_name = FileOrStdin::VALUE_NAME, value_name = FileOrStdin::VALUE_NAME,
required = true,
)] )]
pub inputs: Vec<FileOrStdin>, pub inputs: Vec<FileOrStdin>,

View File

@ -256,11 +256,6 @@ pub fn lint(sq: Sq, mut args: Command) -> Result<()> {
armor::Kind::PublicKey armor::Kind::PublicKey
})?; })?;
// If no inputs are given, read from stdin.
if args.inputs.is_empty() {
args.inputs.push(Default::default());
}
'next_input: for input in args.inputs { 'next_input: for input in args.inputs {
let mut input_reader = input.open()?; let mut input_reader = input.open()?;
let filename = match input.inner() { let filename = match input.inner() {