Skip to content

Commit

Permalink
check-ignore: update help output (#4358)
Browse files Browse the repository at this point in the history
* check_ignore: update help output
per #4282 (review)
and #4282 (review)

* check-ignore: more output string updates
per #4323 et al.

* check-ignore: min text update
to match iterative/dvc.org/pull/1673

Co-authored-by: Ruslan Kuprieiev <kupruser@gmail.com>
  • Loading branch information
jorgeorpinel and efiop committed Aug 11, 2020
1 parent 765d2ed commit 9cb32b5
Showing 1 changed file with 15 additions and 17 deletions.
32 changes: 15 additions & 17 deletions dvc/command/check_ignore.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,9 @@ def run(self):


def add_parser(subparsers, parent_parser):
ADD_HELP = "Debug DVC ignore/exclude files"
ADD_HELP = (
"Check whether files or directories are excluded due to `.dvcignore`."
)

parser = subparsers.add_parser(
"check-ignore",
Expand All @@ -95,35 +97,31 @@ def add_parser(subparsers, parent_parser):
"--details",
action="store_true",
default=False,
help="Show the exclude pattern together with each target path.",
help="Show the exclude patterns along with each target path.",
)
parser.add_argument(
"-n",
"--non-matching",
"-a",
"--all",
action="store_true",
default=False,
help="Show the target paths which don’t match any pattern. "
"Only usable when `--details` is also employed",
help="Include the target paths which don’t match any pattern "
"in the `--details` list.",
)
parser.add_argument(
"--stdin",
"-n",
"--non-matching",
action="store_true",
default=False,
help="Read pathnames from the standard input, one per line, "
"instead of from the command-line.",
help="Include the target paths which don’t match any pattern "
"in the `--details` list.",
)
parser.add_argument(
"-a",
"--all",
"--stdin",
action="store_true",
default=False,
help="Show all of the patterns match the target paths. "
"Only usable when `--details` is also employed",
help="Read paths from standard input instead of providing `targets`.",
)
parser.add_argument(
"targets",
nargs="*",
help="Exact or wildcard paths of files or directories to check "
"ignore patterns.",
"targets", nargs="*", help="File or directory paths to check",
).complete = completion.FILE
parser.set_defaults(func=CmdCheckIgnore)

0 comments on commit 9cb32b5

Please sign in to comment.