Commit Graph

15353 Commits

Author SHA1 Message Date
Edward Thomson
f015996fe3 fuzzer: add a revparse fuzzer 2024-02-06 16:56:30 +00:00
Edward Thomson
8bd69574bd fuzzers: provide util functions like repo init
Many fuzzers will need to operate with a repository; extract the
repository initialization from downloads_refs_fuzzer.c into its own
utility area.
2024-02-06 16:56:30 +00:00
Edward Thomson
802f08c696 Merge pull request #6721 from vafada/ssh-timeout
set SSH timeout
2024-02-05 11:54:55 +00:00
Edward Thomson
c3dc87b0c8 docs: update documentation for timeout
The connect timeout *does* apply to SSH connections (at least libssh2),
so update the documentation appropriately.
2024-02-05 10:16:17 +00:00
Edward Thomson
f6d1cd7c3e Merge pull request #6727 from libgit2/ethomson/should_checkout_error
clone: don't swallow error in should_checkout
2024-02-04 22:35:42 +00:00
Edward Thomson
ca864c5914 clone: don't swallow error in should_checkout
When determining whether to check out a branch, we did not actually look
at `should_checkout`'s possible error condition. Disconnect the boolean
"should checkout" value from the potential error code so that it no
longer looks like a function that can be treated as if it returns a
boolean.
2024-02-04 14:40:47 +00:00
Mark
7be7c0c0e0 use git_socket_stream__timeout 2024-01-26 13:37:23 -05:00
Edward Thomson
9b2577f8e0 Merge pull request #6716 from libgit2/ethomson/commit
commit: introduce git_commit_create_from_stage
2024-01-26 10:35:37 +00:00
Mark
392e380463 set SSH timeout 2024-01-18 23:13:14 -05:00
Edward Thomson
55381816e8 commit: support specifying encoding for message 2024-01-15 15:53:19 +00:00
Edward Thomson
67a4d04b59 commit: introduce git_commit_create_from_stage
Provide a simple helper method that allows users to create a commit from
the current index with minimal information.
2024-01-15 15:53:19 +00:00
Edward Thomson
fddfca3526 tests: add cl_assert_equal_oidstr helper method 2024-01-15 00:15:10 +00:00
Edward Thomson
cf19ddc522 commit: fix const declaration
commit functions should take an array of const pointers, not a const
array.
2024-01-15 00:15:10 +00:00
Edward Thomson
048421a404 repo: add head_commit helper
Provide a helper method to provide the HEAD's commit, much like our
existing `head_tree` helper.
2024-01-15 00:15:10 +00:00
Edward Thomson
25e2b9d8c2 Merge branch 'safedir' 2024-01-14 01:06:49 +00:00
Edward Thomson
516749fe7d repo: simplify safe.directory comparison
Keep the `git_str` buf that prevents unnecessary small allocations, and
simplify the comparisons compared to what was there previously.
2024-01-14 01:06:05 +00:00
Edward Thomson
ff58b1699d Merge pull request #6715 from libgit2/ethomson/benchmarks
Benchmarks: add a site to view results
2024-01-12 10:50:47 +00:00
Edward Thomson
a79e48addb benchmarks: publish benchmarks as a static api 2024-01-12 09:57:16 +00:00
Edward Thomson
155eb67f28 benchmarks: use upload-artifact v3 2024-01-12 09:57:16 +00:00
Edward Thomson
45c8caad1c benchmarks: update name to be "libgit2" 2024-01-12 09:57:16 +00:00
Edward Thomson
ef53f20bd7 Merge pull request #6714 from DavHau/fixes
docs: fix mistake in attr.h
2024-01-11 17:27:05 +00:00
DavHau
d6454dd467 docs: fix mistake in attr.h
Also fix indentation
2024-01-11 16:34:36 +07:00
Edward Thomson
ea00310b09 Merge pull request #6707 from libgit2/ethomson/commit
Commit improvements
2024-01-10 02:06:06 +00:00
Edward Thomson
5d60731498 Merge pull request #6709 from libgit2/ethomson/nightly
Fix nightly builds
2024-01-10 02:03:57 +00:00
Edward Thomson
d15be592db ci: move docker container creation to an action 2024-01-10 01:45:15 +00:00
Edward Thomson
ee1d9a065a ci: actually push new build containers
When we update the build container, actually do a push. Remove the
broken build-containers.yml step and just do it in the workflow.
2024-01-10 01:45:15 +00:00
Edward Thomson
235f8e222d ci: update nightlies
There's been drift in our nightly builds vs our main builds.
Unfortunately, sharing steps remains clunky with our matrix-heavy setup.
So this remains copy-pasta.
2024-01-10 01:45:15 +00:00
Edward Thomson
0589ba6ccc ci: use newest libssh2 in bionic builds 2024-01-10 01:44:33 +00:00
Edward Thomson
98075baed2 fixup! commit: introduce git_repository_commit_parents 2023-12-23 15:30:31 +00:00
Edward Thomson
0572884693 commit: introduce git_repository_commit_parents
Emulating `git commit` is clunky - identifying your commit's parents is
part of the problem. Provide a helper to give you the parents given the
current repository state.
2023-12-23 14:11:26 +00:00
Edward Thomson
e2027c006b ci: add noble to build-container matrix 2023-12-23 13:43:48 +00:00
Edward Thomson
198a1b209a Merge pull request #5904 from pluehne/support-authentication-in-push-example
Support authentication in push example
2023-12-21 23:58:46 +00:00
Edward Thomson
517d2cd385 Merge pull request #6697 from libgit2/ethomson/ci
Yet more CI improvements
2023-12-21 21:33:38 +00:00
Edward Thomson
383e5ed581 ci: use ecdsa keys for ssh
Using modern rsa (sha2-256 or sha2-512) with libssh2 is complicated and
depends on numerous factors for support. Just use ecdsa, which is
supported by both libssh2 v1.11.0 and modern OpenSSH (which we use for
our server in CI).
2023-12-21 20:46:47 +00:00
Edward Thomson
8329f7ace3 ci: upgrade focal builds to noble
Let's use the latest & greatest for building our sanitizer / fuzzing
builds.
2023-12-21 20:46:47 +00:00
Edward Thomson
4da4bea79f ci: add an Ubuntu Noble dockerfile 2023-12-21 20:46:47 +00:00
Edward Thomson
edeec76a29 ci: update all images to use libssh2 v1.11.0 2023-12-21 20:46:47 +00:00
Edward Thomson
da1e957325 Merge pull request #6705 from libgit2/ethomson/httpclient
httpclient: clear client->parser.data after use
2023-12-21 20:45:58 +00:00
Edward Thomson
0667c77184 Merge pull request #6704 from libgit2/ethomson/ntlmclient
ntlmclient: update to latest upstream ntlmclient
2023-12-21 20:41:31 +00:00
Edward Thomson
713cf8381a Merge pull request #6642 from yori/yori/fix-remove-unmodified
git_diff_find_similar doesn't always remove unmodified deltas
2023-12-21 20:33:09 +00:00
Edward Thomson
66f587b526 ntlmclient: update to latest upstream ntlmclient 2023-12-21 20:25:55 +00:00
Edward Thomson
52daefc6f3 httpclient: clear client->parser.data after use
Some static code analysis complains that we're putting a stack variable
into client->parser.data (which persists past the function calls). Clear
that on function exit to avoid confusion.
2023-12-21 20:24:05 +00:00
Edward Thomson
a80c526935 diff: move non-blob handling out of is_target 2023-12-21 13:27:27 +00:00
Edward Thomson
3261893710 Merge pull request #6700 from libgit2/ethomson/ubfix
Fix some bugs caught by UBscan
2023-12-20 17:01:13 +00:00
Edward Thomson
01d2adcb60 remote: pass the commit not its id in tests
`git_commit_create_v` takes _commits_ not _commit ids_. Fix the test to
call the API correctly.
2023-12-20 16:38:28 +00:00
Edward Thomson
6816f30cbe Use the correct function definition for function pointers
Passing a function pointer with different parameters is UB, even if
those params are (void *). Use our separate `_cb` functions that will do
the correct casting.
2023-12-20 16:38:28 +00:00
Edward Thomson
032a8c2d5c util: our strcmp cb should use git__strcmp 2023-12-20 16:38:28 +00:00
Edward Thomson
2dee5bd812 Merge pull request #6698 from libgit2/ethomson/deps
zlib: upgrade bundled zlib to v1.3
2023-12-20 12:23:43 +00:00
Edward Thomson
156e08998c Merge pull request #6699 from libgit2/ethomson/bitfield
examples: use unsigned int for bitfields
2023-12-20 12:23:09 +00:00
Edward Thomson
7ebd8a1d46 Merge pull request #6684 from kcsaul/ignore_missing_grafts
Bypass shallow clone support for in-memory repositories
2023-12-20 12:22:49 +00:00