Closed ilovemaui closed 5 years ago
In the web interface you can hit the "select all" button above the project picker. The selection is stored in a cookie afterwards and then it's selected automatically. It kinda solves the problem in the web interface however there is no special keyword.
So this is asking for something like this:
https://myopengrok/source/search?q=foobar&defs=&refs=&path=&hist=&type=&project=ALL
Related to #1048 in a sense that too many projects make the URL long enough to hit limits.
perhaps something like that.. before, I didn't use projects at all, and we just searched everything anyhow. I am currently hardcoding the list, but this enhancement would make that unnecessary.
@vladak I'd suggest a different parameter than "project" as the project name can be arbitrary. Something like this:
https://myopengrok/source/search?q=foobar&defs=&refs=&path=&hist=&type=&search_all=true
additionally, and i don't know if it related. but when you open a browser for the 1st time, there are no projects selects. While it does remember once you put in the projects you want. is there any way to default to include all projects the first time a browser is open?
No there is not
ok. thanks. I wasn't sure if this could be a useful enhancement
ok. thanks. I wasn't sure if this could be a useful enhancement
By the way this was already suggested a long time ago (#28) and it could be an useful enhancement
This is needed. I have 100's of projects and so when I want to share the link with another developer its prohibitively long.
Also kinda duplicate of #563
I updated the code to include a search all projects button. The question is how do i submit a push?
It's easy on github: https://help.github.com/articles/creating-a-pull-request/
Thanks. I think I did the needful.
From: Vladimir Kotal notifications@github.com Sent: Wednesday, May 31, 2017 6:07 AM To: OpenGrok/OpenGrok Cc: dhireng; Comment Subject: Re: [OpenGrok/OpenGrok] short URL for all projects search wanted (#1357)
It's easy on github: https://help.github.com/articles/creating-a-pull-request/
Creating a pull request - User Documentationhttps://help.github.com/articles/creating-a-pull-request/ help.github.com Create a pull request to propose and collaborate on changes to a repository. These changes are proposed in a branch, which ensures that the master branch only ...
— You are receiving this because you commented. Reply to this email directly, view it on GitHubhttps://github.com/OpenGrok/OpenGrok/issues/1357#issuecomment-305093019, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AP9U0a0-QixRlioWWzSlkHrDJpcnZj7qks5r_QOhgaJpZM4LxuT3.
We run opengrok with ~400 projects and long url is big problem for us too. Now url has about 12kb when I search all projects. This makes links to search results almost unsharable.
However simple solution with one special wildcard for all projects does not seem to be enough. Common use case is to search subset of all projects but still large and we would be back with same issue.
So please take this as another vote and kind request to fix this issue.
My proposal how the long url issue can be fixed:
1 ) Grouping Projects into Groups As Opengrok already allows administrator to define Groups of Projects in configuration file. List of projects in url will be automatically shrinked into predefined Groups, as much as possible.
Example: Projects: A,B,C,D,E Group: G1 contains Projects A,B Group: G2 contains Projects B,C Group: G3 contains Projects D,E Group: G4 contains Groups G2,G3 Shrinking: {A,C,E} -> {A,C,E} {A,B} -> {G1} {A,B,C} -> {G1,C} {B,C,D,E} -> {G4} {A,B,C,D,E} -> {A,G4} or {all}
Basic algorithm idea:
G
all existing Groups
, sorted in descending order by size.selected Projects
contains all Projects from Group G
.G
to set of selected Groups.G
from set of selected Projects
.1a ) Virtual predefined Group for all Improve solution 1) for users not using Groups and for users with large number Groups. Opegrok can define one virtual Group 'all' that will always contain all existing Projects/Groups.
As a result, for users not using Groups, this will work exactly same as one wildcard solution proposed above. And users using Groups will not have to define own 'ALL' groups to enable super short link searching all projects.
2 ) Another small improvement
Switch url from ...?project=A&project=B
to ...?project=A|B
Another advantage I see in Groups usage in search url is that urls to Opengrok will obsolete slower. If projects are added or removed in Group, current search url fails or does not inlude new Projects. Urls with Groups will adapt automagically.
Instead of adding a special case to the project parameter (like ?project=ALL
), maybe OpenGrok could search all projects by default if the project parameter is not supplied.
There was PR #1621 opened for this however not touched in a while however maybe some of the work can be leveraged.
Any update on this? This is a much needed request.
no directly, but now it's supported with groups so the url gets a little bit shorter when using groups
Wish OpenGrok remembered the projects that I have selected to search. When I "select all" and search, I get into a file and click a link (to a function declaration), for example, it seems to default to a more limited set of projects than I selected to search in the first place (in my case, I have 'src' "project" 'include' "project" and so forth), so I'm always having to go back up and click select all again or it will just search the 'include' project, for example. I'd be fine in my case with selecting a default set of projects to search and never having to re-select.
This is different problem than being discussed here - see #1447.
Why is this closed? Using groups is not an option when you have 1200 different repos automatically imported. This is still very much a huge problem...
I don't see this being closed.
I submitted a PR but for one reason or the other it was getting pushed back. I now maintain my own forked repository. Also note that the projects dropdown is gets super slow when you have a couple of 100 projects. It will be best if the right design is agreed - the coding aspect takes no time.
PR #1621 was closed due to lack of response to review comments as far as I know. Also, adding new UI elements is pretty much deal breaker.
Question is if adding a UI-element is as bad as having a broken application for the past 6 months... It's starting to get quite annoying...
The PRs needs to meet some quality threshold, otherwise the project would be hard to maintain. This was not as much about the UI element, rather it was the lack of response. If this is so important, someone else would step up with its own PR I guess.
so i recently enabled projects in my opengrok instance. but do a search, you need to specify all of them (the url). so perhaps we can add an enhancement/keyword that will let you search all projects.. for example.. i have proj1 proj2 proj3 proj4 proj5 so I have to do a search like this: https://myopengrok/source/search?q=foobar&defs=&refs=&path=&hist=&type=&project=proj1&project=proj2&project=proj3 &project=dpkg&project=proj4&project=proj5
if would be nice if we could have a single keyword that would include all of them. thanks. fyi, this should also be added to command line tool.