46 lines
2 KiB
Diff
46 lines
2 KiB
Diff
From b6279d75db53ddc34dd6ba727df1b7fd0ad134dd Mon Sep 17 00:00:00 2001
|
|
From: =?UTF-8?q?Jan=20Christian=20Gr=C3=BCnhage?=
|
|
<jan.christian@gruenhage.xyz>
|
|
Date: Sun, 13 Feb 2022 10:09:29 +0100
|
|
Subject: [PATCH 2/2] fix: remove single quotes from clap doc comments
|
|
|
|
Apparently, clap_complete doesn't properly escape single quotes in doc
|
|
comments, leading to broken shell completions for zsh. To circumvent
|
|
this, I've removed the single quote in the one place where it shouldn't
|
|
have been in the first place ("it's" vs "its", contraction vs possessive
|
|
pronoun), and replaced "it's" with "it is" in the other place.
|
|
|
|
Reference to upstream issue: https://github.com/clap-rs/clap/issues/1596
|
|
---
|
|
src/commands.rs | 2 +-
|
|
src/opts.rs | 2 +-
|
|
2 files changed, 2 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/src/commands.rs b/src/commands.rs
|
|
index 106e36d..692dceb 100644
|
|
--- a/src/commands.rs
|
|
+++ b/src/commands.rs
|
|
@@ -99,7 +99,7 @@ pub fn run(args: Opts, question_policy: QuestionPolicy) -> crate::Result<()> {
|
|
let output_file = fs::File::create(&output_path)?;
|
|
|
|
if !represents_several_files(&files) {
|
|
- // It's possible the file is already partially compressed so we don't want to compress it again
|
|
+ // It is possible the file is already partially compressed so we don't want to compress it again
|
|
// `ouch compress file.tar.gz file.tar.gz.xz` should produce `file.tar.gz.xz` and not `file.tar.gz.tar.gz.xz`
|
|
let input_extensions = extension::extensions_from_path(&files[0]);
|
|
|
|
diff --git a/src/opts.rs b/src/opts.rs
|
|
index 14d6997..e532e7b 100644
|
|
--- a/src/opts.rs
|
|
+++ b/src/opts.rs
|
|
@@ -39,7 +39,7 @@ pub enum Subcommand {
|
|
#[clap(required = true, min_values = 1)]
|
|
files: Vec<PathBuf>,
|
|
|
|
- /// The resulting file. It's extensions can be used to specify the compression formats.
|
|
+ /// The resulting file. Its extensions can be used to specify the compression formats.
|
|
#[clap(required = true, value_hint = ValueHint::FilePath)]
|
|
output: PathBuf,
|
|
},
|
|
--
|
|
2.35.1
|