Xfce Forum

Sub domains
 

You are not logged in.

#1 2018-01-06 21:34:19

dcarrco
Member
Registered: 2018-01-06
Posts: 4

Continuing Trouble with Right-Click and also Shred/Srm as a custom act

hey there folks.  i love XFCE and scoff at all the complex shaded and animated desktops.  lean and mean, thats what i like.
Thunar is also a great file manager and i have been enjoying using it for years.  i have tried all the major distros and landed on
Sparky for now (Debian).  Thunar 1.6.11 - Linux 4.9.0-4-amd64 #1 SMP Debian 4.9.65-3+deb9u1 (2017-12-23) x86_64 GNU/Linux

#!/bin/bash
zenity --question --text="Shred Files?" --ok-label="Yes" --cancel-label="No"
if [ $? = 0 ] ; then
   for FILE in "$@" ; do

   srm -fz "$FILE"
   done
   zenity --info --title=”done” --text=”Shredding complete”
fi

Heres the problem, which i have had over several distros but always with XFCE and Thunar.

1.  about half the time if i right click on a file, it will choose the last option on the right-click menu immediately.  i have replaced my mouse several time from wireless to wired and back.  i have tried to expand click-delay in settings.  i have tried building latest version of Thunar.  no luck.  i was accidentally shredding files because that happened to be the last option on my right-click menu.  So now i have written a bash script which leads to the second problem:

2.  i have tried this as a command as listed here https://help.ubuntu.com/community/ThunarCustomActions with the command

zenity --question;if [$? = 0];then shred -fuz %F;fi

but using shred or srm in either one line OR bash script it deletes all the files ok but never returns from the action to the Thunar window.  cursor spins forever.  so i tried breaking it into a bash script and it does the same thing.  it asks "Shred Files?" and then shreds the files and says "Shredding complete" but then never returns.  i have to force the Thunar wondow closed and reopen.  when i reopen, the files are gone so it exited bash script, but hung somewhere else.

Any help?  Its been very frustrating.  It must be working for everyone else because i cant find a solution.  is it because i have an SSD drive?  some cache setting?  permissions on the bash script?  should i use gksudo?  arrghhh

Last edited by dcarrco (2018-01-06 21:51:46)

Offline

#2 2018-01-07 01:52:46

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 4,075

Re: Continuing Trouble with Right-Click and also Shred/Srm as a custom act

Hello and welcome.

As for #2, the command is wrong. It should be:

zenity --question;if [ $? -eq 0 ];then shred -fuz %F;fi

...I'm not sure how the command on that web page is supposed to work.

As to #1, that is really weird. Especially given that it doesn't happen every time. Does the same happen when you use other Xfce programs like righ-clicking on the desktop or mousepad, etc?


How To Ask For Help           Xfce FAQ                            Xfce Release Information
The Xfce Community          Xfce Tips and Tricks

Offline

#3 2018-01-07 15:17:59

dcarrco
Member
Registered: 2018-01-06
Posts: 4

Re: Continuing Trouble with Right-Click and also Shred/Srm as a custom act

thanks ToZ.  i tried that command and it also doesnt return to thunar. 
you know, the choosing last option on right click menu is less of a problem (and no it doesnt do that on any other right click menus) than the fact that the command locks up Thunar.  srm or shred, in a bash script or in the one line above, it deletes the files but never returns to thunar and i have to force close that window.  for example when i shred 2 files, i see the first one disappear in the thunar window, and then it locks up.  once again, the files are gone, but thunar nevers regains control.

any ideas on that?  is there a debug mode or log for thunar that might tell me whats going on?

Offline

#4 2018-01-07 16:32:10

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 4,075

Re: Continuing Trouble with Right-Click and also Shred/Srm as a custom act

Missed the version of thunar you have. That bug was fixed in 1.6.12. See: https://bugzilla.xfce.org/show_bug.cgi?id=13832 & https://bugzilla.xfce.org/show_bug.cgi?id=13481.


How To Ask For Help           Xfce FAQ                            Xfce Release Information
The Xfce Community          Xfce Tips and Tricks

Offline

#5 2018-01-07 16:51:18

dcarrco
Member
Registered: 2018-01-06
Posts: 4

Re: Continuing Trouble with Right-Click and also Shred/Srm as a custom act

ToZ.  great.  thank you for your help.  i downloaded and built 1.6.12 and indeed the problem has been fixed in that version.  im gonna spend all day just shredding everything.

Offline

#6 2018-01-08 18:06:55

dcarrco
Member
Registered: 2018-01-06
Posts: 4

Re: Continuing Trouble with Right-Click and also Shred/Srm as a custom act

hey ToZ.  after building and installing (using make install) the newer Thunar, which fixed the Right-Click Shred Custom action as we have discussed, I now get about 15 "Refusing to add non-unique action'uca_action-145312695903404601' to action group 'ThunarActions'" lines in my log (with varying many digit numbers).  I saw this post https://forum.xfce.org/viewtopic.php?id=7934 and tried that solution but it didnt help.  They are just log entries so no really big deal, but do you have a suggestion?  anyone?

Offline

#7 2018-01-08 22:12:05

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 4,075

Re: Continuing Trouble with Right-Click and also Shred/Srm as a custom act

dcarrco wrote:

hey ToZ.  after building and installing (using make install) the newer Thunar, which fixed the Right-Click Shred Custom action as we have discussed, I now get about 15 "Refusing to add non-unique action'uca_action-145312695903404601' to action group 'ThunarActions'" lines in my log (with varying many digit numbers).  I saw this post https://forum.xfce.org/viewtopic.php?id=7934 and tried that solution but it didnt help.  They are just log entries so no really big deal, but do you have a suggestion?  anyone?

How did you rebuild? Did you uninstall the previous thunar? Did you overwrite it? What ./configure statement did you use?

I believe that debian has a method for creating deb file. A quick search brought up this link.


How To Ask For Help           Xfce FAQ                            Xfce Release Information
The Xfce Community          Xfce Tips and Tricks

Offline

Board footer

Powered by FluxBB