upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/src/bin/ngit/main.rs
diff options
context:
space:
mode:
authorDanConwayDev <DanConwayDev@protonmail.com>2026-03-04 15:37:17 +0000
committerDanConwayDev <DanConwayDev@protonmail.com>2026-03-04 15:37:17 +0000
commit293ef01e141846f7de5af2c8c6be9d6c694083fd (patch)
treed4ee20d9a89fe622fcfa058e600fdd25e56eab91 /src/bin/ngit/main.rs
parentb4c7b5e24d05aef878e155a1bedc22de54609fbb (diff)
standardise on --label; add label filter and display to pr list/view
- rename --hashtag (comma-separated) to --label (repeatable) on issue list, matching the --label flag already used on issue create - add --label filter to pr list with the same OR semantics (matching GitHub) - display labels column in pr list table and Labels: line in pr view - include labels array in all JSON outputs (list and view for both issue and pr) - rename internal 'hashtags' -> 'labels' throughout issue_list.rs and list.rs
Diffstat (limited to 'src/bin/ngit/main.rs')
-rw-r--r--src/bin/ngit/main.rs19
1 files changed, 14 insertions, 5 deletions
diff --git a/src/bin/ngit/main.rs b/src/bin/ngit/main.rs
index 4c1aa75..28bf1da 100644
--- a/src/bin/ngit/main.rs
+++ b/src/bin/ngit/main.rs
@@ -57,12 +57,20 @@ async fn main() {
57 Commands::Pr(args) => match &args.pr_command { 57 Commands::Pr(args) => match &args.pr_command {
58 PrCommands::List { 58 PrCommands::List {
59 status, 59 status,
60 labels,
60 json, 61 json,
61 id, 62 id,
62 offline, 63 offline,
63 } => { 64 } => {
64 sub_commands::list::launch(status.clone(), *json, false, id.clone(), *offline) 65 sub_commands::list::launch(
65 .await 66 status.clone(),
67 labels.clone(),
68 *json,
69 false,
70 id.clone(),
71 *offline,
72 )
73 .await
66 } 74 }
67 PrCommands::View { 75 PrCommands::View {
68 id, 76 id,
@@ -72,6 +80,7 @@ async fn main() {
72 } => { 80 } => {
73 sub_commands::list::launch( 81 sub_commands::list::launch(
74 "open,draft,closed,applied".to_string(), 82 "open,draft,closed,applied".to_string(),
83 vec![],
75 *json, 84 *json,
76 *comments, 85 *comments,
77 Some(id.clone()), 86 Some(id.clone()),
@@ -122,14 +131,14 @@ async fn main() {
122 Commands::Issue(args) => match &args.issue_command { 131 Commands::Issue(args) => match &args.issue_command {
123 IssueCommands::List { 132 IssueCommands::List {
124 status, 133 status,
125 hashtag, 134 labels,
126 json, 135 json,
127 id, 136 id,
128 offline, 137 offline,
129 } => { 138 } => {
130 sub_commands::issue_list::launch( 139 sub_commands::issue_list::launch(
131 status.clone(), 140 status.clone(),
132 hashtag.clone(), 141 labels.clone(),
133 *json, 142 *json,
134 false, 143 false,
135 id.clone(), 144 id.clone(),
@@ -145,7 +154,7 @@ async fn main() {
145 } => { 154 } => {
146 sub_commands::issue_list::launch( 155 sub_commands::issue_list::launch(
147 "open,draft,closed,applied".to_string(), 156 "open,draft,closed,applied".to_string(),
148 None, 157 vec![],
149 *json, 158 *json,
150 *comments, 159 *comments,
151 Some(id.clone()), 160 Some(id.clone()),