# Functions
AddRecent : add to recent file.
ChangeSymlink : move symlink to existing binary.
CheckDirExist : check if directory existdir=path to filereturn bool.
CheckDirHasTGBin : // check binary exist (TODO UNIT TEST).
Check if user has permission to directory :dir=path to filereturn bool.
CheckFileExist : check if file exist in directory.
CheckSymlink : check file is symlink.
ConvertExecutableExt : convert excutable with local OS extension.
CreateDirIfNotExist : create directory if directory does not exist.
CreateRecentFile : create a recent file.
CreateSymlink : create symlink.
DownloadFromURL : Downloads the binary from the source url.
GetCurrentDirectory : return the current directory.
GetFileName : remove file ext.
GetHomeDirectory : return the home directory.
GetInstallLocation : get location where the terraform binary will be installed, will create a directory in the home location if it does not exist.
GetRecentVersions : get recent version from file.
GetSemver : returns version that will be installed based on server constaint provided.
GetTFLatest : Get the latest terraform version given the hashicorp url.
GetTFLatestImplicit : Get the latest implicit terraform version given the hashicorp url.
GetTFList : Get the list of available terraform version given the hashicorp url.
GetTFURLBody : Get list of terraform versions from hashicorp releases.
Install : Install the provided version in the argument.
InstallableBinLocation : Checks if terraform is installable in the location provided by the user.If not, create $HOME/bin.
IsDirEmpty : check if directory is empty (TODO UNIT TEST).
NewCommand : get command.
Path : returns path of directory value=path to file.
Print invalid TF version.
Print invalid TF version.
ReadLines : Read a whole file into the memory and store it as array of lines.
RemoveDuplicateVersions : remove duplicate version.
RemoveFiles : remove file.
RemoveSymlink : remove symlink.
RenameFile : rename file name.
ValidateSemVer : Goes through the list of terraform version, return a valid tf version for contraint provided.
Unzip will decompress a zip archive, moving all files and folders within the zip file (parameter 1) to an output directory (parameter 2).
ValidMinorVersionFormat : returns valid MINOR version format For example: 0.1 = valid
// For example: a.1.2 = invalid
// For example: 0.1.2 = invalid
*/.
ValidVersionFormat : returns valid version format For example: 0.1.2 = valid
// For example: 0.1.2-beta1 = valid
// For example: 0.1.2-alpha = valid
// For example: a.1.2 = invalid
// For example: 0.1.
VersionExist : check if requested version exist.
WriteLines : writes into file.