lab icon indicating copy to clipboard operation
lab copied to clipboard

Equip every command with at least one example

Open zaquestion opened this issue 7 years ago • 5 comments

zaquestion avatar Apr 28 '18 07:04 zaquestion

ever? or every?

jspreddy avatar May 01 '18 01:05 jspreddy

You know, I looked at that title on multiple occasions and kept feeling like something was :potato:

zaquestion avatar May 01 '18 03:05 zaquestion

That would help this project a lot. I've also looked at tests and there aren't any, it appears. Plus: the command line help script doesn't list available commands.

wkoszek avatar Jun 01 '18 14:06 wkoszek

@wkoszek Is this another confusion with the similar ruby based project? It sounds like you're saying there aren't tests? We have quite a few integration tests located here: https://github.com/zaquestion/lab/tree/master/cmd

You can checkout the coverage here as well https://codecov.io/gh/zaquestion/lab

Regarding help, when you run lab help the git help is printed and we append on our own commands

These GitLab commands are provided by lab:

  ci            Work with GitLab CI pipelines and jobs
  fork          Fork a remote repository on GitLab and add as remote
  issue         Describe, list, and create issues
  mr            Describe, list, and create merge requests
  project       Perform project level operations on GitLab
  snippet       Create a personal or project snippet

From there you can use these help command/flags to get more information. This is where the examples would be store as well.

$ git help ci
Work with GitLab CI pipelines and jobs

Usage:
  lab ci [command]

Available Commands:
  lint        Validate .gitlab-ci.yml against GitLab
  trace       Trace the output of a ci job
  view        (beta) render the CI Pipeline to the terminal

Use "lab ci [command] --help" for more information about a command.

$ git ci --help
Work with GitLab CI pipelines and jobs

Usage:
  lab ci [command]

Available Commands:
  lint        Validate .gitlab-ci.yml against GitLab
  trace       Trace the output of a ci job
  view        (beta) render the CI Pipeline to the terminal

Flags:
  -h, --help   help for ci

Use "lab ci [command] --help" for more information about a command.

Additionally you can view the help with the generated docs over here: https://zaquestion.github.io/lab/

zaquestion avatar Jun 01 '18 18:06 zaquestion

@zaquestion Yes. Feel free to ignore my feedback here. I was trapped by 2 commands having the same name here.

wkoszek avatar Jun 01 '18 18:06 wkoszek