yatima1460 / Drill

Search files without indexing, but fast crawling
https://drill.software/
GNU General Public License v2.0
268 stars 21 forks source link

Search within a folder #36

Open rauldipeas opened 5 years ago

rauldipeas commented 5 years ago

In Catfish i can search within a folder and i'm using this to search icons on system folder /usr/share/icons, i can't do this with Drill.

Could this be implemented?

yatima1460 commented 5 years ago

You can't with the AppImage because it's in a frozen state, but you can if you use the portable zip or the .deb!

Just remove /usr from the blocklists! in /opt/drill-search/assets

https://github.com/yatima1460/Drill/blob/e8c5802fb2a668fbdd75c42a26cc4ab48bf13e60/assets/blocklists/linux.txt#L13

yatima1460 commented 5 years ago

But if you want that /usr/share/icons is treated as the root search this still needs to be implemented Or if you want to search a specific path

I want to add a "path:/usr/share/icons iconname" search way probably

yatima1460 commented 5 years ago

The entire Drill needs a token system for searching, like path:, extension:, date: and so on

rauldipeas commented 5 years ago

Maybe, you should include two types of search, one that look into entirely system and another like actualy was.

yatima1460 commented 5 years ago

The more time passes the less blacklists will be needed, SSDs price is crashing and every average user will have a SSD in 5 years max

Anyways I think a "all:" token is a nice addition

yatima1460 commented 5 years ago

Side question: do you have any knowledge about the best idea to parse tokens?

Like what is the best way to parse something like this:

all:path:/usr/share/icons filetype:svg

I NEVER did something like this and I want to ask opinions around

yatima1460 commented 5 years ago

For now I will add low priority because you can """fix""" this by removing /usr from the blocklists and it's not something the average user would use

But this needs to be implemented as a token, and the token system will be a huge update

rauldipeas commented 5 years ago

Side question: do you have any knowledge about the best idea to parse tokens?

Like what is the best way to parse something like this:

all:path:/usr/share/icons filetype:svg

I NEVER did something like this and I want to ask opinions around

Sorry, i don't have this knowlege to help you.

But thank you for the support, your suggestion fixed my problem.

rauldipeas commented 5 years ago

Another thing that you should change:

icon=/usr/share/icons/drill-search/drill.png to icon=drill

This way i can use a icon from theme.

yatima1460 commented 5 years ago

How does icon path resolving work?

If I replace it with just icon=drill and install using the .deb the icon is not showing

yatima1460 commented 5 years ago

sudo update-icon-caches /usr/share/icons/* does not show the icon either

rauldipeas commented 5 years ago

You have to put icon on /usr/share/pixmaps/ or within hicolor folders.

yatima1460 commented 5 years ago

You are right, I can already see other software icons there

yatima1460 commented 5 years ago

icon fixed

yatima1460 commented 5 years ago

now the real question: why do you want to change the icon? you prefer a magnifying glass thingy?

rauldipeas commented 5 years ago

I don't want to change, the icon has to be a part of theme, when change theme, all icons has to be the same look/patern.

yatima1460 commented 5 years ago

Thanks, I want it to follow the standards as much as possible

Do you know any good link to the documentation about the various paths in the Linux distros and what should I put there?

rauldipeas commented 5 years ago

Sorry, i don't know, but if you need any help, just ask me.

yatima1460 commented 5 years ago

What if there are multiple users so every user can have his/her own configuration file?

Where should I put Drill configuration files?

Into ~/.config/drill-search?

rauldipeas commented 5 years ago

Could be.

yatima1460 commented 5 years ago

So do you think path:/usr/share/icons would be a good search string to let Drill only scan that specific path? If you would use something like that I would implement it

but the time it takes to write path:/usr/share/icons is probably longer than waiting for Drill to crawl /usr/share/icons when /usr is removed from the blocklists lol

rauldipeas commented 5 years ago

In fact, what I need is an option to search on a specific path only.

yatima1460 commented 5 years ago

So it's more like removing useless results from the list instead of actually searching on a specific path because of performance reasons?

rauldipeas commented 5 years ago

Something like that...hehe

yatima1460 commented 5 years ago

typing path:/usr/share/icons icon_name will take more time than actually finding what you really need

I believe the best solution for this is that if you start Drill (CLI or GTK) with --root:/usr/share/icons, it will override the mountpoints and start scanning there

and you could create a link to start Drill with that command, is it usable for you in this way?

rauldipeas commented 5 years ago

It should be enough.