remote

package
v0.2.4 Latest Latest
Warning

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

Go to latest
Published: Jan 1, 2025 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsAlive

func IsAlive(remote Remote) bool

Types

type Remote

type Remote interface {
	String() string                                      // String info for remote
	GetInfo() *info.RemoteInfo                           // Returns basic RemoteInfo struct
	GetType() string                                     // Returns the remote type (e.g. GitLab, Gitea)
	GetNumProjects(*RemoteQueryOpts) int                 // Returns total number of accessible projects
	StreamProjects(*load.ProgressInfo, *RemoteQueryOpts) // Streams projects to chans provided in load.ProgressInfo
}

Any remote needs to be able to return the number of projects the user has access to and also stream all projects along with updates to channels provided by *load.ProgressInfo

type RemoteQueryOpts

type RemoteQueryOpts struct {
	Ctx       context.Context
	OwnerOnly bool
}

Generic options to be passed to any impelenter of the Remote interface

Jump to

Keyboard shortcuts

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