Xfce Forum

Sub domains
 

You are not logged in.

#1 2016-12-18 16:24:12

jack_the_pirate
Member
Registered: 2016-09-10
Posts: 59

Thunar + Catfish: can't search inside current directory recursively

I've followed instructions in the manual here:
http://docs.xfce.org/xfce/thunar/custom … th_catfish

"Finding files in the current folder with catfish
    Name: Search files…
    Command: catfish --path=%f
    File pattern: *
    Appears if selection contains: Directories

Note: For this action, you'll need to have catfish installed, which is part of the catfish package.
Finding files inside the selected folder with catfish
    Name: Search files inside…
    Command: catfish --path=%f%d
    File pattern: *
    Appears if selection contains: Directories"

And the problem is that the search finds files everywhere, not only recursively, i.e., in the current directory and folders inside it.

What am I doing wrong?


Queen - Megadeth - Metallica - 80's

Offline

#2 2016-12-18 18:37:49

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 10,948

Re: Thunar + Catfish: can't search inside current directory recursively

What version of catfish are you using? I remember things changing a while back with that application.

Anyways, those entries in the wiki don't work properly with my version of catfish (1.4.2). The reason is related to what the variables return. As a test to see what the variables return, use this command in your custom action (requires zenity):

zenity --info --text="f=%f\nF=%F\nd=%d\nD=%D\nn=%n\nN=%N"

... and you will see what the variables return. On my system:

f='/home/toz/Documents'
F='/home/toz/Documents'
d='/home/toz'
D='/home/toz'
n='Documents'
N='Documents'

...when clicking on the Documents folder in my home directory.

To that end, if you want to search for something in the current folder use %d. If you want to search for something in the clicked-on folder, use %f. Using both %d and %f will search both folders (recursively).


Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki  |  Community | Contribute ---

Offline

#3 2016-12-18 23:40:09

jack_the_pirate
Member
Registered: 2016-09-10
Posts: 59

Re: Thunar + Catfish: can't search inside current directory recursively

Ok in my system I get this:
f='/home/user1'
F='/home/user1'
d='/home'
D='/home'
n='user1'
N='user1'

But, the problem remains, ie, catfish continues to search everywhere and finds files in folders in other disks I have mounted in /mnt when I try to find stuff in my home folder


Queen - Megadeth - Metallica - 80's

Offline

#4 2016-12-18 23:44:33

jack_the_pirate
Member
Registered: 2016-09-10
Posts: 59

Re: Thunar + Catfish: can't search inside current directory recursively

Oh I forgot, I'm using Catfish 1.2.2-1.
I'm using Debian Jessie, and as you know, Debian uses not so updated packages; that's why your version is older than mine

Last edited by jack_the_pirate (2016-12-18 23:46:27)


Queen - Megadeth - Metallica - 80's

Offline

#5 2016-12-19 02:50:35

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 10,948

Re: Thunar + Catfish: can't search inside current directory recursively

If you want to only search in the current folder that is displayed in thunar, use %d.
If you want to search within the folder that you are right-clicking on, use %f.
Don't use both as %f%d as shown in the wiki, it won't work correctly.


Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki  |  Community | Contribute ---

Offline

#6 2016-12-19 11:47:56

jack_the_pirate
Member
Registered: 2016-09-10
Posts: 59

Re: Thunar + Catfish: can't search inside current directory recursively

ToZ wrote:

If you want to only search in the current folder that is displayed in thunar, use %d.
If you want to search within the folder that you are right-clicking on, use %f.
Don't use both as %f%d as shown in the wiki, it won't work correctly.

Yes, they both work like you said:
catfish --path=%d
catfish --path=%f


But here's my findings:

if I have 2 files with the same name inside 2 folders also with the same name but on 2 separate locations (e.g.: /home/user/music/guitar_solo.mp3 and /mnt/bk_disk/music/guitar_solo.mp3), and I make search selecting or inside /home/user for guitar_solo.mp3, the search gives me this 2 results:

- "/home/user/music/guitar_solo.mp3"

- "/mnt/bk-disk/music/guitar_solo.mp3"


However, I think it should only return "/home/user/music/guitar_solo.mp3" as the result sad


Queen - Megadeth - Metallica - 80's

Offline

#7 2016-12-19 14:12:16

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 10,948

Re: Thunar + Catfish: can't search inside current directory recursively

Just tested this and I can't replicate this issue on my Jessie install.

Is "/mnt/bk-disk" somehow linked to from within your home directory? 
How do you mount bk-disk?


Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki  |  Community | Contribute ---

Offline

#8 2016-12-20 15:27:54

jack_the_pirate
Member
Registered: 2016-09-10
Posts: 59

Re: Thunar + Catfish: can't search inside current directory recursively

Well, actually it is not mounted like I said but like this line in fstab:
/dev/mapper/DISCO_BKS_crypt    /bbk/diario    ext4    noatime,errors=remount-ro    0    1

and every night I have a cron job running a script to backup several folders:
- /home/user
- /etc
- /data

And I've searched my home folder and didn't find any symlink at all.

But, I remember playing around with hard links some months ago, and maybe that's the origin of this situation.

Last edited by jack_the_pirate (2016-12-20 15:28:34)


Queen - Megadeth - Metallica - 80's

Offline

Board footer

Powered by FluxBB