nttcom / fic

Command Line Interface for Flexible InterConnect

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

fic

Command Line Interface for Flexible InterConnect

Installation

go get -u github.com/nttcom/fic

Make sure that PATH includes $GOPATH/bin.

export PATH=$PATH:$GOPATH/bin

Configuration

There are two ways to set your configurations.

  • Export environment variables:
export FIC_USERNAME=****
export FIC_PASSWORD=****
export FIC_TENANT_ID=****
  • Create config file:
touch ~/.fic.yaml
echo "username: ****" >> ~/.fic.yaml
echo "password: ****" >> ~/.fic.yaml
echo "tenant_id: ****" >> ~/.fic.yaml

Execution

fic areas list

Command reference

See fic.md.

Auto completion

Bash

The completion script for Bash can be generated with the command fic completion bash. It depends on bash-completion, which means that you have to install this software first. If you use the completion script on macOS, it requires bash-completion v2 and Bash 4.1+. Kubectl docs show how to install bash-completion and bash in details.

There are two ways to enable auto completion.

  • Source the completion script in your ~/.bashrc file:
echo 'source <(fic completion bash)' >>~/.bashrc
  • Add the completion script to the bash_completion.d directory:
# On Linux
fic completion bash >/etc/bash_completion.d/fic
# On macOS
fic completion bash >/usr/local/etc/bash_completion.d/fic

Zsh

The completion script for Zsh can be generated with the command fic completion zsh.

You need to put the generated script somewhere in your fpath named _fic like this.

fic completion zsh > ${fpath[1]}/_fic

License

Fic is released under the Apache 2.0 license. See LICENSE.

About

Command Line Interface for Flexible InterConnect

License:Apache License 2.0


Languages

Language:Go 99.7%Language:Makefile 0.3%