Commit Graph

60 Commits

Author SHA1 Message Date
Kiril Videlov
c0710a05e7
captrure update branch errors in snapshot 2024-06-08 22:31:23 +02:00
Kiril Videlov
9c56a5f040 remove proxy core::git::Oid 2024-06-05 22:56:03 +02:00
Kiril Videlov
4a54f74aa2 remove field access 2024-06-05 01:19:23 +02:00
Kiril Videlov
e63081c69d remove core::git::Repository shell type 2024-06-05 01:11:10 +02:00
Mattias Granlund
d0993b8acd Update updated_at timestamp after mutations
- also drops unnecessary `.context()` from most `vb_state.set_branch(...)` calls
2024-06-04 13:52:58 +02:00
Kiril Videlov
bc16fadcc5 move commit signing to git2 extension trait 2024-06-03 01:04:14 +02:00
Kiril Videlov
4ae1847a28 remove core::git::Reference type 2024-06-02 19:03:03 +02:00
Kiril Videlov
879a07da64 remove core::git::Index 2024-06-02 17:57:18 +02:00
Sebastian Thiel
e7c1d6033a
Remove all errors that don't trigger a custom code or context 2024-06-01 14:34:16 +02:00
Sebastian Thiel
61a53c6346
Another pass at removing ProjectConflict
As this causes quite a lot of changes, there is this commit to capture them.
2024-06-01 14:34:13 +02:00
Sebastian Thiel
20d84247e9
Prune Code to only what's used by the UI
Also adjust the `Code` documentation to clarify this - otherwise
we will have more and more variants and nobody actually cares.

The frontend code is adjusted as well, as its `Code` counterpart
contained unsused variants which are now removed.
2024-06-01 14:32:27 +02:00
Kiril Videlov
62a3d02303 remove git::signature shell type 2024-05-29 23:51:26 +02:00
Kiril Videlov
45979b4c85 remove usage of git::Commit 2024-05-29 17:33:57 +02:00
Sebastian Thiel
1abb464845
Merge pull request #3885 from gitbutlerapp/rust-remote-tweaks-for-byron
Tweaks to remotes code
2024-05-29 15:13:02 +02:00
Kiril Videlov
be149a5569 remove git::Tree in favor of just git2::Tree 2024-05-29 14:30:59 +02:00
Caleb Owens
faa476875d Replace &BranchId to BranchId 2024-05-29 11:07:36 +02:00
Caleb Owens
b8a1dcb2f0
Revert "Replace integer timestamps with Duration" 2024-05-24 09:40:52 +01:00
Caleb Owens
4a7e5f48dd Merge origin/master into core-util-duration-updates 2024-05-23 14:04:54 +02:00
Caleb Owens
d55260c96a Use Duration rather than various integer times for time 2024-05-23 14:02:48 +02:00
Mattias Granlund
cd419eca67 Refactor how we merge in commits from branch upstream
- send change_id to frontend for `RemoteCommit`
- split up massive function into three
- add a couple of checks to prevent unexpected state
- rebase if force push allowed (needs toggle)
2024-05-23 10:58:59 +02:00
Scott Chacon
b0c5c07a57
some change-id based tests 2024-05-15 15:21:19 +02:00
Scott Chacon
202c551bc7
remove signing setting 2024-05-14 13:15:11 +02:00
Scott Chacon
d944cad533 merge upstream
temp
2024-05-14 10:25:29 +02:00
Kiril Videlov
81e948774f
fix test 2024-05-12 23:42:04 +02:00
Scott Chacon
51f9769024 sign commits with real git
in the strangest possible way
2024-05-07 15:15:25 +02:00
Josh Junon
dce8ead62f
use simpler virtual branch handle fetch in tests (and fix strange uncaught compilation error) 2024-05-06 20:22:40 +02:00
Scott Chacon
46fe51eeda fix rust errors 2024-05-06 14:30:25 +02:00
Sebastian Thiel
a08e2be07e
OwnershipClaims now allocates less
This is done by allowing to take (rust) ownership where internally
the item is consumed.
2024-04-26 07:08:43 +02:00
Mattias Granlund
8dd4a92622 Use empty vector instead of None 2024-04-24 08:15:01 +01:00
Mattias Granlund
055c7e7119 Use blame for hunk locking
- replaces commit walking with a git blame
- limited to specific hunk lines
- earliest_commit set to default target
- lock if any blame other than boundary commit
- intersection uses context lines
2024-04-24 08:15:01 +01:00
Sebastian Thiel
568d35fa90
refactor
- assure that `repository` can't be misused in `hunks_by_filepath()`.
- Use more obvious enumeration to describe and match on lines
- make clear that diff_lines can be a hash
- avoid multiple hashmasps if one would do
- `Hunk::hash_diff` now uses lines with terminator to be close to being a true content hash. This was probably intended by the code originally.
2024-04-21 11:35:26 +02:00
Sebastian Thiel
04bcf3b8b2
adjust Hunk::hash_diff() to produce unique hashes based on input.
The input is variable and maybe empty, maybe a diff header followed
by diff-lines, and it could be an SHA1 of a binary file, which now is
hashed like any other content.
2024-04-21 11:35:26 +02:00
Sebastian Thiel
fb83dafd8b
Make using Hunk::hash with something that's not a hash a hard error.
Fix all occasions where this seems to be used like this.
2024-04-21 11:35:25 +02:00
Sebastian Thiel
eb0db39387
Strongly type the hunk-hash to avoid String, but remain compatible.
This change also avoids allocating for the hash, while keeping
everything else the same.
2024-04-21 11:35:25 +02:00
Kiril Videlov
ee62577012
remove gb_repository from remote 2024-04-21 09:16:14 +02:00
Kiril Videlov
6334336e7b
remove branch reader / writer 2024-04-19 23:48:11 +02:00
Kiril Videlov
86fe1e2735
remove target reader / writer 2024-04-19 23:29:13 +02:00
Kiril Videlov
442eb88eaa rm target writer from unrelated tests 2024-04-19 23:13:27 +02:00
Kiril Videlov
01100a5407
rm gb_repository from commit 2024-04-19 22:52:17 +02:00
Kiril Videlov
f1cee4bf11
rm gb_repository from merge_virtual_branch_upstream 2024-04-19 22:49:53 +02:00
Kiril Videlov
eb1c0ca721
rm gb_repository from list_virtual_branches 2024-04-19 22:48:43 +02:00
Kiril Videlov
1240177dcf
rm gb_repository from unapply_branch 2024-04-19 22:47:13 +02:00
Kiril Videlov
749cde0112
rm gb_repository from unapply_ownership 2024-04-19 22:45:33 +02:00
Kiril Videlov
45c1342a53
rm gb_repository from apply_branch 2024-04-19 22:44:42 +02:00
Kiril Videlov
676fb0e8fa
rm gb_repository from update_gitbutler_integration 2024-04-19 22:39:46 +02:00
Kiril Videlov
b77818c31e
rm gb_repository from update_branch 2024-04-19 22:23:24 +02:00
Kiril Videlov
b1c6af328e
rm gb_repository from get_status_by_branch 2024-04-19 22:18:35 +02:00
Kiril Videlov
6dc51f4d12
rm gb_repository from is_remote_branch_mergeable 2024-04-19 22:12:37 +02:00
Kiril Videlov
2e1c46c0a6
rm gb_repository from is_virtual_branch_mergeable 2024-04-19 22:11:30 +02:00
Kiril Videlov
67a8d03254
rm gb_repository from verify branch 2024-04-19 22:09:28 +02:00