From dff81f7b84c279d7e00fe7a885743605a2ac5b7e Mon Sep 17 00:00:00 2001 From: Teddy Wing Date: Sun, 2 Aug 2020 00:10:19 +0200 Subject: git-sugpatch: Accept multiple suggestion args; Accept suggestion ID args Add the ability to pass multiple suggestions to the binary. The diffs will appear in the output one after another. Also allow suggestions to be specified by their comment ID instead of their full URL. This uses the Git repo's remote to determine the owner-repo pair. When a URL argument is given, the owner-repo pair is extracted from the URL. It's now possible to call the binary like this: $ git-sugpatch 459692838 \ > https://github.com/teddywing/suggestion-test/pull/1#discussion_r459691747 --- src/lib.rs | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/lib.rs') diff --git a/src/lib.rs b/src/lib.rs index 494c389..0a8ab13 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1,5 +1,11 @@ #![warn(rust_2018_idioms)] pub mod config; +pub mod error; pub(crate) mod owner_repo; + +mod arg; + + +pub use arg::is_suggestion_id; -- cgit v1.2.3