source

package
v0.10.7 Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// GitScheme is the URL scheme used for Git-based requests.
	GitScheme = "git"
	// GitHubDomain is the domain used for GitHub-based requests.
	GitHubDomain = "github.com"
	// GitLabDomain is the domain used for GitLab-based requests.
	GitLabDomain = "gitlab.com/"
	// BitBucketDomain is the domain used for BitBucket-based requests.
	BitBucketDomain = "bitbucket.org/"
)
View Source
const (
	// HttpScheme is the URL scheme for Http-based requests
	HttpScheme = "http"
	// HttpsScheme is the URL scheme for Https-based requests
	HttpsScheme = "https"
)
View Source
const (
	// OCIScheme is the URL scheme for OCI-based requests
	OCIScheme = "oci"
)

Variables

This section is empty.

Functions

func IsGit

func IsGit(src string) bool

IsGit determines whether or not a source is to be treated as a git source.

func IsLocal

func IsLocal(src string) bool

IsLocal determines whether or not a source is to be treated as a local path.

func IsOCI

func IsOCI(src string) bool

IsOCI determines whether or not a URL is to be treated as an OCI URL

func IsRemoteUrl

func IsRemoteUrl(src string) bool

IsRemoteUrl determines whether or not a URL is to be treated as an URL

func IsVCSDomain

func IsVCSDomain(src string) bool

IsVCSDomain determines whether or not a source is to be treated as a VCS source.

func ReadThroughGetter

func ReadThroughGetter(src string, opts ...getter.ClientOption) (string, string, error)

ReadThroughGetter is used to get the source code content from different types of sources (local path, remote URL, or Git source). It gets the pwd, creates temp files, and builds the client to get the code content. If an error occurs during the acquisition process, an error message will be returned.

Types

This section is empty.

Jump to

Keyboard shortcuts

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