MCPcopy Create free account
hub / github.com/entireio/git-sync / addTargetEndpoint

Function addTargetEndpoint

cmd/git-sync/flags.go:20–25  ·  view source on GitHub ↗
(cmd *cobra.Command, ep *gitsync.Endpoint)

Source from the content-addressed store, hash-verified

18}
19
20func addTargetEndpoint(cmd *cobra.Command, ep *gitsync.Endpoint) {
21 cmd.Flags().StringVar(&ep.URL, "target-url", "", "target repository URL")
22 cmd.Flags().BoolVar(&ep.FollowInfoRefsRedirect, "target-follow-info-refs-redirect",
23 envBool("GITSYNC_TARGET_FOLLOW_INFO_REFS_REDIRECT"),
24 "send follow-up target RPCs to the final /info/refs redirect host")
25}
26
27func addSourceAuth(cmd *cobra.Command, auth *gitsync.EndpointAuth) {
28 cmd.Flags().StringVar(&auth.Token, "source-token", envOr("GITSYNC_SOURCE_TOKEN", ""), "source token/password")

Callers 2

newSyncLikeCmdFunction · 0.85
newBootstrapCmdFunction · 0.85

Calls 1

envBoolFunction · 0.85

Tested by

no test coverage detected