Commit graph

18 commits

Author SHA1 Message Date
Kynan Ware
72859237e2 Move --type into the search Qualifiers
The --type filter was concatenated into ImmutableKeywords in
SearchQueryBuild, which bypassed search.Query's quoting and let values
that contained quotes (or extra qualifiers) corrupt the final query.
Per babakks's suggestion in the review thread, model it as a regular
qualifier instead.

Add an IssueType field to Qualifiers tagged `qualifier:"type"` so it
shares a key with the existing Type field, and rework Qualifiers.Map
to honour the tag and concatenate values when multiple fields share
the same key. SearchQueryBuild now drops its bespoke type:X
formatting and just sets Qualifiers.IssueType, leaving the
keyword/qualifier escaping to pkg/search.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-05-12 20:40:02 -06:00
Babak K. Shandiz
56cdc36013
refactor(pkg/search): rename KeywordsVerbatim to ImmutableKeywords
Signed-off-by: Babak K. Shandiz <babakks@github.com>
2025-11-20 16:53:16 +00:00
Babak K. Shandiz
76b2de8a18
test(pkg/search): assert verbatim keywords are respected
Signed-off-by: Babak K. Shandiz <babakks@github.com>
2025-11-20 13:08:27 +00:00
Babak K. Shandiz
ef69901f05
refactor(search): rename Query.String to StandardSearchString
Signed-off-by: Babak K. Shandiz <babakks@github.com>
2025-09-08 16:04:47 +01:00
Babak K. Shandiz
efddea720f
test(search): improve test cases
Signed-off-by: Babak K. Shandiz <babakks@github.com>
2025-09-08 15:45:20 +01:00
Babak K. Shandiz
f0a130dd4e
refactor(search): improve special qualifier grouping
Signed-off-by: Babak K. Shandiz <babakks@github.com>
2025-08-31 15:19:42 +01:00
Babak K. Shandiz
cb249e6cbb
test(search): explain why is: and in: qualifiers used in test case
Signed-off-by: Babak K. Shandiz <babakks@github.com>
2025-08-31 02:02:25 +01:00
Babak K. Shandiz
bf242ae2f4
fix(search): sort qualifiers in advacned issue search syntax
Signed-off-by: Babak K. Shandiz <babakks@github.com>
2025-08-31 02:00:27 +01:00
Babak K. Shandiz
392c286db3
test(search): add tests for AdvancedIssueSearchString method
Signed-off-by: Babak K. Shandiz <babakks@github.com>
2025-08-31 01:49:00 +01:00
Josh Kraft
b8f86f54ad Merge branch 'trunk' into gh-search-code 2023-04-26 18:48:24 -06:00
Josh Kraft
65720e498e implement code search
updates
2023-04-26 18:38:35 -06:00
Kousik Mitra
7ee35e43cc
Enable owner flag to take multiple values for searching 2023-04-12 10:37:09 +05:30
Sam Coe
7bd7153285
Fix multiword keyword quoting for search commands (#7170) 2023-03-16 09:19:26 +11:00
Kevin Lee
9a1056fc87
Add search commits command (#6817) 2023-01-17 19:35:09 +00:00
Sam Coe
e7102f9d84
Migrate to go-gh text package (#6236) 2022-09-14 09:23:55 +04:00
Sam Coe
ebbf2ac096
Fix owner qualifier for search queries (#5693) 2022-05-23 13:00:32 +00:00
Sam Coe
ee6fc0f9b7
Add search issues and search pull requests commands (#5334) 2022-03-27 19:53:03 +00:00
Sam Coe
e0045f26b9
Add top level search command and search repos sub command (#5172) 2022-03-09 12:24:27 +00:00