pub-dev icon indicating copy to clipboard operation
pub-dev copied to clipboard

Document negation: https://pub.dev/help/search#query-expressions

Open jonasfj opened this issue 1 year ago • 5 comments

We support negation in the UI, by displaying [-] checkboxes. We have no way to set negation other than typing -is:plugin or something like that. But we haven't documented negation in the documentation.

jonasfj avatar Jul 22 '24 14:07 jonasfj

Which search terms can be negated? @isoos do you know?

sigurdm avatar Aug 01 '24 09:08 sigurdm

I think only tags (in the form of prefix:identifier) can be negated. I've just checked that text phrases cannot be negated (which would be a useful feature too).

isoos avatar Aug 01 '24 17:08 isoos

Can the updated:<duration> tags be negated?

sigurdm avatar Aug 02 '24 07:08 sigurdm

Can the updated: tags be negated?

Hm, while these are tag-shaped, they are not really the same internally (similar to package:<name> prefixes). I guess we really need to implement https://github.com/dart-lang/pub-dev/issues/1752 (maybe using package:query or a subset of it).

isoos avatar Aug 02 '24 09:08 isoos

Not saying they have to be negatable, just that we need to know the current workings in order to document them.

sigurdm avatar Aug 02 '24 09:08 sigurdm