fishi0x01 / vsh

vsh - HashiCorp Vault interactive shell and cli tool
MIT License
284 stars 12 forks source link

In interactive mode, assume path for command is pwd #94

Closed mattlqx closed 3 years ago

mattlqx commented 3 years ago

When running as shell, the present working path should be assumed for PATH on commands to make it optional. Today it is a required parameter in all cases.

https://localhost:8200 /src/> grep foo
path is required
recursive searches for a pattern starting at a path
Usage: grep [--regexp] [--keys] [--values] SEARCH PATH

Positional arguments:
  SEARCH
  PATH

Options:
  --regexp, -e           Treat search string as a regexp
  --keys, -k             Match against keys (true if -v is not specified)
  --values, -v           Match against values (true if -k is not specified)
  --help, -h             display this help and exit

https://localhost:8200 /src/> grep foo ./
...
fishi0x01 commented 3 years ago

Good idea :+1:

I assume this behavior should be implemented for

grep
replace

I will look into this