Documentation ¶
Index ¶
- Variables
- func AddFile(dir string, file string) error
- func AskMultipleChoices(message string, choices []string) string
- func AskUser(message string) string
- func AskUserWithDefault(message string, defaultValue string, shouldPrompt bool) string
- func AskYesOrNo(message string, defaultValue bool, shouldPrompt bool) bool
- func Commit(dir string, message string) error
- func CompareVersions(desired string, actual string) (bool, error)
- func ContainsString(slice []string, desired string) bool
- func DownloadSingleFile(tempDir string, temp DownloadFile, flagBranch string) error
- func DownloadTemplates(tempDir string, td TemplateDefinition, templatePath string, flagBranch string) error
- func Fetch(url string, mod *time.Time) (io.ReadCloser, error)
- func FetchJSON(url string, mod *time.Time, v interface{}) error
- func FileExists(filename string) bool
- func GetAllowedNodeVersions() []string
- func GetClosedAllowedNodeVersion(major uint64, minor uint64, patch uint64) string
- func GetDefaultNodeVersion() string
- func GetDependencyVersion(packageJsonFile string, dependencyNames ...string) (bool, string)
- func GetFramework(composerJSONfile string, framework string) (bool, string)
- func GetGemVersion(gemFile string, gemNames ...string) (bool, string)
- func GetMeteorVersion(meteorReleaseFile string) (bool, string)
- func GetNodeDatabase(packageJsonFile string, databaseNames ...string) (bool, string)
- func GetNodeVersion(packageJsonFile string) (bool, []string)
- func GetPHPDatabase(composerJSONfile string, databaseName string) (bool, string)
- func GetPHPVersion(composerJSONfile string) (bool, string)
- func GetPythonVersion() (hasFound bool, version string)
- func GetRubyVersion(gemFile string) (bool, string)
- func GetScriptsStart(packageJsonFile string) (bool, string)
- func GetSupportedNodeFrameworks() []string
- func GitRootDir(dir string) (string, error)
- func HasGit(dir string) bool
- func IsDjangoProject(rootDir string) bool
- func LocalGitBranch(dir string) string
- func PadVersionNumber(version string) string
- func ParseEnvironmentVariables(line string) (string, error)
- func ParseLineForGem(gemName string, line string) (bool, string)
- func ParsePort(command string) (hasFound bool, port string)
- func ParseUniqueInt(line string) (string, error)
- func PathRelativeToGitRoot(dirPath string) (string, error)
- func PythonPackages(requirementsTxt string) ([]string, error)
- func RemoteGitUrl(dir string) string
- func RemovePortIfEnvVar(command string) string
- func SetAllowedNodeVersions(versions []string)
- func Tar(source, target string) error
- type Database
- type DownloadFile
- type EnvVar
- type Lister
- type PortMapping
- type Process
- type Service
- type TemplateDefinition
Constants ¶
This section is empty.
Variables ¶
View Source
var ( MsgReset string = ansi.ColorCode("reset") PrintTitle, PrintlnTitle = printers(" ", ansi.ColorCode("green+h")) PrintL0, PrintlnL0 = printers(" ", ansi.ColorCode("magenta")) PrintL1, PrintlnL1 = printers(" ", ansi.ColorCode("white")) PrintL2, PrintlnL2 = printers(" ----> ", ansi.ColorCode("black+h")) PrintError, PrintlnError = printers(" ", ansi.ColorCode("red")) PrintWarning, PrintlnWarning = printers(" ", ansi.ColorCode("yellow")) )
Functions ¶
func AskMultipleChoices ¶
func AskUserWithDefault ¶
func ContainsString ¶
func DownloadSingleFile ¶
func DownloadSingleFile(tempDir string, temp DownloadFile, flagBranch string) error
func DownloadTemplates ¶
func DownloadTemplates(tempDir string, td TemplateDefinition, templatePath string, flagBranch string) error
func FileExists ¶
func GetAllowedNodeVersions ¶
func GetAllowedNodeVersions() []string
func GetDefaultNodeVersion ¶
func GetDefaultNodeVersion() string
func GetDependencyVersion ¶
func GetGemVersion ¶
returns bool = found any of the gems or not and string = the version of the first found
func GetMeteorVersion ¶
func GetNodeDatabase ¶
func GetNodeVersion ¶
Looks for node version in the package.json. If found returns true, version if not false, ""
func GetPHPDatabase ¶
func GetPHPVersion ¶
Looks for node version in the package.json. If found returns true, version if not false, ""
func GetPythonVersion ¶
func GetRubyVersion ¶
Looks for ruby version in the gemfile. If found returns true, version if not false, ""
func GetScriptsStart ¶
func GetSupportedNodeFrameworks ¶
func GetSupportedNodeFrameworks() []string
func GitRootDir ¶
func IsDjangoProject ¶
func LocalGitBranch ¶
func PadVersionNumber ¶
func ParseLineForGem ¶
Checks a line to see if it contains the given gem. returns true, version or false, ""
func ParseUniqueInt ¶
func PathRelativeToGitRoot ¶
func PythonPackages ¶
func RemoteGitUrl ¶
func RemovePortIfEnvVar ¶
func SetAllowedNodeVersions ¶
func SetAllowedNodeVersions(versions []string)
Types ¶
type DownloadFile ¶
type EnvVar ¶
func NewEnvMapping ¶
type PortMapping ¶
func NewInternalPortMapping ¶
func NewInternalPortMapping(container string) *PortMapping
func NewPortMapping ¶
func NewPortMapping() *PortMapping
type Process ¶
func ParseProcfile ¶
type TemplateDefinition ¶
type TemplateDefinition struct { Version string `json:"version"` Dockerfiles []DownloadFile `json:"dockerfiles"` ServiceYmls []DownloadFile `json:"service-ymls"` DockerComposeYmls []DownloadFile `json:"docker-compose-ymls"` BundleManifest []DownloadFile `json:"bundle-manifest-jsons"` }
Click to show internal directories.
Click to hide internal directories.