Skip to content
This repository has been archived by the owner on Nov 18, 2021. It is now read-only.

Search by label using logical OR #660

Closed
superkhau opened this issue Apr 28, 2016 · 89 comments
Closed

Search by label using logical OR #660

superkhau opened this issue Apr 28, 2016 · 89 comments
Labels
enhancement implemented parity Features that GitHub is missing, but competitors implement; also, see [Migration] search

Comments

@superkhau
Copy link

I want to filter labels using a query like label:bug OR label:feature. Is there a way to do this? Seems to only support AND ATM.

@TPS
Copy link
Collaborator

TPS commented May 2, 2016

Should probably be implemented along with #65. 👍

@davidschreiber

This comment has been minimized.

@OliverJAsh
Copy link

This has been changed in the current GitHub version: By default labels now use OR

I'm not seeing this. If I filter by two labels, the search performs an AND

@bltierney
Copy link

seems to be an 'AND' for both labels in a single issue. What I want is an OR across all issues.

@rue-dluria
Copy link

rue-dluria commented May 8, 2017

Having an option between OR and AND would be fantastic - a use case at my org is that many of our PRs have a help wanted or ready for review label, both of which mean that the PR needs attention, and there's no way to have a single filter that captures both.

@avalan4e57
Copy link

That would be quite helpful! It was a surprise for me when I've found out that there could be no optional logical operators for search.

@jkassisbw

This comment has been minimized.

@anatoliyarkhipov
Copy link

Also it would be nice to have OR for search by authors

@tseabra
Copy link

tseabra commented Oct 26, 2017

For me its review :)
Suggestions:

  • review:none,changes_requested
  • review:none|changes_requested
  • review:none or review:changes_requested

@alexfornuto

This comment has been minimized.

@OBreidenbach
Copy link

+1
An 'or' would be great. ;-)

@malyuk

This comment has been minimized.

@malyuk
Copy link

malyuk commented Dec 5, 2017

@jotaen - I am sorry about this. I was just over excited about possibility to use logical OR in issues filtering and wanted to upvote :) 3 different teams are using shared repo for issue tracking on our end which creates a need for labeling that looks like this:
image

Once I want to see all issues that are in QA, I have to go over each label and look at them individually. Ideally, I would like to sum them up.

@jtakalai
Copy link

jtakalai commented Feb 1, 2018

Gitlab already does this (they seem to be using ElasticSearch). What gives? https://docs.gitlab.com/ee/user/search/advanced_search_syntax.html#using-the-advanced-syntax-search

@chris-heathwood-mood
Copy link

+1
Really slowing me down I have 4 filters I check on a regular basis which could be one if an 'or' existed.

@alexfornuto
Copy link

So I wonder how many others in this thread (myself included) didn't notice that this is not an official GitHub repo, only used for public tracking of issues otherwise sent privately.

That means for this feature request to get any love from GitHub, each of us should email support@github.com to voice our support for this idea.

See https://github.com/isaacs/github/blob/master/README.md for more details.

@pensiero

This comment has been minimized.

1 similar comment
@artie-shevchenko

This comment has been minimized.

@teknoraver
Copy link

If I try to find my commits on repo with more than 10 stars, I get a lot of results from repos with 0 star:

https://github.com/search?q=author:teknoraver+-user:teknoraver+stars:>10&type=Commits

what I'm doing wrong?

@TPS
Copy link
Collaborator

TPS commented Oct 21, 2018

@teknoraver My guess? A typo & an unsafe encode.… Try:
https://github.com/search?q=author:teknoraver+-user:teknoraver+stars:%3E10+type=Commits

@teknoraver
Copy link

@teknoraver My guess? A typo & an unsafe encode.… Try:
https://github.com/search?q=author:teknoraver+-user:teknoraver+stars:%3E10+type=Commits

Hi. the &type=Commits is added automatically when switch from "repositories" and "commits" by clicking on the left menu

@CelerityAbbottPC

This comment has been minimized.

@sypets
Copy link
Contributor

sypets commented Jan 19, 2019

There is also a StackOverflow question about this: Can I search github labels with logical operator OR?

@TPS TPS added the parity Features that GitHub is missing, but competitors implement; also, see [Migration] label Feb 26, 2019
@oprogramador
Copy link

message from developer@githubsupport.com :

Hi Piotr,

Thanks for your feedback! We're always working to improve GitHub and we consider every suggestion we receive. I don't show that we are planning to offer logical OR in our searches this year, but I have added it to our internal Feature Request List.

We can't say if/when we may add a feature, however your feedback has definitely been recorded.

Cheers, 
GitHub Support

@alexfornuto
Copy link

heh, 3 years to get put on the list to maybe be looked at sometime after the next year.

@dpaks
Copy link

dpaks commented Mar 22, 2021

Any update on this? 5th anniversary is just about a month away!

@Rand-Random
Copy link

Happy 5th birthday!

fasterit pushed a commit to htop-dev/htop that referenced this issue May 14, 2021
… for multiple labels ORed ... yet.

Has been only five years ... isaacs/github#660
@ahsf
Copy link

ahsf commented May 20, 2021

