| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
Unfortunately the original variant makes some incorrect typing
assumptions about commit-graphs which make handling graph chains
difficult to do correctly. This creates a new subpackage and deprecates
the old one. It then adds support commit graph chains.
Signed-off-by: Andrew Thornton <art27@cantab.net>
|
|\
| |
| | |
plumbing: parse the encoding header of the commit object
|
| |
| |
| |
| | |
other part can re-code the commit message according to the encoding to this encoding info
|
|\ \
| |/
|/| |
fuzzing : fuzz testing support for oss-fuzz integration
|
| |
| |
| |
| | |
Signed-off-by: Arjun Singh <ajsinghyadav00@gmail.com>
|
|/
|
|
|
|
|
|
| |
Since the build-tag sha256 was introduced the commit graph code should
be switched to use hash.Size and only use a graph if it has the correct
hash version for the version of go-git that is built.
Signed-off-by: Andrew Thornton <art27@cantab.net>
|
|\
| |
| | |
*: fix some typos
|
| |
| |
| |
| | |
Signed-off-by: Zhizhen He <hezhizhen.yi@gmail.com>
|
|/
|
|
|
|
|
|
| |
When a merge commit is created from merging a signed tag, the tag object
is embedded in the commit object. This commit adds support for this tag
data when encoding and decoding a commit object.
Signed-off-by: Aditya Sirish <aditya@saky.in>
|
|
|
|
|
|
| |
For diagnostics reasons we want to surface error messages coming from VCS providers.
That's why we introduce the reason field to Err struct in http package.
This field can be used by an end user of the library in order to better understand failures.
|
| |
|
|
|
|
| |
Signed-off-by: Arieh Schneier <15041913+AriehSchneier@users.noreply.github.com>
|
|
|
|
| |
Signed-off-by: Arieh Schneier <15041913+AriehSchneier@users.noreply.github.com>
|
|
|
|
| |
Signed-off-by: Arieh Schneier <15041913+AriehSchneier@users.noreply.github.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Git v2.41.0 comes with [changes](https://github.com/git/git/commit/933e3a4ee205353d8f093d5dfcd226fa432c4e58)
that breaks go-git's assumptions for when detecting empty repositories.
Go-git expects a flush instead of the first hash line. Instead, a dummy capabilities^{}
with zero-id is returned. The change aims to allow for identifying
the object format even when cloning empty
repositories.
Signed-off-by: Paulo Gomes <pjbgf@linux.com>
|
|
|
|
|
|
| |
user home. Fixes #578
Signed-off-by: Arieh Schneier <15041913+AriehSchneier@users.noreply.github.com>
|
|
|
|
| |
Signed-off-by: Arieh Schneier <15041913+AriehSchneier@users.noreply.github.com>
|
|
|
| |
Co-authored-by: Paulo Gomes <paulo.gomes.uk@gmail.com>
|
|
|
|
| |
home
|
|
|
|
| |
Signed-off-by: Arieh Schneier <15041913+AriehSchneier@users.noreply.github.com>
|
|\
| |
| | |
git: Allow Initial Branch to be configurable
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| | |
Some areas of the code base were missing error checks,
without them it may be harder to troubleshoot unexpected
behaviours.
Signed-off-by: Paulo Gomes <pjbgf@linux.com>
|
| |
| |
| |
| | |
Signed-off-by: Paulo Gomes <pjbgf@linux.com>
|
| |
| |
| |
| | |
Signed-off-by: Paulo Gomes <pjbgf@linux.com>
|
|/
|
|
| |
Signed-off-by: Paulo Gomes <pjbgf@linux.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add support for custom HTTP and HTTPS proxies for each session.
The tests require server certificate and a matching private key to be
able to run a TLS server and test HTTPS proxy functionality. The cert
and the key are stored in `plumbing/transport/http/testdata/certs` and
were generated using the following command:
`openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout server.key -out server.crt`
Note: All details were left empty, except for the FQDN for which
example.com was used.
Signed-off-by: Sanskar Jaiswal <jaiswalsanskar078@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
objects
Refactor the in-built http transport to cache the underlying http
transport objects mapped to its specific options for each Git transport
object. This lets us reuse the transport for a specific set of configurations
as recommended. (ref: https://pkg.go.dev/net/http#Transport)
If there are no transport specific options provided, the default
transport is used.
Signed-off-by: Sanskar Jaiswal <jaiswalsanskar078@gmail.com>
|
|
|
|
| |
Signed-off-by: Sanskar Jaiswal <jaiswalsanskar078@gmail.com>
|
|
|
|
| |
Signed-off-by: Sanskar Jaiswal <jaiswalsanskar078@gmail.com>
|
|\
| |
| | |
storage: filesystem/dotgit, Improve load packed-refs
|
| | |
|
|\ \
| |/
|/| |
internal: Fix regression in scp-like match
|
| |
| |
| |
| | |
Signed-off-by: Joseda Rios <josriolop@gmail.com>
|
|\ \
| | |
| | | |
*: Add support for initializing SHA256 repositories
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The variable length for plumbing.Hash is defined at build time, blocked by
tag sha256.
This approach was a trade-off between keeping backwards compatibility while
making progress towards supporting SHA256 with a small amount of changes.
Relates to the SHA256 implementation, defined in #706.
Signed-off-by: Paulo Gomes <pjbgf@linux.com>
|
| | |
| | |
| | |
| | |
| | |
| | | |
Relates to the SHA256 implementation, defined in #706.
Signed-off-by: Paulo Gomes <pjbgf@linux.com>
|
| |/
| |
| |
| |
| |
| | |
Relates to #706.
Signed-off-by: Paulo Gomes <pjbgf@linux.com>
|
|/
|
|
|
|
|
|
|
|
|
| |
In a self-contained pack file delta references might point to base
objects stored later in the file.
In this case we need to replace placeholders for external refs with the
actual base object and update the children references.
Fixes: #484
Co-authored-by: Markus Wolf <mail@markus-wolf.de>
|
|\
| |
| | |
fix(ssh): unable to pass a custom HostKeyCallback func
|
| |
| |
| |
| |
| |
| |
| |
| | |
Don't overwrite HostKeyCallback if one is provided.
Fixes: c35b8082c863 ("plumbing: transport/ssh, auto-populate ClientConfig.HostKeyAlgorithms. Fixes #411")
Fixes: https://github.com/go-git/go-git/issues/654
Signed-off-by: Ayman Bagabas <ayman.bagabas@gmail.com>
|
|\ \
| | |
| | | |
fix: don't use the `firstErrLine` when it is empty
|
| |/
| |
| |
| |
| | |
Returning `nil` causes `handleAdvRefDecodeError` to fall back
to `io.ErrUnexpectedEOF`.
|
|\ \
| | |
| | | |
plumbing: support SSH/X509 signed tags
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This commit enables support for extracting the SSH and X509 signatures
from (annotated) Git tags, as an initial step to support the
verification of more signatures than just PGP in go-git.
The ported logic from Git further ensures that we look for a signature
at the tail of an annotation, instead of the first signature we find
in the annotation, as this could theoretically result in a faulty
signature getting detected if part of a an annotation itself (e.g.
by being placed in the middle as part of an inherited message).
For commits, no further change is required as the current extraction
of any signature (format) from `gpgsig` in the commit header is
sufficient for manual verification.
In a future iteration, we could add `signature/ssh` and `signature/x509`
packages to further enable people to deal with verifying other
signatures than PGP. As well as adding additional methods to `Commit`
and `Tag` to provide glue between the packages and the most prominent
user-facing APIs.
Signed-off-by: Hidde Beydals <hidde@hhh.computer>
|
|/
|
|
|
|
|
|
|
|
|
|
| |
Follow-up from #618, at the time the Pure Go sha1cd implementation
was not performant enough to be the default. This has now changed
and the cgo and generic implementations yields similar results.
Users are able to override the default implementation, however this
seems to be a better default as it does not require the use of CGO
during build time.
Signed-off-by: Paulo Gomes <pjbgf@linux.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Implement the same SHA1 collision resistent algorithm used by both the
Git CLI and libgit2.
Only commits with input that match the unavoidable bit conditions will be further
processed, which will result in different hashes.
Which is the same behaviour experienced in the Git CLI and Libgit2.
Users can override the hash algorithm used with:
hash.RegisterHash(crypto.SHA1, sha1.New)
xref links:
https://github.com/libgit2/libgit2/pull/4136/commits/2dfd1294f7a694bfa9e864a9489ae3cb318a5ed0
https://github.com/git/git/commit/28dc98e343ca4eb370a29ceec4c19beac9b5c01e
Signed-off-by: Paulo Gomes <pjbgf@linux.com>
|
|\
| |
| | |
plumbing: object, rename calculation uses too much memory
|
| |
| |
| |
| |
| |
| |
| | |
The size of the similarity matrix is not limited and can be quite big
when lots of files are deleted and added in a commit.
Signed-off-by: Javi Fontan <jfontan@gmail.com>
|
|\ \
| | |
| | | |
plumbing: config, Branch name with hash can be cloned. Fixes #309
|