aid

package
v0.0.0-...-7ecf171 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 14, 2021 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildTemplate

func BuildTemplate(name string) error

BuildTemplate build the given template located under clencli/ directory (without the .tmpl extension)

func ConfigurationsDirectoryExist

func ConfigurationsDirectoryExist() bool

ConfigurationsDirectoryExist returns `true` if the configuration directory exist, `false` otherwise

func ConfigurationsFileExist

func ConfigurationsFileExist() bool

ConfigurationsFileExist returns `true` if the configuration file exist, `false` otherwise

func CreateBasicProject

func CreateBasicProject(cmd *cobra.Command, name string) error

CreateBasicProject creates a basic project

func CreateCloudFormationProject

func CreateCloudFormationProject(cmd *cobra.Command, name string) error

CreateCloudFormationProject creates an AWS CloudFormation project

func CreateCloudProject

func CreateCloudProject(cmd *cobra.Command, name string) error

CreateCloudProject copies the necessary templates for cloud projects

func CreateConfigurationsDirectory

func CreateConfigurationsDirectory() (bool, string)

CreateConfigurationsDirectory creates the configuration directory, returns `true` if the configuration directory exist, `false` otherwise

func CreateTerraformProject

func CreateTerraformProject(cmd *cobra.Command, name string) error

CreateTerraformProject creates a HashiCorp Terraform project

func CredentialsFileExist

func CredentialsFileExist() bool

CredentialsFileExist returns `true` if the credentials file exist, `false` otherwise

func DeleteConfigurationFile

func DeleteConfigurationFile() error

DeleteConfigurationFile delete the credentials file

func DeleteConfigurationsDirectory

func DeleteConfigurationsDirectory() error

DeleteConfigurationsDirectory delete the configurations directory

func DeleteCredentialFile

func DeleteCredentialFile() error

DeleteCredentialFile delete the credentials file

func DownloadGitIgnore

func DownloadGitIgnore(cmd *cobra.Command, input string) (bool, error)

DownloadGitIgnore ..

func DownloadPhoto

func DownloadPhoto(params model.UnsplashRandomPhotoParameters, cred model.Credential, photoSizes []string) error

DownloadPhoto downloads a photo and saves into downloads/unsplash/ folder It creates the downloads/ folder if it doesn't exists

func DownloadPhotoByID

func DownloadPhotoByID(r model.UnsplashGetPhotoResponse, size string) error

DownloadPhotoByID TODO ...

func GetAppInfo

func GetAppInfo() model.App

GetAppInfo return information about clencli settings

func GetGitIgnoreList

func GetGitIgnoreList() string

GetGitIgnoreList ...

func GetModelFromFlags

func GetModelFromFlags(cmd *cobra.Command) model.UnsplashRandomPhotoParameters

GetModelFromFlags fills the parameters onto the Unsplash Random Photo Parameters struct

func GetPhoto

GetPhoto TODO..

func GetSensitiveUserInput

func GetSensitiveUserInput(cmd *cobra.Command, text string, info string) (string, error)

GetSensitiveUserInput get sensitive input as string

func GetSensitiveUserInputAsString

func GetSensitiveUserInputAsString(cmd *cobra.Command, text string, info string) string

GetSensitiveUserInputAsString get sensitive input as string

func GetUserInputAsBool

func GetUserInputAsBool(cmd *cobra.Command, text string, info bool) bool

GetUserInputAsBool prints `text` on console and return answer as `boolean`

func GetUserInputAsString

func GetUserInputAsString(cmd *cobra.Command, text string, info string) string

GetUserInputAsString prints `text` on console and return answer as `string`

func InitCustomized

func InitCustomized(profile string, config model.Configurations) bool

InitCustomized TODO...

func ReadConfig

func ReadConfig(name string) (*viper.Viper, error)

ReadConfig returns the viper instance of the given configuration `name`

func ReadConfigAsViper

func ReadConfigAsViper(configPath string, configName string, configType string) (*viper.Viper, error)

ReadConfigAsViper returns...

func ReadTemplate

func ReadTemplate(fileName string) (*viper.Viper, error)

ReadTemplate read the given template under clencli/*.yaml

func RequestRandomPhoto

RequestRandomPhoto retrieves a single random photo, given optional filters.

func SaveGetPhotoResult

func SaveGetPhotoResult(r model.UnsplashGetPhotoResponse)

SaveGetPhotoResult TODO ...

func SetupLoggingLevel

func SetupLoggingLevel(level string) error

SetupLoggingLevel set logrus level

func SetupLoggingOutput

func SetupLoggingOutput(path string) error

SetupLoggingOutput set logrun output file

func UpdateReadMeLogoURL

func UpdateReadMeLogoURL(readme model.ReadMe, response model.UnsplashRandomPhotoResponse) error

UpdateReadMeLogoURL TODO ...

func WriteInterfaceToFile

func WriteInterfaceToFile(in interface{}, path string) error

WriteInterfaceToFile write the given interface into a file

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL