enfcli
The enfcli
- Xaptum's CLI tool - allows you to easily manage your ENF resources. Check out the docs for examples of the various enfcli
commands available for you to use.
Installation
To install enfcli
release versions of the gem run
$ gem install enfcli
To update existing enfcli
installation to latest release version
$ gem update enfcli
To install enfcli
pre-release verions
$ gem install enfcli --pre
Usage
There are two ways to connect to the ENF through the enfcli
.
Configuration file
The recommended way to connect to the ENF through the
enfcli
is by creating a configuration file (.xaptum_config.json
) in your home directory. Theenfcli
will read your configuration from this file whenever you attempt to connect, and will save you from entering in yourhost
andusername
parameters each time. The following command creates a config file in your home directory.$ enfcli create-config-file --host=<HOST> --user=<USERNAME> Config file created successfully at /Users/dylanirlbeck/.xaptum_config.json!
You can view your current configuration at any time by doing the following:
$ enfcli display-config-file {"host":<HOST>,"user":<USERNAME>}
With your configuration file created, connect to the ENF by simply doing
$ enfcli Connecting to <HOST>..... Enter Password: <PASSWORD>
CLI parameters
Instead of a configuration file, you can always connect to the ENF through the
enfcli
by providing your host and username as command line parameters$ enfcli --host <host> --user <user>
Whichever way you choose, you'll be prompted for your account password as the final step of authentication. Once authenticated, type help
in enfcli
prompt to list all available enfcli
commands
enfcli-user@acme> help
Development
- Clone the repository
- Create a new branch
bash git checkout -b <GIT_USER_NAME>/<BRANCH_NAME>
- Bump the version
bash make bump-pre
- Ensure code is formatted using
rufo
. The build process will fail if the code is not formatted.bash make format
NOTE: Do not fork the repository
Release
enfcli
pre-release and release versions are automatically published to RubyGems by the build process. Each commit to master
branch publishes a pre-release version of the gem.
Publishing Pre-Release version
- Open a pull request to merge the feature branch into
master
- After review and approval merge feature branch into
master
- The build process publishes a pre-release version if gem version matches one of the following patterns:
MAJOR.MINOR.PATCH-alpha
MAJOR.MINOR.PATCH-beta
MAJOR.MINOR.PATCH-rc
Publishing a Release version
- Update
enfcli
version toMAJOR.MINOR.PATCH
inlib/enfcli/version.rb
and commit the change tomaster
- Create and push a tag with the same name as the version
- The build process publishes a release version of the gem
License
Copyright 2018 Xaptum, Inc.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this work except in compliance with the License. You may obtain a copy of the License from the LICENSE.txt file or at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.