Commit Graph

8843 Commits

Author SHA1 Message Date
ndom91
de310a203d fix: isDeleting branch behaviour in BranchPreviewHeader 2024-09-01 14:18:04 +03:00
ndom91
5e5c8cb289 fix: rename loadingDelete => isDeleting 2024-09-01 14:18:04 +03:00
ndom91
fc31c5e262 fix: set branch delete modal action btn to loading=true when appropriate 2024-09-01 14:18:04 +03:00
Kiril Videlov
7a3b694da8
Merge pull request #4806 from Byron/show-git
Trace the `git` binary path (#3601)
2024-08-30 22:11:46 +02:00
Nico Domino
e62acb1192
fix: revert modal transition back to animation (#4805) 2024-08-30 15:53:40 +02:00
Sebastian Thiel
fe970e1fcd
Trace the git binary path (#3601)
This should help in cases the binary can't be found nonetheless,
for yet to be clarified reason.
2024-08-30 15:29:49 +02:00
Nico Domino
c2a662edf3
fix: extract Board empty state into own component (#4796) 2024-08-30 11:48:55 +00:00
Nico Domino
ac6bc0bb13
chore: bump turborepo to 2.1.0 (#4801) 2024-08-30 11:48:33 +00:00
Pavel Laptev
fe3c73ccfd
FileListItem fix (#4799)
* show lock icons and lock tooltip

* replace state with derived

* allow to drag files
2024-08-30 13:11:23 +02:00
Kiril Videlov
2c7773a6cd
Merge pull request #4793 from Byron/git2-to-gix
performance improvements and bug fixes
2024-08-30 12:53:26 +02:00
Kiril Videlov
717078dc44
Merge pull request #4800 from gitbutlerapp/update-change-reference-for-branch
add api for updating change references
2024-08-30 12:49:53 +02:00
Kiril Videlov
af6fdc36a4
add api for updating change references 2024-08-30 12:38:50 +02:00
Caleb Owens
c8caabb46c
Merge pull request #4797 from gitbutlerapp/Resolve-tree-in-less-stupid-manner
Resolve merge in less stupid manner
2024-08-30 12:09:27 +02:00
Pavel Laptev
425136da20
Edit mode updates (#4792)
* Add `Scrollbar` and `ScrollableContainer` to the UI lib

* event fixes

* replace app components with UI

* Move `ContentWrapper` to the UI side

* update file status badge colors

* move scrollbar components back to to app

because of the user settings

* dummy commit card added to the edit mode

* add the commit line

* edit modal UI tweaks

* remove unused code

* lint fixes

* lint fixes
2024-08-30 11:21:11 +02:00
Caleb Owens
0802d1c477
Resolve merge in less stupid manner 2024-08-30 11:05:20 +02:00
Sebastian Thiel
4d495cb3bc
Adjust integration check to also recognize by matching tree.
This is relevant when all commits are equal by tree, but seem changed
due to the added GitButler headers.

For added safety, we also compare by commit message, date and authors,
basically everything that isn't the headers.
2024-08-30 07:15:47 +02:00
Sebastian Thiel
4cafc909b0
Improve the clarity of performance logs 2024-08-30 07:15:47 +02:00
Sebastian Thiel
4ae354392b
Improve performance of list-local using git2. 2024-08-30 07:15:47 +02:00
Sebastian Thiel
36f23d529f
CLI with branch list-remotes to list remote branches 2024-08-30 07:15:46 +02:00
Sebastian Thiel
6a4849d090
refactor: avoid borrowed git2::Oid as it's a copy type.
Usually this makes the affected code simpler.
2024-08-30 07:15:46 +02:00
Sebastian Thiel
c81b140790
Assure the most-recent workspace head is used when emitting changed files.
The reason for this is that now the outcome of this can be re-used in `list_virtual_branches`,
which is sensitive to seeing the latest vbranch state which is not a given.

Calculating it makes sure there is no mismatch, and probably "can't be wrong".

Also note that `head_commit()` is still kept around as it's the idea to eventually
use it more.
2024-08-30 07:15:40 +02:00
Filipe Louro
92349391f3 Refactor RepoInfo type to use domain instead of source and resource 2024-08-29 18:24:45 +03:00
Filipe Louro
90bf797ad0 Add resource to tests to make checks happy 2024-08-29 18:24:45 +03:00
Filipe Louro
43264e28f2 Run prettier 2024-08-29 18:24:45 +03:00
Filipe Louro
bec6ddcefa Make if statement more strict 2024-08-29 18:24:45 +03:00
Filipe Louro
3cc2edda7a Set gitHostFactory for gitlab self hosted instances 2024-08-29 18:24:45 +03:00
Nico Domino
0f48b53108
feat: add <form /> to Modal implementation (#4780) 2024-08-29 11:34:47 +02:00
Sebastian Thiel
b03ba56288
Merge pull request #4784 from Byron/fix-features
Remove unnecessary `gix` features from `watcher` and add them to `tauri`
2024-08-29 09:50:53 +02:00
Sebastian Thiel
47b6d41a26
Merge pull request #4771 from Byron/git2-to-gix
list virtual branches performance
2024-08-29 09:50:35 +02:00
Sebastian Thiel
a7b01bd641
Keep using get_workspace_head() when no cached result is used.
That way, the application will not run into unexpected cases.
2024-08-29 09:34:54 +02:00
Sebastian Thiel
79798c7407
Exclude big files when performing a worktree diff.
This was lost previously when switching it over to a read-only
implementation.
Implementing it with an ignore list will take time, 400ms in the GitLab
repository, but it's not slower than it was before and it is always
preferred to not dump objects into the ODB unnecessarily.
2024-08-29 09:31:59 +02:00
Sebastian Thiel
8c7159d906
Remove unnecessary gix features from watcher and add them to tauri 2024-08-29 07:26:29 +02:00
Sebastian Thiel
a0e236110a
refactor
- move `gix` repository extension to where it belongs more naturally.
- make sure that `get_wd_tree()` is named more closely to what it really
  does, and use it in more places.
2024-08-28 22:05:25 +02:00
Sebastian Thiel
751e091f6f
Reuse the worktree-diff during 'recalulate-everything'
It's used for emission of changed files, but also for listing
branch information.

Make sure we only run the worktree-status once to save time.

This also unifies the acquisition of the `HEAD^{commit}`,
which one day will be a natural feature once `gix::Repository`
is used.
2024-08-28 21:42:29 +02:00
Sebastian Thiel
13deabdebd
find large files more quickly thanks to gix based dirwalk
Also make sure that important `gix` crates are always compiled
with optimization for proper performance.

This is particularly useful when optimizing performance as not
everything has to be done in release mode.

However, it also causes CI to be slower as it compiles some
dependencies longer.

The problem realy is that `tauri dev` doesn't support custom profiles,
so there is only `dev` and `release`.
2024-08-28 21:19:47 +02:00
Sebastian Thiel
7ce143954f
Do not dynamically calculate the head commit when listing virtual branches.
That way, the head is static which allows to re-use the worktree status across
multiple related calls.

Also, add a way to quickly get the `head_commit()` from a `git2::Repository`.

Note that this may cause breakage in the app, as now it will see the actual
head, not a computed one, but that should also help us to find places that
didn't properly update their state.
2024-08-28 21:16:43 +02:00
Kiril Videlov
b2cdc37d41
Merge pull request #4779 from Byron/fix-clone
Assure HTTPS support is compiled into `gix` using `curl`.
2024-08-28 13:24:18 +02:00
Sebastian Thiel
41c053474a
Assure HTTPS support is compiled into gix using curl. 2024-08-28 12:55:44 +02:00
Sebastian Thiel
fc63929da3
Add a flag to allow performance logging: GITBUTLER_PERFORMANCE_LOG
````
GITBUTLER_PERFORMANCE_LOG=1 LOG_LEVEL=debug pnpm tauri dev
````

Additionally, some noise was removed by turning a warning into
a trace.
2024-08-28 11:41:29 +02:00
Pavel Laptev
95d11a2965
Fix files selection (#4764)
* allow select multiple if the lane is applied

* missing commit Id added

* fix selection with `shift`

* disable draggable icon for unapplied commits

* replace `isPreview` with existing `isUnapplied`

* do not allow mutliple selection for remote commits

* refactor(utils): small update

* revert previous commit

* review changes
2024-08-28 11:27:48 +02:00
Sebastian Thiel
7e0878a14f
Use read-only worktree diff
The worktree diff is essentially a 'git status' with a given tree,
and that can be expressed with a diff of the workdir, the index and a tree.

This comes at the expense of not being able to control which file sizes are diffed.
2024-08-28 11:10:04 +02:00
Sebastian Thiel
bd2c19db0b
Allow the bench profile to compile faster
There we don't necessarily need every last bit of optimization like
one would want in release profiles, but build performance is of the essence
for developer productivity.
2024-08-28 11:10:04 +02:00
Sebastian Thiel
30cc6a4838
Add branch status to CLI
It calls `list_virtual_branches()` which kind of has the effect of a status call.
2024-08-28 11:10:02 +02:00
Sebastian Thiel
dd724f310d
Also debug-trace information on list_virtual_branches calls.
This can be useful for those who seek extra information, and while it's
dominating refresh times.
2024-08-28 11:09:33 +02:00
Caleb Owens
5a69cd8412
Merge pull request #4776 from gitbutlerapp/have-sidebar-in-edit-mode
Have sidebar in edit mode
2024-08-28 10:52:08 +02:00
Caleb Owens
47358dd7a8
Have sidebar in edit mode 2024-08-28 10:41:47 +02:00
Caleb Owens
25409fd6f9
Merge pull request #4777 from gitbutlerapp/UI-updates-Edit-mode
UI updates: Edit mode
2024-08-28 10:19:40 +02:00
Kiril Videlov
b6c57eedf9
Merge pull request #4745 from Comnir/4472-fix-conflicting-branches-list-message
Fix conflicting-branches list message
2024-08-28 10:09:55 +02:00
Pavel Laptev
cb52363774 Sokitview updates 2024-08-27 23:37:05 +02:00
Kiril Videlov
12d48df0f7
Merge pull request #4774 from gitbutlerapp/remove-unused-feature-flag
remove unused feature flag
2024-08-27 20:57:26 +02:00