Documentation ¶
Index ¶
- Constants
- Variables
- func AssignAutoConfirmFlag(flags *pflag.FlagSet)
- func BisectRemove() error
- func Confirm(flags *pflag.FlagSet, question string) (bool, error)
- func Die(errMsg string, code int)
- func DieErr(err error)
- func DieFmt(msg string, args ...interface{})
- func DieOnErrorOrUnexpectedStatusCode(response interface{}, err error, expectedStatusCode int)
- func DieOnHTTPError(httpResponse *http.Response)
- func DisableColors()
- func Execute()
- func FmtDiff(d apigen.Diff, withDirection bool)
- func IsValidAccessKeyID(accessKeyID string) bool
- func IsValidSecretAccessKey(secretAccessKey string) bool
- func ListRepositoriesAndAnalyze(ctx context.Context) error
- func Must[T any](v T, err error) T
- func MustParseBranchURI(name, s string) *uri.URI
- func MustParsePathURI(name, s string) *uri.URI
- func MustParseRefURI(name, s string) *uri.URI
- func MustParseRepoURI(name, s string) *uri.URI
- func NewRetryClient(retriesCfg RetriesCfg, transport *http.Transport) *http.Client
- func OpenByPath(path string) (io.ReadSeekCloser, error)
- func PrintTable(rows [][]interface{}, headers []interface{}, paginator *apigen.Pagination, ...)
- func RetrieveError(response interface{}, err error) error
- func ValidArgsRepository(cmd *cobra.Command, args []string, toComplete string) ([]string, cobra.ShellCompDirective)
- func Warning(message string)
- func Write(tpl string, data interface{})
- func WriteIfVerbose(tpl string, data interface{})
- func WriteTo(tpl string, data interface{}, w io.Writer)
- type APIError
- type Bisect
- type BisectSelect
- type Configuration
- type CredentialsError
- type Detailed
- type FromTo
- type FromToBase
- type LocalOperation
- type Pagination
- type PresignMode
- type RetriesCfg
- type StatementDoc
- type Table
- type UnknownConfigError
- type UserMessage
- type WrongEndpointURIError
Constants ¶
View Source
const ( LakectlInteractive = "LAKECTL_INTERACTIVE" DeathMessage = "{{.Error|red}}\nError executing command.\n" DeathMessageWithFields = "{{.Message|red}}\n{{.Status}}\n" WarnMessage = "{{.Warning|yellow}}\n\n" )
View Source
const ( AutoConfirmFlagName = "yes" AutoConfigFlagShortName = "y" AutoConfirmFlagHelp = "Automatically say yes to all confirmations" StdinFileName = "-" )
View Source
const (
CaseInsensitiveWarningMessageFormat = `Directory '%s' is case-insensitive, versioning tools such as lakectl local and git will work incorrectly.`
)
View Source
const (
DefaultBranch = "main"
)
View Source
const (
DefaultMaxIdleConnsPerHost = 100
)
View Source
const (
ParentNumberFlagName = "parent-number"
)
View Source
const (
PathDelimiter = "/"
)
Variables ¶
View Source
var ErrCommitNotFound = errors.New("commit not found")
View Source
var ErrTaskNotCompleted = errors.New("task not completed")
View Source
var (
ErrUnknownOperation = errors.New("unknown operation")
)
Functions ¶
func AssignAutoConfirmFlag ¶ added in v0.31.0
func BisectRemove ¶ added in v0.99.0
func BisectRemove() error
func DieOnErrorOrUnexpectedStatusCode ¶ added in v0.60.1
func DieOnHTTPError ¶ added in v0.58.0
func DisableColors ¶
func DisableColors()
func Execute ¶
func Execute()
Execute adds all child commands to the root command and sets flags appropriately. This is called by main.main(). It only needs to happen once to the rootCmd.
func IsValidAccessKeyID ¶ added in v0.60.0
func IsValidSecretAccessKey ¶ added in v0.60.0
func ListRepositoriesAndAnalyze ¶ added in v0.60.0
func MustParseBranchURI ¶ added in v0.63.0
func MustParsePathURI ¶ added in v0.40.0
func MustParseRefURI ¶ added in v0.40.0
func MustParseRepoURI ¶ added in v0.40.0
func NewRetryClient ¶ added in v1.21.0
func NewRetryClient(retriesCfg RetriesCfg, transport *http.Transport) *http.Client
func OpenByPath ¶ added in v0.33.0
func OpenByPath(path string) (io.ReadSeekCloser, error)
OpenByPath returns a reader from the given path. If the path is "-", it consumes Stdin and opens a readable copy that is either deleted (POSIX) or will delete itself on close (non-POSIX, notably WINs).
func PrintTable ¶
func PrintTable(rows [][]interface{}, headers []interface{}, paginator *apigen.Pagination, amount int)
func RetrieveError ¶ added in v0.53.0
func ValidArgsRepository ¶ added in v0.83.3
func WriteIfVerbose ¶ added in v0.62.0
func WriteIfVerbose(tpl string, data interface{})
Types ¶
type Bisect ¶ added in v0.99.0
type Bisect struct { Created time.Time `json:"created"` Repository string `json:"repository"` BadCommit string `json:"badCommit,omitempty"` GoodCommit string `json:"goodCommit,omitempty"` Commits []*apigen.Commit `json:"commits,omitempty"` }
func (*Bisect) PrintStatus ¶ added in v0.99.0
func (b *Bisect) PrintStatus()
func (*Bisect) SaveSelect ¶ added in v0.99.0
func (b *Bisect) SaveSelect(sel BisectSelect) error
type BisectSelect ¶ added in v0.99.0
type BisectSelect int
const ( BisectSelectGood BisectSelect = iota BisectSelectBad )
type Configuration ¶ added in v0.107.0
type Configuration struct { Credentials struct { AccessKeyID lakefsconfig.OnlyString `mapstructure:"access_key_id"` SecretAccessKey lakefsconfig.OnlyString `mapstructure:"secret_access_key"` } `mapstructure:"credentials"` Server struct { EndpointURL lakefsconfig.OnlyString `mapstructure:"endpoint_url"` Retries RetriesCfg `mapstructure:"retries"` } `mapstructure:"server"` Metastore struct { Type lakefsconfig.OnlyString `mapstructure:"type"` Hive struct { URI lakefsconfig.OnlyString `mapstructure:"uri"` DBLocationURI lakefsconfig.OnlyString `mapstructure:"db_location_uri"` } `mapstructure:"hive"` Glue struct { // TODO(ariels): Refactor credentials to share with server side. Profile lakefsconfig.OnlyString `mapstructure:"profile"` CredentialsFile lakefsconfig.OnlyString `mapstructure:"credentials_file"` DBLocationURI lakefsconfig.OnlyString `mapstructure:"db_location_uri"` Credentials *struct { AccessKeyID lakefsconfig.OnlyString `mapstructure:"access_key_id"` AccessSecretKey lakefsconfig.OnlyString `mapstructure:"access_secret_key"` SessionToken lakefsconfig.OnlyString `mapstructure:"session_token"` } `mapstructure:"credentials"` Region lakefsconfig.OnlyString `mapstructure:"region"` CatalogID lakefsconfig.OnlyString `mapstructure:"catalog_id"` } `mapstructure:"glue"` // setting FixSparkPlaceholder to true will change spark placeholder with the actual location. for more information see https://github.com/treeverse/lakeFS/issues/2213 FixSparkPlaceholder bool `mapstructure:"fix_spark_placeholder"` } Local struct { // SkipNonRegularFiles - By default lakectl local fails if local directory contains a symbolic link. When set, lakectl will ignore the symbolic links instead. SkipNonRegularFiles bool `mapstructure:"skip_non_regular_files"` } `mapstructure:"local"` // Experimental - Use caution when enabling experimental features. It should only be used after consulting with the lakeFS team! Experimental struct { Local struct { POSIXPerm struct { Enabled bool `mapstructure:"enabled"` IncludeUID bool `mapstructure:"include_uid"` IncludeGID bool `mapstructure:"include_gid"` } `mapstructure:"posix_permissions"` } `mapstructure:"local"` } `mapstructure:"experimental"` }
Configuration is the user-visible configuration structure in Golang form. When editing, make sure *all* fields have a `mapstructure:"..."` tag, to simplify future refactoring.
type CredentialsError ¶ added in v0.60.0
func (*CredentialsError) Error ¶ added in v0.60.0
func (e *CredentialsError) Error() string
func (*CredentialsError) GetDetails ¶ added in v0.60.0
func (e *CredentialsError) GetDetails() string
type FromToBase ¶ added in v0.94.1
type LocalOperation ¶ added in v0.108.0
type LocalOperation string
type Pagination ¶
type PresignMode ¶ added in v1.7.0
type RetriesCfg ¶ added in v1.21.0
type RetriesCfg struct { Enabled bool `mapstructure:"enabled"` MaxAttempts int `mapstructure:"max_attempts"` // MaxAttempts is the maximum number of attempts MinWaitInterval time.Duration `mapstructure:"min_wait_interval"` // MinWaitInterval is the minimum amount of time to wait between retries MaxWaitInterval time.Duration `mapstructure:"max_wait_interval"` // MaxWaitInterval is the maximum amount of time to wait between retries }
type StatementDoc ¶
type UnknownConfigError ¶ added in v0.60.0
func (*UnknownConfigError) Error ¶ added in v0.60.0
func (e *UnknownConfigError) Error() string
func (*UnknownConfigError) GetDetails ¶ added in v0.60.0
func (e *UnknownConfigError) GetDetails() string
type UserMessage ¶ added in v0.60.0
type UserMessage struct {
Message string
}
type WrongEndpointURIError ¶ added in v0.60.0
func (*WrongEndpointURIError) Error ¶ added in v0.60.0
func (e *WrongEndpointURIError) Error() string
func (*WrongEndpointURIError) GetDetails ¶ added in v0.60.0
func (e *WrongEndpointURIError) GetDetails() string
Source Files ¶
- abuse.go
- abuse_commit.go
- abuse_create_branches.go
- abuse_link_same_object.go
- abuse_list.go
- abuse_random_delete.go
- abuse_random_read.go
- abuse_random_writes.go
- actions.go
- actions_runs.go
- actions_runs_describe.go
- actions_runs_list.go
- actions_validate.go
- annotate.go
- auth.go
- auth_groups.go
- auth_groups_acl.go
- auth_groups_acl_get.go
- auth_groups_acl_set.go
- auth_groups_add_member.go
- auth_groups_create.go
- auth_groups_delete.go
- auth_groups_list.go
- auth_groups_members.go
- auth_groups_members_list.go
- auth_groups_members_remove.go
- auth_groups_policies.go
- auth_groups_policies_attach.go
- auth_groups_policies_detach.go
- auth_groups_policies_list.go
- auth_policies.go
- auth_policies_create.go
- auth_policies_delete.go
- auth_policies_list.go
- auth_policies_show.go
- auth_users.go
- auth_users_create.go
- auth_users_credentials.go
- auth_users_credentials_create.go
- auth_users_credentials_delete.go
- auth_users_credentials_list.go
- auth_users_delete.go
- auth_users_groups.go
- auth_users_groups_list.go
- auth_users_list.go
- auth_users_policies.go
- auth_users_policies_attach.go
- auth_users_policies_detach.go
- auth_users_policies_list.go
- bisect.go
- bisect_bad.go
- bisect_good.go
- bisect_log.go
- bisect_reset.go
- bisect_run.go
- bisect_start.go
- bisect_view.go
- branch.go
- branch_create.go
- branch_delete.go
- branch_list.go
- branch_protect.go
- branch_reset.go
- branch_revert.go
- branch_show.go
- cat_hook_output.go
- cat_sst.go
- cherry_pick.go
- commit.go
- common_helpers.go
- completion.go
- config.go
- diff.go
- docs.go
- doctor.go
- find_merge_base.go
- fs.go
- fs_cat.go
- fs_download.go
- fs_ls.go
- fs_presign.go
- fs_rm.go
- fs_stage.go
- fs_stat.go
- fs_update_metadata.go
- fs_upload.go
- gc.go
- gc_delete_config.go
- gc_get_config.go
- gc_set_config.go
- import.go
- ingest.go
- local.go
- local_checkout.go
- local_clone.go
- local_commit.go
- local_init.go
- local_list.go
- local_pull.go
- local_status.go
- log.go
- merge.go
- metastore.go
- metastore_copy.go
- metastore_copy_all.go
- metastore_copy_schema.go
- metastore_create_symlink.go
- metastore_diff.go
- metastore_import_all.go
- refs_dump.go
- refs_restore.go
- repo.go
- repo_create.go
- repo_create_bare.go
- repo_delete.go
- repo_list.go
- retry_client.go
- root.go
- show.go
- show_commit.go
- tag.go
- tag_create.go
- tag_delete.go
- tag_list.go
- tag_show.go
- usage.go
- usage_summay.go
- validargs.go
Click to show internal directories.
Click to hide internal directories.