Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(docs): Update README for Windows Bash auto-completion and correct… #16

Merged
merged 2 commits into from
Dec 23, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 10 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,18 @@ To install the `cocli` command, do:
```
$ go install github.com/veraison/cocli@latest
```

To configure auto-completion, use the `completion` subcommand. For example, if
`bash` is your shell, you would do something like:
To configure auto-completion, use the `completion` subcommand. For example, if `bash` is your shell, you would do something like:
```
$ cocli completion bash > ~/.bash_completion.d/cocli
$ . ~/.bash_completion
```

If you are setting up in Windows Bash, you can use:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I’m unfamiliar with windows bash. Is this more common than powershell, the cmd terminal, or cygwin? Or do you mean through WSL? Please clarify when you say “windows bash”.

grammar thing: colons should not follow verbs, so please remove from “use:”.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I’ve fixed the grammar issue you pointed out regarding the colon after verbs thank you for catching that and, I was referring to Git Bash.

```
$ mkdir -p ~/.local/share/bash-completion/completions
$ cocli completion bash > ~/.local/share/bash-completion/completions/cocli
$ source ~/.local/share/bash-completion/completions/cocli
```
to get automatic command completion and suggestions using the TAB key.

To get a list of the supported shells, do:
Expand Down Expand Up @@ -231,7 +236,7 @@ Use the `cots create` subcommand to create a CBOR-encoded CoTS. The `environment


```
$ cocli cots create --environment data/cots/env/vendor.json --tafile data/cots/shared_ta.ta
$ cocli cots create --environment data/cots/templates/env/vendor.json --tafile data/cots/shared_ta.ta
```
On success, you should see something like the following printed to stdout:
```
Expand All @@ -242,7 +247,7 @@ The CBOR-encoded CoTS file is stored in the current working directory with a
name derived from its environment template. If you want, you can specify a different
target directory and file name using the `--output` command line switch (abbrev. `-o`)
```
$ cocli cots create --environment data/cots/env/vendor.json --tafile data/cots/shared_ta.ta --output /tmp/myCots.cbor
$ cocli cots create --environment data/cots/templates/env/vendor.json --tafile data/cots/shared_ta.ta --output /tmp/myCots.cbor
>> created "/tmp/myCots.cbor"
```
Note that the output directory, as well as all its parent directories, MUST pre-exist.
Expand Down
Loading