Commit Graph

8110 Commits

Author SHA1 Message Date
Sebastian Thiel
4a7b63a56e
various refactors in main functions called during project load
* use `ctx` as name instead of `project_repository` to make lines shorter
  and more readable. This could be done everywhere once the type-name changes
  as well.
* Where possible, avoid using `&self` for `VirtualBranchActions` as there is no state.
  For now I avoided to remove its usage as field in the filesystem monitor.
* Use a more modern way to use state in `tauri` commands.
* Add the `Ext` suffix to what clearly is extension traits.
2024-07-14 21:32:55 +02:00
Sebastian Thiel
f48d0e2746
adapt to changes in gitbutler-branch crate 2024-07-14 21:32:55 +02:00
Sebastian Thiel
85b4e564cd
simplify module paths of gitbutler-branch crate 2024-07-14 21:32:55 +02:00
Sebastian Thiel
4501b5dd51
minimize the public API of the branch crate
Only keep public what needs to be public right now, which always
helps with refactoring later.
2024-07-14 21:32:55 +02:00
Sebastian Thiel
4805f6e7e7
adapt to changes in gitbutler-branch-actions 2024-07-14 21:32:55 +02:00
Sebastian Thiel
5e408f6b2d
Assure a single path to an item (struct, fn)
Also, simplify paths and optimize them (to some extend) to seem
non-redundant when `use`ing them.
2024-07-14 21:32:55 +02:00
Sebastian Thiel
0079f2bcbe
minimize the public API of gitbutler-branch-actions crate.
Also avoid private traits where functions would be easier to use.
2024-07-14 21:32:54 +02:00
Sebastian Thiel
6fb6201ab9
assure docs can be built without warnings by default.
It's a good way to review import paths and the public API.
2024-07-14 21:32:49 +02:00
Mattias Granlund
3ef3dbc24f Drop rxjs from package.json 🎉 2024-07-14 20:20:52 +01:00
Mattias Granlund
cfd1c73fa4 Replace platform() observable with store 2024-07-14 20:20:52 +01:00
Mattias Granlund
9d50f45e8d Replace app updater rxjs with stores 2024-07-14 20:20:52 +01:00
Mattias Granlund
1395113aba Replace UserService rxjs with writable store 2024-07-14 20:20:52 +01:00
Mattias Granlund
9181a62829 Fix missing RemoteBranchService context 2024-07-14 20:20:52 +01:00
Mattias Granlund
2299ff430d Fix base branch reload 2024-07-14 20:20:52 +01:00
Mattias Granlund
5a4220ca73 Remove rxjs from branch services 2024-07-14 20:20:52 +01:00
Mattias Granlund
dfe4f1b8f9 Remove rxjs from RemoteBranchService 2024-07-14 20:20:52 +01:00
Mattias Granlund
d3886747c6 Move base branch stuff into its own directory 2024-07-14 20:20:52 +01:00
Mattias Granlund
30a08556e8 Turn base branch observable into a store 2024-07-14 20:20:52 +01:00
Mattias Granlund
b0ff24cc1a Refactor fetches subscription into FetchesSignal
- removing rxjs
2024-07-14 20:20:52 +01:00
Mattias Granlund
b3065851a3 Refactor head subscription into service
- removing rxjs
2024-07-14 20:20:52 +01:00
Mattias Granlund
b58aa9c8bc Fix bug: missing fetch on subscribe call to github pr store 2024-07-14 18:19:01 +01:00
Mattias Granlund
a8c21c9708 Add basic listing test for github integration
- tests basic listing and project metrics
2024-07-14 14:45:22 +01:00
Mattias Granlund
8c61d841c2 Make project metrics optional for GitHost 2024-07-14 14:45:22 +01:00
Mattias Granlund
5d757ab7fb Misc improvements
- simplify metrics reporter now that github has been refactore
- shorten interface name from GitHostService to GitHost
- shorten various types and function names
2024-07-14 13:43:01 +01:00
Mattias Granlund
f7c684edf9 Fix octokit not available bug 2024-07-14 13:43:01 +01:00
Mattias Granlund
354af30550 Fix bug in error map
- unsafe destructuring is bad..
2024-07-14 13:43:01 +01:00
Mattias Granlund
032ad230ae Keep in progress checks badge as is while reloading
- the flickering back and forth is annoying
2024-07-14 12:59:45 +01:00
Mattias Granlund
f197e8b288 Handle unhandled promise rejections
- users need this feedback in case something goes wrong
2024-07-14 12:55:21 +01:00
Mattias Granlund
1e68325185 Fix merge button by fetching from remotes after merge 2024-07-14 10:30:25 +01:00
Mattias Granlund
7d221519c0 Sleep a bit after merging pr before reloading
- github seems a bit eventually consistent
2024-07-14 10:10:14 +01:00
Mattias Granlund
129c948837 Disable pr button when no commits
- upgrade pr button to svelte5
2024-07-14 09:52:53 +01:00
Mattias Granlund
d834f64f34 Use s-curve backoff when refreshing github checks 2024-07-13 22:25:20 +01:00
Mattias Granlund
f9f79188ed Fix: reload vbranches on sync click
- regressed last release with removal on emit() on fetch
2024-07-13 20:31:17 +01:00
Mattias Granlund
6addc060df Fix pr related problem in branch header
- regressed in github refactor
2024-07-13 19:24:37 +01:00
Mattias Granlund
8d20674602 Move function into only file where it is referenced 2024-07-13 17:40:10 +01:00
Mattias Granlund
81288fa43f Drop unnecssary documenation 2024-07-13 17:40:10 +01:00
Mattias Granlund
4d9cb0837f Rename hostedGit -> gitHost in filenames and code 2024-07-13 17:40:10 +01:00
Mattias Granlund
ef7d27b7fb rename hostedServices -> gitHost 2024-07-13 17:40:10 +01:00
Mattias Granlund
0a681fad9a Add a couple of tests for pr monitoring service
- stop polling when completed
- fetch once if no check runs  or suites
- fix a few problems discovered while creating test
2024-07-13 17:40:10 +01:00
Mattias Granlund
768da9852d Add proof-of-concept integration test for GitHub pr service 2024-07-13 17:40:10 +01:00
Mattias Granlund
d113cfa03f Improve a couple of types 2024-07-13 17:40:10 +01:00
Mattias Granlund
15e4e549bf Retry PR creation unless error handled
- make push rethrow so we don't attempt creating PR if it fails
2024-07-13 17:40:10 +01:00
Mattias Granlund
915bd5bd6b Only create octokit client if access token is defined 2024-07-13 17:40:10 +01:00
Mattias Granlund
9d6bfb14e1 Migrate pull request preview +page.svelte to runes mode 2024-07-13 17:40:10 +01:00
Mattias Granlund
e676718e66 Remove unused getter / setter 2024-07-13 17:40:10 +01:00
Mattias Granlund
2ac54960bf Remove merge method from PrMonitor 2024-07-13 17:40:10 +01:00
Mattias Granlund
374240b196 Move creation of pr monitor into pr service
- pr monitor depends on pr service, easier to construct this way
2024-07-13 17:40:10 +01:00
Mattias Granlund
b1fa672d81 Refactor GitHub integration 2024-07-13 17:40:10 +01:00
Nico Domino
7c2243b2a0
fix: rm workflow_dispatch from docs GHA (#4358) 2024-07-13 13:27:25 +00:00
Nico Domino
d5497592ca
fix: cleanup markdown modification script in release GHA (#4357) 2024-07-13 12:23:00 +00:00