| 1 | package lfshttpscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/lfshttp`/ |
| 2 | |
| 3 | import ( |
| 4 | "fmtscip-go gomod github.com/golang/go/src go1.25.0 fmt/" |
| 5 | "net/httpscip-go gomod github.com/golang/go/src go1.25.0 `net/http`/" |
| 6 | |
| 7 | "github.com/git-lfs/git-lfs/v3/toolsscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools`/" |
| 8 | "github.com/ssgelm/cookiejarparserscip-go gomod github.com/ssgelm/cookiejarparser v1.0.1 `github.com/ssgelm/cookiejarparser`/" |
| 9 | ) |
| 10 | |
| 11 | func isCookieJarEnabledForHostscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/lfshttp`/isCookieJarEnabledForHost().(c *Clientscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/lfshttp`/Client#, host string) bool { |
| 12 | _, cookieFileOk := c.ucscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/lfshttp`/Client#uc..Getscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/config`/URLConfig#Get().("http", fmtscip-go gomod github.com/golang/go/src go1.25.0 fmt/.Sprintfscip-go gomod github.com/golang/go/src go1.25.0 fmt/Sprintf().("https://%v", host), "cookieFile") |
| 13 | |
| 14 | return cookieFileOk |
| 15 | } |
| 16 | |
| 17 | func getCookieJarForHostscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/lfshttp`/getCookieJarForHost().(c *Clientscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/lfshttp`/Client#, host string) (httpscip-go gomod github.com/golang/go/src go1.25.0 `net/http`/.CookieJarscip-go gomod github.com/golang/go/src go1.25.0 `net/http`/CookieJar#, error) { |
| 18 | cookieFile, _ := c.ucscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/lfshttp`/Client#uc..Getscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/config`/URLConfig#Get().("http", fmtscip-go gomod github.com/golang/go/src go1.25.0 fmt/.Sprintfscip-go gomod github.com/golang/go/src go1.25.0 fmt/Sprintf().("https://%v", host), "cookieFile") |
| 19 | |
| 20 | cookieFilePath, err := toolsscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools`/.ExpandPathscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools`/ExpandPath().(cookieFile, false) |
| 21 | if err != nil { |
| 22 | return nil, err |
| 23 | } |
| 24 | |
| 25 | return cookiejarparserscip-go gomod github.com/ssgelm/cookiejarparser v1.0.1 `github.com/ssgelm/cookiejarparser`/.LoadCookieJarFilescip-go gomod github.com/ssgelm/cookiejarparser v1.0.1 `github.com/ssgelm/cookiejarparser`/LoadCookieJarFile().(cookieFilePath) |
| 26 | } |