From 2f8d3a0247d45461f82f74b6106f552a92fc1617 Mon Sep 17 00:00:00 2001 From: Corey Johnson Date: Mon, 4 May 2020 11:52:09 -0700 Subject: [PATCH] Add doc --- docs/command-line-syntax.md | 39 +++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 docs/command-line-syntax.md diff --git a/docs/command-line-syntax.md b/docs/command-line-syntax.md new file mode 100644 index 000000000..727f2b5b6 --- /dev/null +++ b/docs/command-line-syntax.md @@ -0,0 +1,39 @@ +# How we document our command line syntax + +## Required arguments + +Use plain text + +_*example:*_ +`gh help` +help is a required argument in this command + +## Placeholder values + +Use Angled brackets to represent text that you must supply + +_*example:*_ +`gh pr view ` +Replace `` with an issue number + +## Optional arguments + +Place optional arguments in square brackets + +_*example:*_ +`gh pr checkout [--web]` +Replace `--web` is an optional argument + +## Mutually exclusive arguments + +Place mutually exclusive arguments inside braces separated by a vertical bar. + +_*example:*_ +`gh pr {view | create}` + +## Repeatable arguements + +One or more arguments can replace arguments with ellipsis + +_*example:*_ +`gh pr close `