Rohit Yadav [Wed, 27 Oct 2021 11:49:31 +0000 (17:19 +0530)]
admin: update version to next milestone v6.3.0
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Marcus Sorensen [Tue, 26 Oct 2021 18:06:44 +0000 (12:06 -0600)]
Add arm64 build (#108)
Signed-off-by: Marcus Sorensen <mls@apple.com>
Co-authored-by: Marcus Sorensen <mls@apple.com>
Petr Novák [Thu, 14 Oct 2021 11:34:39 +0000 (13:34 +0200)]
Fixed csv output (#106) (#107)
csv output processed by Writer from encoder/csv
Sina Kashipazha [Tue, 5 Oct 2021 11:38:11 +0000 (13:38 +0200)]
Fixed typo. (#101)
Pearl Dsilva [Tue, 5 Oct 2021 11:37:51 +0000 (17:07 +0530)]
Prevent incorrect timeout value from being set (#103)
Rohit Yadav [Wed, 22 Sep 2021 10:38:57 +0000 (16:08 +0530)]
cmk: fix formating using gofmt
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Pearl Dsilva [Tue, 21 Sep 2021 12:04:32 +0000 (17:34 +0530)]
Update CHANGES.md - 6.2.0 changes (#97)
Abhishek Kumar [Tue, 21 Sep 2021 06:38:27 +0000 (12:08 +0530)]
show meaningful metadata for id autocompletion in some cases (#96)
* show hypervisor,version for listhypervisorcapabilities autocompletion
Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
* fix for listGuestOsMappings
Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
Pearl Dsilva [Tue, 31 Aug 2021 05:38:08 +0000 (11:08 +0530)]
Display output in human readable format (#95)
Pearl Dsilva [Mon, 9 Aug 2021 10:47:56 +0000 (16:17 +0530)]
Make auto completion optional (#91)
* Make auto completion optional
* default autocompletion to true in absense of config
Pearl Dsilva [Mon, 9 Aug 2021 10:46:43 +0000 (16:16 +0530)]
Fix mapping of default output type to json (#93)
Pearl Dsilva [Mon, 9 Aug 2021 06:59:59 +0000 (12:29 +0530)]
Validate user access to config file IF it exists (#88)
Pearl Dsilva [Mon, 9 Aug 2021 06:59:32 +0000 (12:29 +0530)]
Change version references to 6.2.0 (#89)
* Fix cmk version
* Validate user access to config file IF it exists
Pearl Dsilva [Tue, 3 Aug 2021 07:36:58 +0000 (13:06 +0530)]
Avoids adding newline to list/map output data for output format other than 'text' (#87)
Pearl Dsilva [Tue, 3 Aug 2021 07:07:02 +0000 (12:37 +0530)]
Print map in readable format when display format is set to text (#86)
Rohit Yadav [Tue, 3 Aug 2021 05:41:50 +0000 (11:11 +0530)]
Update README.md
Travis .org domain moved to .com
Pearl Dsilva [Tue, 3 Aug 2021 05:34:59 +0000 (11:04 +0530)]
Prevent ACS commands starting with sync to get redirected to API discovery (#82)
* Prevent ACS commands starting with sync to get redirected to API discovery
* change check
Pearl Dsilva [Tue, 3 Aug 2021 05:34:27 +0000 (11:04 +0530)]
Verify user access to config file (#80)
Pearl Dsilva [Tue, 3 Aug 2021 05:33:50 +0000 (11:03 +0530)]
Validate args passed - fail fast in case of invalid args (#79)
sureshanaparti [Thu, 13 May 2021 08:48:46 +0000 (14:18 +0530)]
Inclusivity changes for CloudStack - Renamed default git branch name from 'master' to 'main' and some offensive words/terms as appropriate. (#76)
Sina Kashipazha [Thu, 18 Mar 2021 10:21:02 +0000 (11:21 +0100)]
Added new option to change default cmk config file. (#70)
Cloudmonkey command lets us use a different config file rather than the default one. This pull request added the same functionality to the cmk command.
cmk -c ./my-config
Rohit Yadav [Wed, 29 Jul 2020 06:09:26 +0000 (11:39 +0530)]
snap: snapcraft update
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Thu, 18 Jun 2020 07:16:53 +0000 (12:46 +0530)]
README: add docker badge
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Thu, 18 Jun 2020 07:12:13 +0000 (12:42 +0530)]
changes: update changelog, bump version for next release v6.1.0
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Thu, 18 Jun 2020 06:14:33 +0000 (11:44 +0530)]
cmd: don't sort header when filter keys are specified
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Thu, 18 Jun 2020 05:37:03 +0000 (11:07 +0530)]
output: display key in filtered output for csv, column and table
Fixes #63
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Thu, 18 Jun 2020 05:06:46 +0000 (10:36 +0530)]
config: allow web-proxy support
Now any of the following env variables may be exported before using
cmk with any http/https proxy:
export http_proxy='http://user:password@server:3128'
export https_proxy='http://user:password@server:3128'
export HTTP_PROXY='http://user:password@server:3128'
export HTTPS_PROXY='http://user:password@server:3128'
Or, run cmk like following:
HTTP_PROXY="http://IP:port" cmk
Fixes #49
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Khosrow Moossavi [Wed, 17 Jun 2020 02:57:58 +0000 (22:57 -0400)]
Makefile: Statically building the binary to not depend on gcc compiler (#59)
This is to statically build the cmk binary. It means it doesn't depend on gcc being present to work. The use case is that the cmk binary without this won't work in any alpine docker image.
Rohit Yadav [Mon, 2 Mar 2020 09:14:35 +0000 (14:44 +0530)]
Update CHANGES.md
Rohit Yadav [Thu, 24 Oct 2019 10:29:29 +0000 (15:59 +0530)]
cmk: add Dockerfile
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Mon, 19 Aug 2019 06:09:54 +0000 (11:39 +0530)]
output: jsonify when value is slice or map
Fixes #46 - output value as json when the value of key/row is slice or
map for nested structures.
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Wed, 10 Jul 2019 17:40:34 +0000 (23:10 +0530)]
travis: fix module enable
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Tue, 25 Jun 2019 11:22:08 +0000 (16:52 +0530)]
travis: enable go v1.12
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Tue, 25 Jun 2019 10:04:08 +0000 (15:34 +0530)]
completer: on hostid autocompletion use type=Routing
This fixes the issue that hostid autocompletion only shows Routing
resources (hypervisor hosts) except for the provisionCertificate API.
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Thu, 20 Jun 2019 09:53:48 +0000 (15:23 +0530)]
cmd: fix bug around required params check
This fixes issue for map type of required parameters as seen in the
createTags API where previously an API request would fail when
tags[0].<something> was passed.
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Sat, 6 Apr 2019 16:59:44 +0000 (22:29 +0530)]
snapcraft fixes
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Sat, 6 Apr 2019 16:34:12 +0000 (22:04 +0530)]
snapcraft: update with customised go binary building
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Sat, 6 Apr 2019 16:03:55 +0000 (21:33 +0530)]
Makefile: split the dist to dist-linux
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Sat, 6 Apr 2019 00:12:10 +0000 (05:42 +0530)]
snapcraft badge
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Fri, 5 Apr 2019 23:03:10 +0000 (04:33 +0530)]
snapcraft file
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Tue, 26 Mar 2019 08:07:19 +0000 (13:37 +0530)]
performrelease: emit sha512 based checksum file
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Thu, 14 Mar 2019 07:54:48 +0000 (13:24 +0530)]
cmd: remove `paramcompletion` option which is shipped enabled by default
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Thu, 14 Mar 2019 07:54:01 +0000 (13:24 +0530)]
config: bump version to next 6.1.0-alpha
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Wed, 13 Mar 2019 09:54:23 +0000 (15:24 +0530)]
config: Fix prompt to use the same profile name as loaded
When -p <profilename> is passed via cmd line, cloudmonkey indeed uses
the correctly passed profile name but in shell/interactive mode it
does not print it correctly.
Fixes #47
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Tue, 5 Mar 2019 11:56:48 +0000 (17:26 +0530)]
about: bump version to 6.0.0
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Tue, 5 Mar 2019 11:17:21 +0000 (16:47 +0530)]
cli: fix auto-completion bug
Refactors the logic that finds the auto-completion API.
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Tue, 5 Mar 2019 09:47:56 +0000 (15:17 +0530)]
network: get content from file when arg=@/path is provided (#43)
This adds feature similar to `curl` where you can pass content of a file
via the `arg=@/path/to/file` syntax. This can be useful while uploading
custom certificate via cloudmonkey.
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Tue, 5 Mar 2019 09:19:54 +0000 (14:49 +0530)]
config: add help docs for `set` commands (#40)
This fixes #40, adds human readable docs for set commands and prints
error when an invalid command is added.
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Tue, 5 Mar 2019 08:48:18 +0000 (14:18 +0530)]
config: Implement per profile based api cache (#39)
This fixes #39 and implements logic to have separate api cache on per
profile basis. On changing server profile, user won't need to run
sync, any previously sync-ed cache will be re-used.
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Tue, 29 Jan 2019 06:42:13 +0000 (12:12 +0530)]
Makefile: emit builds for various platforms and architectures
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Tue, 29 Jan 2019 06:14:30 +0000 (11:44 +0530)]
vendor: fix issue in readline option selector
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Tue, 29 Jan 2019 06:14:09 +0000 (11:44 +0530)]
Makefile: emit build for arm32 (raspberrypi)
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Mon, 31 Dec 2018 13:07:41 +0000 (18:37 +0530)]
cli: in case of no possible arg values, return empty string
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sat, 29 Dec 2018 22:23:37 +0000 (03:53 +0530)]
cli: reimplement CLI completer using chzyer/readline (#38)
This moves the prompt implementation back to chzyer/readline with the following changes:
- Use a `tab-tab` and `enter` based approach similar to zsh
- Use readline based selector that removes option values in parenthesis
- Removes old go-prompt implementation and manual history utils
- Heuristics based API arg completion when there is no obvious API by arg name
- Better autocompletion for API args and its response key filter args
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sat, 15 Dec 2018 21:48:52 +0000 (03:18 +0530)]
cmk: debug cmdline args input comma separated for readability
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sat, 15 Dec 2018 21:48:11 +0000 (03:18 +0530)]
history: ignore duplicate and empty inputs for shell history
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sat, 15 Dec 2018 20:52:03 +0000 (02:22 +0530)]
output: Fix json output to not do html escape
Also updates dependencies using `go mod vendor`.
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sat, 15 Dec 2018 20:50:47 +0000 (02:20 +0530)]
vendor: update dependencies
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Fri, 7 Dec 2018 21:50:38 +0000 (03:20 +0530)]
config: Fixes #35 fix panic due to inappropriate config loading
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
Rohit Yadav [Wed, 5 Dec 2018 11:09:10 +0000 (16:39 +0530)]
README: fix golang version
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Mon, 3 Dec 2018 11:51:07 +0000 (17:21 +0530)]
network: remove nested quotes in parameters
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sat, 1 Dec 2018 18:16:04 +0000 (23:46 +0530)]
cli: use cyan as selected colour, don't bolden the input
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sat, 1 Dec 2018 17:51:59 +0000 (23:21 +0530)]
vendor: update vendoring dependencies
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Fri, 30 Nov 2018 19:35:57 +0000 (01:05 +0530)]
network: fix segfault
Fixes segfault issue when response is invalid (nil).
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Fri, 30 Nov 2018 19:18:29 +0000 (00:48 +0530)]
cmk: add git sha and build timestamp from makefile
With this change `cmk -v` will output git sha and build timestamp.
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Fri, 30 Nov 2018 18:58:42 +0000 (00:28 +0530)]
config: bump internal version to 6.0.0-beta2
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Fri, 30 Nov 2018 18:53:49 +0000 (00:23 +0530)]
cli: only show autocompletion options when tab is pressed
This adds constraint that the autocompletion options are only shown
when tab is pressed.
Fixes #31.
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Fri, 30 Nov 2018 18:21:54 +0000 (23:51 +0530)]
cli: allow parameter completion to be disables
This adds the `paramcompletion` setting from python based cloudmonkey
to allow disabling of go-prompt based parameter completion logic.
This also ensure that when cursor is moved back completion won't be
shown to minimize distraction.
Fixes #32
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Fri, 30 Nov 2018 18:20:34 +0000 (23:50 +0530)]
config: add debuggability using -d flag
Signed-off-by: Rohit Yadav <rohit@apache.org>
Pierre-Luc Dion [Fri, 30 Nov 2018 02:37:29 +0000 (21:37 -0500)]
config: create home configdir if not exist (#30)
Fixes #29
Rohit Yadav [Thu, 25 Oct 2018 06:09:37 +0000 (11:39 +0530)]
cli: implement heuristics based completer as a fallback
This implements a API heuristics based options API arg completer based
on the related API name for an arg, or if a list API exists whose name
contains the arg name.
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sun, 21 Oct 2018 19:15:58 +0000 (00:45 +0530)]
cmk: implement file lock for config read/write
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sun, 21 Oct 2018 19:15:20 +0000 (00:45 +0530)]
cmk: implement command line flags support and usage doc
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sun, 21 Oct 2018 19:14:46 +0000 (00:44 +0530)]
cli: implement command line history support
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sun, 21 Oct 2018 19:14:14 +0000 (00:44 +0530)]
cli: fix pipe based output in shell
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sun, 21 Oct 2018 19:13:11 +0000 (00:43 +0530)]
cmk: shlex input, new columnar output, refactorings
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sun, 21 Oct 2018 02:26:34 +0000 (07:56 +0530)]
travis: fix build go mod vendor
This updates by adding changes in vendor from `go mod vendor` and
explicitly enables Go 1.11.1 modules.
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sat, 20 Oct 2018 23:44:26 +0000 (05:14 +0530)]
cmk: rewrite CLI using go-prompt
- Remove readline/prompt-ui based implementation
- Simplify autocompletion logic
- Migrate to go mod
- Update all dependencies
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sat, 20 Oct 2018 18:50:35 +0000 (00:20 +0530)]
Makefile: use -mod=vendor to build using vendor
Rohit Yadav [Sat, 20 Oct 2018 04:25:05 +0000 (09:55 +0530)]
cmk: disable search bar by default on tab-tab completion
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sat, 20 Oct 2018 04:19:27 +0000 (09:49 +0530)]
vendor: update dependencies
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Fri, 19 Oct 2018 18:02:30 +0000 (23:32 +0530)]
cmk: switch to go mod
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Tue, 18 Sep 2018 11:21:26 +0000 (16:51 +0530)]
network: fix variable name to fix lint error
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Tue, 21 Aug 2018 19:42:15 +0000 (01:12 +0530)]
network: handle login session management and expiry
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Thu, 16 Aug 2018 08:23:05 +0000 (13:53 +0530)]
network: Fixes #24 split args to API in two parts
This fixes issue of passing args which has `=` like:
update configuration name=ldap.basedn value="ou=People,dc=ldap,dc=corp,dc=company,dc=com"
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Mon, 2 Jul 2018 07:56:30 +0000 (13:26 +0530)]
output: fix lint issue to fix build failures
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Tue, 26 Jun 2018 11:11:26 +0000 (16:41 +0530)]
output: implement and refactor json, csv, table, text outputs
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Tue, 26 Jun 2018 09:08:46 +0000 (14:38 +0530)]
cmk: rename references to `cmk` and update README
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Tue, 26 Jun 2018 08:56:02 +0000 (14:26 +0530)]
config: fix lint issue and travis failures
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Mon, 25 Jun 2018 18:47:16 +0000 (00:17 +0530)]
network: expire cookie jar based on initial log-in cookies
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Mon, 25 Jun 2018 18:10:29 +0000 (23:40 +0530)]
config: several refactorings and interactive fixes
This also enables log in attempt and reuse of http client once a user
successfully logs in. This speeds up the CLI experience when username
and password credentials are used instead of api/secret keys.
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Mon, 25 Jun 2018 10:48:06 +0000 (16:18 +0530)]
cmd: handle errors well, throw non-zero exit code on error
Signed-off-by: Rohit Yadav <rohit@apache.org>
dahn [Sat, 23 Jun 2018 19:17:35 +0000 (21:17 +0200)]
Makefile: Fix gopath in command (#21)
Fixes build failures in some environments.
Rohit Yadav [Sat, 23 Jun 2018 19:12:24 +0000 (00:42 +0530)]
network: Fix glint error
Rename to jobID
Rohit Yadav [Sat, 23 Jun 2018 15:59:33 +0000 (21:29 +0530)]
config: add inbuilt API precache
This adds API precache based on 4.11.1 which is used in environments
without any existing API cache.
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sat, 23 Jun 2018 15:36:27 +0000 (21:06 +0530)]
cmd: on async job error, also print job response
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sat, 23 Jun 2018 15:14:04 +0000 (20:44 +0530)]
network: implement asyncblock for polling job results
This implements async blocking if config option is enabled by polling
the async job id and showing a cursor.
Add vendor dependency: briandowns/spinner
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Sat, 23 Jun 2018 15:11:46 +0000 (20:41 +0530)]
config: enable asyncblock by default, fix double space
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Wed, 20 Jun 2018 07:46:28 +0000 (13:16 +0530)]
config: change default prompt to :cat:
In loving memory of my kitten 'Happy' 🐈,
from henceforth please keep the default prompt to the change introduced
in this commit.
Signed-off-by: Rohit Yadav <rohit@apache.org>
Rohit Yadav [Wed, 9 May 2018 13:41:40 +0000 (19:11 +0530)]
Fixes #17: handle errors when unable to connect
Signed-off-by: Rohit Yadav <rohit@apache.org>