still open? come on ...
this makes me want to switch back to CVS

@Rocking80
Copy link

My God, 5 years passed and this issue is still OPEN!
What are those product owners of github?

@ElectricRCAircraftGuy
Copy link

ElectricRCAircraftGuy commented Jun 1, 2021

FYI all: here's my answer, to provide insight meanwhile, on Can I search github labels with logical operator OR?

And for anyone using GitHub for no cost, remember what you paid for it.

And for anyone complaining here (which does less good) but NOT also contacting GitHub via their support page (which does more good), please go do that now: https://support.github.com/contact/feedback.

This Issue is a 3rd-party issue tracker on a 3rd-party repo which is NOT officially sponsored by, nor used by, nor monitored by the github development team. So, if you expect them to follow this issue here but you aren't providing them feedback above and linking your feedback to them back to here (ie: giving them this link in your feedback to them), your expectations are in vain.

cc: @Rocking80, @ahsf, @mjonchhe, @Rand-Random, @dpaks, @delfu, @nestor-custodio, @a-elhag, @anyayunli, etc.

@Levi-Lesches
Copy link
Contributor

And for anyone using GitHub for FREE, remember what you paid for it.

Honestly, this is a real head-scratcher in most support forums. I'd also love this feature, but for those of you losing your cool (not many), c'mon. It's a free service, and while new features and improvements are always nice, it's also free! Being appreciative of free software is one of the pinnacles of open-source.

@TPS
Copy link
Collaborator

TPS commented Jun 2, 2021

@Levi-Lesches To be fair, if GitHub was open-source, this would likely have been kludged in w/in a week of request, & then (probably) properly added some point since then.

@oprogramador
Copy link

@superkhau

Are you going to clone this proposal to https://github.com/github/feedback/discussions ?

@superkhau
Copy link
Author

Wow, I can't believe this is still here! Let's hope this gets solved before the next half decade. 🍻

@oprogramador Unfortunately, I don't have admin rights and cannot convert this issue to a discussion.

@oprogramador
Copy link

@superkhau

It seems that everybody can create a discussion there https://github.com/github/feedback/discussions/new but maybe you have to do that manually.

@superkhau
Copy link
Author

@oprogramador Done! Please show your support at community/community#4507. 🚀

@Rand-Random
Copy link

@superkhau
Forgot to close this? Or why keep both open?

@superkhau
Copy link
Author

@Rand-Random I'm not sure if closing this will have any major ramifications -- what does everyone here think?

Thumbs up this comment if you think this should be closed in favour of the linked discussion.

@0xdevalias
Copy link

The official GitHub team and other maintainers are discussing the best way to handle migrations on another issue on this repo. I’d suggest not closing anything and letting them handle it all appropriately

@Levi-Lesches
Copy link
Contributor

To be fair, closing an issue does nothing in terms of moving content. A bot can still read and move the comments and even a clossed issue can still be converted to a discussion (just tested to make sure). I think the issues here should be closed to indicate that future discussion should be done on the official forums and that this is here just for archival purposes.

What's likely to happen in terms of migration is that issues will be transferred to github/feedback and then converted to discussions there. Again, no impact if the issue is closed.

@0xdevalias
Copy link

There may be no ‘technical limitation’, but by closing the issue it will likely fade into the noise of irrelevant/already fixed/duplicate/etc issues. It’s still an issue, thus it should stay open. At least until any official advice otherwise.

@michellemerrill
Copy link
Collaborator

👋🏼 hi everyone, closing this issue in favor of community/community#4507 - be sure to watch this space for updates on this enhancement soon!

Repository owner locked as resolved and limited conversation to collaborators Jul 21, 2021
@TPS
Copy link
Collaborator

TPS commented Jul 21, 2021

@michellemerrill Locked resolved doesn't seem quite right yet… or does your update have that quick an ETA? 🤔

@TPS TPS added the WIP label Jul 21, 2021
@michellemerrill
Copy link
Collaborator

@TPS I agree -- I was locking it temporarily as we received some spam on it (which now looks to be deleted) -- unlocking, but keeping closed as we will comment on updates in the discussions thread. Stay tuned... soon!!!

Repository owner unlocked this conversation Jul 21, 2021
@RanganaFernando
Copy link

If Google owns Github, they will definitely give this feature.
but you know Microsoft, they don't care

@emmaviolet
Copy link

@TPS it was a fairly quick ETA! https://github.blog/changelog/2021-08-02-search-issues-by-label-using-logical-or/

Do head to the feedback issue with any comments community/community#4507

@TPS TPS added implemented and removed WIP labels Aug 2, 2021
@TPS
Copy link
Collaborator

TPS commented Aug 2, 2021

@emmaviolet Just to find out, is that comma syntax usable w/ any other filters, e.g., user:, org:, &c?

@emmaviolet
Copy link

Just to find out, is that comma syntax usable w/ any other filters, e.g., user:, org:, &c?

@TPS sorry, I missed this! Currently this only works with issue labels. We could look into the others though :-)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement implemented parity Features that GitHub is missing, but competitors implement; also, see [Migration] search
Projects
None yet
Development

No branches or pull requests