Aditya Sirish A Yelgundhalli
692f95930d
gitinterface: Support fetching single object
...
Signed-off-by: Aditya Sirish A Yelgundhalli <ayelgundhall@bloomberg.net>
2025-02-20 13:41:27 -05:00
Aditya Sirish A Yelgundhalli
2923704fa0
gitinterface: Support bare clones
...
Signed-off-by: Aditya Sirish A Yelgundhalli <ayelgundhall@bloomberg.net>
2025-02-04 11:18:02 -05:00
Aditya Sirish
79efbf235f
gitinterface: Support types for tree entries
...
Signed-off-by: Aditya Sirish <aditya@saky.in>
2025-02-02 14:07:34 -05:00
Aditya Sirish
3236696c98
*: Extend TreeBuilder to reuse existing trees
...
If an intermediate tree already exists and we know this ahead of time,
we should use it without recreating it with all of its contents resolved
and written recursively. This commit adds support for such cases and
renames TreeBuilder's APIs to generalize away from accepting blob IDs
only.
Signed-off-by: Aditya Sirish <aditya@saky.in>
2025-02-02 12:06:18 -05:00
Pat Zielinski
d571facb8d
*: Add copyright notice to code files
...
Signed-off-by: Pat Zielinski <70954403+patzielinski@users.noreply.github.com>
2024-09-27 15:28:12 -04:00
Aditya Sirish A Yelgundhalli
fe6d1d343a
*: Drop old gitinterface APIs
...
This commit also renames ReplacementTreeBuilder to TreeBuilder.
Signed-off-by: Aditya Sirish A Yelgundhalli <ayelgundhall@bloomberg.net>
2024-07-01 10:21:25 -04:00
Aditya Sirish A Yelgundhalli
b0c6bac73b
gitinterface: Fixes for tests
...
Signed-off-by: Aditya Sirish A Yelgundhalli <ayelgundhall@bloomberg.net>
2024-06-11 16:46:22 -04:00
Pat Zielinski
5c9403efcf
gitinterface: Add remaining sync tests
...
Signed-off-by: Pat Zielinski <70954403+patzielinski@users.noreply.github.com>
2024-06-07 10:30:59 -04:00
Pat Zielinski
79deec165f
gitinterface: Add (some) sync tests
...
Signed-off-by: Pat Zielinski <70954403+patzielinski@users.noreply.github.com>
2024-06-06 16:43:38 -04:00
Aditya Sirish
2fd0988424
dep: Remove vendored copy of go-git
...
Signed-off-by: Aditya Sirish <aditya@saky.in>
2023-11-29 21:04:54 +05:30
Billy Lynch
d57191618a
Remove module replace in favor of a package fork.
...
This removes the sub-go.mod in favor of updating all references to the
third_party/go-git package.
This lets users `go install` from outside of the module.
Signed-off-by: Billy Lynch <billy@chainguard.dev>
2023-10-25 19:25:56 -04:00
Aditya Sirish
f24f7f27fc
gitinterface: Add fastForwardOnly flag to Fetch
...
Signed-off-by: Aditya Sirish <aditya@saky.in>
2023-10-11 23:18:07 -04:00
Aditya Sirish
be3eece7be
gitinterface: Simplify tmp dir handling in tests
...
Signed-off-by: Aditya Sirish <aditya@saky.in>
2023-10-11 21:31:29 -04:00
Aditya Sirish
483c6eb2a6
gitinterface: Set HEAD in fetch tests
...
Signed-off-by: Aditya Sirish <aditya@saky.in>
2023-10-11 21:31:29 -04:00
Aditya Sirish
ef38590f91
*: Drop explicit trackRemote option
...
Now, the remote tracker is always updated. If gitinterface.Fetch is used
with a refName, it assumes the default is to fetch to the same target in
the local repository. By default, it also updates the remote tracker.
For more granular control, FetchRefSpec must be used.
Signed-off-by: Aditya Sirish <aditya@saky.in>
2023-10-11 21:31:28 -04:00
Pat Zielinski
d0905e7816
Add SPDX License Identifiers to code files
...
Signed-off-by: Pat Zielinski <70954403+patzielinski@users.noreply.github.com>
2023-10-09 08:09:34 -04:00
Aditya Sirish
12a29c17aa
gitinterface: Add syncing features
...
Signed-off-by: Aditya Sirish <aditya@saky.in>
2023-09-12 13:06:53 -04:00