Documentation
¶
Index ¶
- Constants
- func CheckSumForVersionFile(sdkName, newSha256 string) (ok bool, fPath string)
- func FilterVersionItem(item Item) (ok bool)
- func GetSDKSortedRows(ss SDKList) (rows []table.Row)
- func GetVersionFilePath(sdkName string) (fPath string)
- func GetVersionList(sdkName, newSha256 string) (filteredVersions map[string]Item)
- func GetVersionsSortedRows(filteredVersions map[string]Item) (rows []table.Row)
- func SortVersionAscend(versions []table.Row)
- func SortVersions(versions []table.Row)
- type AdditionalEnv
- type AdditionalEnvList
- type BinaryRename
- type DirItems
- type DirPath
- type Downloader
- type FileItems
- type InstallerConfig
- type Item
- type SDK
- type SDKList
- type SDKVersion
- type Version
- type VersionList
Constants ¶
View Source
const ( Conda string = "conda" CondaForge string = "conda-forge" Coursier string = "coursier" Unarchiver string = "unarchiver" Executable string = "executable" Dpkg string = "dpkg" Rpm string = "rpm" )
View Source
const (
SDKListFileName string = "sdk_list.json"
)
Variables ¶
This section is empty.
Functions ¶
func CheckSumForVersionFile ¶
Download version list file.
func FilterVersionItem ¶
func GetSDKSortedRows ¶
func GetVersionFilePath ¶ added in v0.6.4
func GetVersionList ¶
func GetVersionsSortedRows ¶
func SortVersionAscend ¶
func SortVersions ¶
SortVersions sorts a slice of version strings in descending order.
Types ¶
type AdditionalEnv ¶
type AdditionalEnvList ¶
type AdditionalEnvList []AdditionalEnv
type BinaryRename ¶
type Downloader ¶
func NewDownloader ¶
func NewDownloader() (d *Downloader)
type InstallerConfig ¶
type InstallerConfig struct {
FlagFiles *FileItems `toml:"flag_files"`
FlagDirExcepted bool `toml:"flag_dir_excepted"`
BinaryDirs *DirItems `toml:"binary_dirs"`
BinaryRename *BinaryRename `toml:"binary_rename"`
AdditionalEnvs AdditionalEnvList `toml:"additional_envs"`
}
Installation configs
func GetSDKInstallationConfig ¶
func GetSDKInstallationConfig(sdkName, newSha256 string) (ic InstallerConfig)
SDK installation config file.
type Item ¶
type Item struct {
Url string `json:"url"` // download url
Arch string `json:"arch"` // amd64 | arm64
Os string `json:"os"` // linux | darwin | windows
Sum string `json:"sum"` // Checksum
SumType string `json:"sum_type"` // sha1 | sha256 | sha512 | md5
Size int64 `json:"size"` // Size in bytes
Installer string `json:"installer"` // conda | conda-forge | coursier | unarchiver | executable | dpkg | rpm
LTS string `json:"lts"` // Long Term Support
Extra string `json:"extra"` // Extra Info
}
type SDK ¶
type SDK struct {
Sha256 string `json:"sha256"`
HomePage string `json:"homepage"`
InstallConfSha256 string `json:"install_conf_sha256"`
}
Download SDK List file.
type SDKVersion ¶
type SDKVersion []Item
type Version ¶
Version represents a version number.
func ParseVersion ¶
ParseVersion parses a version string into a Version struct.
type VersionList ¶
type VersionList map[string]SDKVersion
Click to show internal directories.
Click to hide internal directories.