Commit Graph

229 Commits

Author SHA1 Message Date
Caleb Owens
da335846a0 Use DateTime over duration 2024-05-23 22:35:35 +02:00
Sebastian Thiel
05118086dd
Use gitoxide in file-watcher
This allows for faster opening times, and more more efficient
exclude checks.
2024-05-23 11:13:56 +02:00
Sebastian Thiel
7536431da9
upgrade gix to v0.63
It comes with various bugfixes and security improvements.
Admittedly, none of these are currently relevant for GitButler.

It's still a good idea to upgrade as `cargo deny` would have problems
with older versions due to the security advisories that were published
yesterday.
2024-05-23 09:40:05 +02:00
Ani Betts
b4b0de6a3c
Merge remote-tracking branch 'upstream/master' into flushable-debounce
* upstream/master: (85 commits)
  History and minor UI fixes (#3797)
  History fixes (#3796)
  make GitGuardian happy
  bump playwright version
  add vitest exclude for node_modules
  Remove unused exports from ipc
  Update auth.ts to use absolute import
  Use correct invoke function
  setup for async tasks on oplog update
  formatting
  save and restore the gitbutler/integration branch
  remove unneccessary CSPs
  Fix ollama request security
  fix: forgot the port
  feat: Set default snapshot lines threshold to 20 when undefined
  fix: Updated connect-src to allow local connections for ollama
  Minor tweaks to CSS and use real branch name
  Unmount history component when hidden
  Fix bug leaving PR button visible
  Small refactor of history component
  ...
2024-05-21 10:29:42 +02:00
Ani Betts
fe35b1f65f
Import notify_debounce_full
We need to make some changes to notify_debounce_full and it seems like
the project is unmaintained, let's copy-paste some code
2024-05-15 20:27:25 +02:00
Ani Betts
1695ad5c53
Add dirs crate 2024-05-15 17:39:00 +02:00
Kiril Videlov
3e0914444f
remove unused crates in tauri 2024-05-12 04:19:19 +02:00
Kiril Videlov
0a12b3eac5
remove unused crates in core 2024-05-12 04:12:56 +02:00
Josh Junon
c564ccc7f7
add gitbutler_git::sign_commit() 2024-05-07 16:26:38 +02:00
Josh Junon
6afd680781
remove old changeset code 2024-05-07 07:03:34 +02:00
Pavel Laptev
043917ad45
Help window menu added 2024-05-05 21:40:06 +02:00
Kiril Videlov
9aee55c869
tiny cli for snapshots
this is a cli convinience tool for listing and restoring gitbutler snapshots even if the app can't start or if it's hung. of course this can be done with plain git, but this is more convinient

In the future we could add more functionality to it
2024-05-04 11:29:14 +02:00
Kiril Videlov
6c0f4c0946
Merge pull request #3652 from gitbutlerapp/dependabot/cargo/tauri-plugin-log-5e3900e
Bump tauri-plugin-log from `773b498` to `5e3900e`
2024-05-01 10:50:58 -07:00
dependabot[bot]
3733772b60
Bump tauri-plugin-log from 773b498 to 5e3900e
Bumps [tauri-plugin-log](https://github.com/tauri-apps/plugins-workspace) from `773b498` to `5e3900e`.
- [Release notes](https://github.com/tauri-apps/plugins-workspace/releases)
- [Commits](773b498392...5e3900e682)

---
updated-dependencies:
- dependency-name: tauri-plugin-log
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-05-01 15:12:27 +00:00
dependabot[bot]
a1a3abc868
Bump the rust-updates group with 10 updates
Bumps the rust-updates group with 10 updates:

| Package | From | To |
| --- | --- | --- |
| [serde](https://github.com/serde-rs/serde) | `1.0.197` | `1.0.199` |
| [thiserror](https://github.com/dtolnay/thiserror) | `1.0.58` | `1.0.59` |
| [anyhow](https://github.com/dtolnay/anyhow) | `1.0.81` | `1.0.82` |
| [async-trait](https://github.com/dtolnay/async-trait) | `0.1.79` | `0.1.80` |
| [chrono](https://github.com/chronotope/chrono) | `0.4.37` | `0.4.38` |
| [reqwest](https://github.com/seanmonstar/reqwest) | `0.12.2` | `0.12.4` |
| [serde_json](https://github.com/serde-rs/json) | `1.0.115` | `1.0.116` |
| [ssh-key](https://github.com/RustCrypto/SSH) | `0.6.5` | `0.6.6` |
| [tauri](https://github.com/tauri-apps/tauri) | `1.6.1` | `1.6.2` |
| [sysinfo](https://github.com/GuillaumeGomez/sysinfo) | `0.30.8` | `0.30.11` |


Updates `serde` from 1.0.197 to 1.0.199
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.197...v1.0.199)

Updates `thiserror` from 1.0.58 to 1.0.59
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](https://github.com/dtolnay/thiserror/compare/1.0.58...1.0.59)

Updates `anyhow` from 1.0.81 to 1.0.82
- [Release notes](https://github.com/dtolnay/anyhow/releases)
- [Commits](https://github.com/dtolnay/anyhow/compare/1.0.81...1.0.82)

Updates `async-trait` from 0.1.79 to 0.1.80
- [Release notes](https://github.com/dtolnay/async-trait/releases)
- [Commits](https://github.com/dtolnay/async-trait/compare/0.1.79...0.1.80)

Updates `chrono` from 0.4.37 to 0.4.38
- [Release notes](https://github.com/chronotope/chrono/releases)
- [Changelog](https://github.com/chronotope/chrono/blob/main/CHANGELOG.md)
- [Commits](https://github.com/chronotope/chrono/compare/v0.4.37...v0.4.38)

Updates `reqwest` from 0.12.2 to 0.12.4
- [Release notes](https://github.com/seanmonstar/reqwest/releases)
- [Changelog](https://github.com/seanmonstar/reqwest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/seanmonstar/reqwest/compare/v0.12.2...v0.12.4)

Updates `serde_json` from 1.0.115 to 1.0.116
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.115...v1.0.116)

Updates `ssh-key` from 0.6.5 to 0.6.6
- [Commits](https://github.com/RustCrypto/SSH/compare/ssh-key/v0.6.5...ssh-key/v0.6.6)

Updates `tauri` from 1.6.1 to 1.6.2
- [Release notes](https://github.com/tauri-apps/tauri/releases)
- [Commits](https://github.com/tauri-apps/tauri/compare/tauri-v1.6.1...tauri-v1.6.2)

Updates `sysinfo` from 0.30.8 to 0.30.11
- [Changelog](https://github.com/GuillaumeGomez/sysinfo/blob/master/CHANGELOG.md)
- [Commits](https://github.com/GuillaumeGomez/sysinfo/compare/v0.30.8...v0.30.11)

---
updated-dependencies:
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: anyhow
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: async-trait
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: chrono
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: reqwest
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: ssh-key
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: tauri
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: sysinfo
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-05-01 15:11:55 +00:00
Kiril Videlov
00706b402b
remove posthog from the rust code
similar to https://github.com/gitbutlerapp/gitbutler/pull/3628
2024-04-29 16:12:14 +02:00
Kiril Videlov
6439f3333a
remove sentry rust dependencies 2024-04-29 15:54:13 +02:00
Kiril Videlov
ae7bb0d2ee
feat: Enhance OperationType handling in SnapshotDetails 2024-04-29 12:08:56 +02:00
Sebastian Thiel
a46de60d10 make tests work
This is accomplished by settig the test-feature when running `core` tests.
There is also a safeguard to help assuring this doesn't land in production.
2024-04-24 16:13:05 +02:00
Kiril Videlov
7f4aec50cf make git system executable the default auth flow 2024-04-24 16:13:05 +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
Sebastian Thiel
cf81401b5a
add a function for worktree file listings specifically
This introduces `gix` to the codebase and uses it selectively
to traverse a worktree while respecting git excludes.
2024-04-20 09:07:17 +02:00
Sebastian Thiel
adfbc7c5cc
Remove now unused dependencies from tauri.
These have moved to `watcher` and `analytics` respectively.
2024-04-18 09:25:33 +02:00
Sebastian Thiel
5785085a77
reintegrate watcher crate into tauri crate 2024-04-17 22:20:32 +02:00
Sebastian Thiel
81dd1fc13e
The watcher-crate compiles and tests run 2024-04-17 21:46:06 +02:00
Sebastian Thiel
143fc05547
add analytics crate based on tauri/analytics 2024-04-17 20:56:04 +02:00
Sebastian Thiel
5223c197d2
add watcher crate with code copied from gitbutler-tauri/src/watcher.
It's not functional yet, but exactly at the spot where it needs fixing
across the boundary that is:

- a stand-in for application events
- analytics
2024-04-17 19:15:17 +02:00
Sebastian Thiel
c173d8074d
parallelize the delta computation 2024-04-15 07:11:16 +02:00
Sebastian Thiel
906bfa3cf4
use the new testsupport crate 2024-04-09 20:45:17 +02:00
Sebastian Thiel
3a148a556f
Add a new testsupport crate that contains core/tests/shared.
It's code shared by multiple crates, and should be reusable
by means of a crate.
2024-04-09 20:45:16 +02:00
Josh Junon
59af2953cd
update config to refer to new crate structure 2024-04-04 12:09:12 +02:00
Kiril Videlov
0948891339
Merge pull request #3398 from gitbutlerapp/dependabot/cargo/tauri-plugin-store-066058f
build(deps): bump tauri-plugin-store from `c6a5b7a` to `066058f`
2024-04-01 18:16:19 +02:00
dependabot[bot]
9ce4103462
build(deps): bump tauri-plugin-store from c6a5b7a to 066058f
Bumps [tauri-plugin-store](https://github.com/tauri-apps/plugins-workspace) from `c6a5b7a` to `066058f`.
- [Release notes](https://github.com/tauri-apps/plugins-workspace/releases)
- [Commits](c6a5b7ae47...066058f631)

---
updated-dependencies:
- dependency-name: tauri-plugin-store
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-04-01 15:45:32 +00:00
dependabot[bot]
69ae2d33b9
build(deps): bump the rust-updates group with 3 updates
Bumps the rust-updates group with 3 updates: [tokio](https://github.com/tokio-rs/tokio), [refinery](https://github.com/rust-db/refinery) and [similar](https://github.com/mitsuhiko/similar).


Updates `tokio` from 1.36.0 to 1.37.0
- [Release notes](https://github.com/tokio-rs/tokio/releases)
- [Commits](https://github.com/tokio-rs/tokio/compare/tokio-1.36.0...tokio-1.37.0)

Updates `refinery` from 0.8.12 to 0.8.13
- [Release notes](https://github.com/rust-db/refinery/releases)
- [Changelog](https://github.com/rust-db/refinery/blob/main/CHANGELOG.md)
- [Commits](https://github.com/rust-db/refinery/compare/0.8.12...0.8.13)

Updates `similar` from 2.4.0 to 2.5.0
- [Changelog](https://github.com/mitsuhiko/similar/blob/main/CHANGELOG.md)
- [Commits](https://github.com/mitsuhiko/similar/compare/2.4.0...2.5.0)

---
updated-dependencies:
- dependency-name: tokio
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: rust-updates
- dependency-name: refinery
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: similar
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: rust-updates
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-04-01 15:43:50 +00:00
Sebastian Thiel
26c39f2a3f
chore: move library from top-level to gitbutler-core
This better expresses what it does, and leaves the `gitbutler-app`
in the top-level where it can serve as visible entrypoint.
2024-03-30 22:39:21 +01:00
Sebastian Thiel
8e9133092f
minimize app-crate dependencies
After the library was removed, it needs less as well.
2024-03-30 15:16:12 +01:00
Sebastian Thiel
2dbdc6ea99
integrate library into app
Note that small `commands` modules are now inlined for ease of use.
2024-03-30 15:16:11 +01:00
Sebastian Thiel
3b89ed50f9
minimize library dependencies 2024-03-30 15:16:11 +01:00
Sebastian Thiel
bc2fff968c
chore(app): move library-portion to top-level src/ folder.
This allows the tauri-specific parts to remain in the `app` crate,
which will help to eventually release a `cli` crate as well.
2024-03-30 15:16:06 +01:00
dependabot[bot]
c6a7b940b1 build(deps): bump tauri-plugin-store from ed682dd to c6a5b7a
Bumps [tauri-plugin-store](https://github.com/tauri-apps/plugins-workspace) from `ed682dd` to `c6a5b7a`.
- [Release notes](https://github.com/tauri-apps/plugins-workspace/releases)
- [Commits](ed682dd96e...c6a5b7ae47)

---
updated-dependencies:
- dependency-name: tauri-plugin-store
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-27 23:25:15 +01:00
dependabot[bot]
4697f2eb50 build(deps): bump tauri-plugin-context-menu from 0845b15 to d8dcbcb
Bumps [tauri-plugin-context-menu](https://github.com/c2r0b/tauri-plugin-context-menu) from `0845b15` to `d8dcbcb`.
- [Commits](0845b15648...d8dcbcb944)

---
updated-dependencies:
- dependency-name: tauri-plugin-context-menu
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-27 23:24:50 +01:00
dependabot[bot]
be9d32d0e7 build(deps): bump the rust-updates group with 14 updates
Bumps the rust-updates group with 14 updates:

| Package | From | To |
| --- | --- | --- |
| [git2](https://github.com/rust-lang/git2-rs) | `0.18.2` | `0.18.3` |
| [uuid](https://github.com/uuid-rs/uuid) | `1.7.0` | `1.8.0` |
| [thiserror](https://github.com/dtolnay/thiserror) | `1.0.57` | `1.0.58` |
| [toml](https://github.com/toml-rs/toml) | `0.8.11` | `0.8.12` |
| [anyhow](https://github.com/dtolnay/anyhow) | `1.0.80` | `1.0.81` |
| [async-trait](https://github.com/dtolnay/async-trait) | `0.1.77` | `0.1.79` |
| [backtrace](https://github.com/rust-lang/backtrace-rs) | `0.3.69` | `0.3.71` |
| [chrono](https://github.com/chronotope/chrono) | `0.4.34` | `0.4.37` |
| [regex](https://github.com/rust-lang/regex) | `1.10.3` | `1.10.4` |
| [serde_json](https://github.com/serde-rs/json) | `1.0.112` | `1.0.115` |
| [ssh-key](https://github.com/RustCrypto/SSH) | `0.6.4` | `0.6.5` |
| [tauri](https://github.com/tauri-apps/tauri) | `1.6.0` | `1.6.1` |
| [walkdir](https://github.com/BurntSushi/walkdir) | `2.4.0` | `2.5.0` |
| [nix](https://github.com/nix-rust/nix) | `0.27.1` | `0.28.0` |


Updates `git2` from 0.18.2 to 0.18.3
- [Changelog](https://github.com/rust-lang/git2-rs/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/git2-rs/compare/git2-0.18.2...git2-0.18.3)

Updates `uuid` from 1.7.0 to 1.8.0
- [Release notes](https://github.com/uuid-rs/uuid/releases)
- [Commits](https://github.com/uuid-rs/uuid/compare/1.7.0...1.8.0)

Updates `thiserror` from 1.0.57 to 1.0.58
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](https://github.com/dtolnay/thiserror/compare/1.0.57...1.0.58)

Updates `toml` from 0.8.11 to 0.8.12
- [Commits](https://github.com/toml-rs/toml/compare/toml-v0.8.11...toml-v0.8.12)

Updates `anyhow` from 1.0.80 to 1.0.81
- [Release notes](https://github.com/dtolnay/anyhow/releases)
- [Commits](https://github.com/dtolnay/anyhow/compare/1.0.80...1.0.81)

Updates `async-trait` from 0.1.77 to 0.1.79
- [Release notes](https://github.com/dtolnay/async-trait/releases)
- [Commits](https://github.com/dtolnay/async-trait/compare/0.1.77...0.1.79)

Updates `backtrace` from 0.3.69 to 0.3.71
- [Release notes](https://github.com/rust-lang/backtrace-rs/releases)
- [Commits](https://github.com/rust-lang/backtrace-rs/compare/0.3.69...0.3.71)

Updates `chrono` from 0.4.34 to 0.4.37
- [Release notes](https://github.com/chronotope/chrono/releases)
- [Changelog](https://github.com/chronotope/chrono/blob/main/CHANGELOG.md)
- [Commits](https://github.com/chronotope/chrono/compare/v0.4.34...v0.4.37)

Updates `regex` from 1.10.3 to 1.10.4
- [Release notes](https://github.com/rust-lang/regex/releases)
- [Changelog](https://github.com/rust-lang/regex/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/regex/compare/1.10.3...1.10.4)

Updates `serde_json` from 1.0.112 to 1.0.115
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.112...v1.0.115)

Updates `ssh-key` from 0.6.4 to 0.6.5
- [Commits](https://github.com/RustCrypto/SSH/compare/ssh-key/v0.6.4...ssh-key/v0.6.5)

Updates `tauri` from 1.6.0 to 1.6.1
- [Release notes](https://github.com/tauri-apps/tauri/releases)
- [Commits](https://github.com/tauri-apps/tauri/compare/tauri-v1.6.0...tauri-v1.6.1)

Updates `walkdir` from 2.4.0 to 2.5.0
- [Commits](https://github.com/BurntSushi/walkdir/compare/2.4.0...2.5.0)

Updates `nix` from 0.27.1 to 0.28.0
- [Changelog](https://github.com/nix-rust/nix/blob/master/CHANGELOG.md)
- [Commits](https://github.com/nix-rust/nix/compare/v0.27.1...v0.28.0)

---
updated-dependencies:
- dependency-name: git2
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: uuid
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: rust-updates
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: toml
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: anyhow
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: async-trait
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: backtrace
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: chrono
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: regex
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: ssh-key
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: tauri
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: rust-updates
- dependency-name: walkdir
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: rust-updates
- dependency-name: nix
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: rust-updates
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-27 23:24:29 +01:00
Kiril Videlov
d629020953
feat: Update dependencies to the latest versions 2024-03-27 19:28:53 +01:00
Josh Junon
9803a7d0c8
remove linefile 2024-03-25 22:42:22 +01:00
Josh Junon
3f481116ba add initial windows askpass implementation 2024-03-21 19:23:04 +01:00
Josh Junon
df2f81340b integrate gitbutler_git::push() into gitbutler-app and wire up askpass mechanisms 2024-03-19 17:56:14 +01:00
Josh Junon
bd288f92ca refactor gitbutler-git to be cli-only and allow prompt handlers 2024-03-19 08:25:57 +01:00
Caleb Owens
a43cdb4060 Set up dependencies for anthropics and open AI in client
I've been able to use the OpenAI library as they support being in the browser if you pass the "dangerouslyAllowBrowser" flag.

Anthropics don't have any interest in supporting browers making API calls and causes sugnificant CORS problems, so I've made use of the Tauri HTTP library, so this commit also sets that up
2024-03-18 19:20:18 +01:00
Josh Junon
52334a2724 remove core crate in favor of more granule crates 2024-03-18 15:06:40 +01:00
Kiril Videlov
d3e3e21a13 refactor: introduces a flat-file state for virtual branches 2024-03-16 21:23:12 +01:00