Commit Graph

35 Commits

Author SHA1 Message Date
Baptiste Roux
fdafa3aa81 chore: Pass regex pattern as slice instead of string 2023-02-01 18:14:56 +01:00
Baptiste Roux
956b172426 chore(repo/find): Exlude paths based on regex 2023-01-14 14:40:11 +01:00
23fc942db7 Warn on empty filters
Closes #29
2022-12-12 15:43:27 +01:00
38bba1472e Improve error messages during sync errors
Closes #46
2022-12-12 15:21:42 +01:00
5880066531 cli: Update code for clap v4 2022-10-06 12:17:26 +02:00
7d8fbb844e Properly handle deletion of nested worktrees 2022-06-29 23:40:23 +02:00
f027191896 Update worktree handling
That's a big one, see the module-level comment for details.
2022-06-23 19:21:05 +02:00
e78dcf471a Print warning when giving --track and --no-track 2022-06-23 19:21:05 +02:00
b77c442f56 Forbid unsafe code 2022-06-17 02:24:15 +02:00
c56765ce26 Match branches with worktrees always, even with slashes 2022-06-17 01:50:01 +02:00
d0cbc2f985 forge: Add option to specify remote name
Close #32
2022-06-15 20:39:54 +02:00
32eb4676ee Restructure into smaller modules 2022-05-27 23:37:54 +02:00
b8c552fb62 Give repos a namespace to allow subdirectories 2022-05-26 18:57:31 +02:00
6ef759a14e Separate config structs from internal structs 2022-05-26 18:57:31 +02:00
1db3eadd4c Fix formatting 2022-05-26 18:57:14 +02:00
127dd0535e Normalize paths when printing configuration 2022-05-26 18:53:12 +02:00
f2f1d5bcaf Fix worktree initialization 2022-05-26 18:53:12 +02:00
38c66cad62 Add git forge integration 2022-05-26 17:55:07 +02:00
584f68ba42 clap: Remove deprecation warning 2022-02-21 20:28:30 +01:00
9b64de7991 Add YAML as a config format option
@mustafa89 ;)
2022-01-22 11:23:53 +01:00
6e4c388195 Add --stash options to pull and rebase 2022-01-22 11:23:53 +01:00
1ae0ceff60 dependencies: Update clap to 3.0.5 2022-01-08 14:47:29 +01:00
a94bd19362 repos: Set error code correctly when status fails 2022-01-04 11:55:00 +01:00
ef8a57c60e Add rebase option for worktrees 2022-01-04 11:18:48 +01:00
717b0d3a74 Add fetch & pull option to worktrees 2021-12-31 11:20:01 +01:00
3ff7b61518 Refuse to convert to worktree with ignored files 2021-12-23 18:33:14 +01:00
61a8d63374 Allow nested worktree directories 2021-12-23 18:33:14 +01:00
92e4856dd9 Remove branch-namespace option 2021-12-23 18:33:14 +01:00
02e9de0cbd Proper formatting 2021-12-23 18:33:14 +01:00
b183590096 Add default tracking configuration 2021-12-23 18:33:14 +01:00
27586b5ff0 Add functionality for persistent branches 2021-12-23 18:33:14 +01:00
4a9f1bc278 Make new clippy happy 2021-12-21 16:15:12 +01:00
0b181b9b79 Run cargo fmt with new cargo version 2021-12-21 16:15:12 +01:00
a51e5f8918 Fix regression of find with broken repos 2021-12-02 12:43:45 +01:00
f0c8805cf3 Refactor
This refactors a huge chunk of the code base to make it more maintainable.

Main points:

* Proper separation between bin and lib. Bin handles argument parsing &
  validation and (most of) the output. Lib provides interfaces for all
  opreations.

* Before, libgit2 internals were literred throughout the codebase,
  mainly the `Repository` struct and `git2::Error` in Results. They
  library is now properly wrapped in `repo.rs`, which exposes only the
  required functionality. It also standardizes the Error messages
  (they're just Strings for now) and handles stuff like the copious
  usage of Options to wrap maybe-invalid-utf-8 values. The program will
  still panic on non-utf-8 Strings e.g. in git remotes, but I guess this
  is acceptable. If you actually manage to hit this case, I promise I'll
  fix it :D

* Many unwraps() are now gone and properly handled.

* The table printing functionality is now confined to `table.rs`,
  instead of passing tables as parameters through the whole program.
2021-12-01 20:12:24 +01:00