You are not logged in.

#26 2010-06-01 04:17:49

venky80
Member
Registered: 2007-05-13
Posts: 1,002

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation


Acer Aspire V5-573P Antergos KDE

Offline

#27 2010-06-01 04:18:38

dmz
Member
From: Sweden
Registered: 2008-08-27
Posts: 881
Website

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

some-guy94 wrote:
dmz wrote:

Anyone that might have a suggestion where to place the rmshit.log?
$HOME/rmshit.log isn't ultimate, considering the purpose of the application. lol

Isn't that what $XDG_DATA_HOME is for?

Thank you.

We're now using either $XDG_DATA_HOME or $HOME/.local/rmshit (and I've removed
  .local/ from the configuration file for obvious reasons smile)

Last edited by dmz (2010-06-01 04:22:40)

Offline

#28 2010-06-01 07:59:33

Ogion
Member
From: Germany
Registered: 2007-12-11
Posts: 367

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

Hm, firefox doesn't create .esd_auth here..But i have nothing regarding esd installed either, maybe that's why?

Ogion


(my-dotfiles)
"People willing to trade their freedom for temporary security deserve neither and will lose both." - Benjamin Franklin
"Enlightenment is man's leaving his self-caused immaturity." - Immanuel Kant

Offline

#29 2010-06-01 09:52:17

dmz
Member
From: Sweden
Registered: 2008-08-27
Posts: 881
Website

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

It's strange...

> pacman -Qo $(which esd)
/usr/bin/esd is owned by esound 0.2.41-1

> pacman -Qi esound|grep Depends
Depends On     : audiofile  tcp_wrappers  alsa-lib>=1.0.18

So, esd was installed because of the options I gave to MPD during compilation.
I have no idea why Firefox "uses" this though...

Last edited by dmz (2010-06-01 11:04:02)

Offline

#30 2010-06-01 10:28:37

rransom
Member
Registered: 2010-04-26
Posts: 92

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

Dieter@be wrote:

Now that i think about it, I think a generic "inotify to userscripts" wrapper already exists

fsniper, for one (in AUR).

Offline

#31 2010-06-01 10:47:50

Dieter@be
Forum Fellow
From: Belgium
Registered: 2006-11-05
Posts: 2,001
Website

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

good thing you accept .local now, I was about to bring the wonderful xdg basedir spec to your attention.

I think deleting files on rmshit startup is OK.
after all, it's the users responsability to configure rmshit correctly

rransom wrote:
Dieter@be wrote:

Now that i think about it, I think a generic "inotify to userscripts" wrapper already exists

fsniper, for one (in AUR).

yep, that was the one. thanks

Last edited by Dieter@be (2010-06-01 10:48:41)


< Daenyth> and he works prolifically
4 8 15 16 23 42

Offline

#32 2010-06-02 06:06:42

dmz
Member
From: Sweden
Registered: 2008-08-27
Posts: 881
Website

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

I went with a hash of arrays for the configuration instead.
This way we can specify multiple watchdirs, all with different files to be killed.

our %shittyfiles = (
  "$ENV{HOME}"      => ['.adobe',              # Flash crap
                        '.esd_auth',           # ESD, Firefox creates this
                        '.macromedia',         # Flash crap
                        '.recently-used.xbel', # GTK Save Dialog, probably
                        '.Xauthority',         # X remote login auth stuff
                        'Desktop',             # Firefox creates this
                        ],
# Authors choice
#  "$ENV{HOME}"      => ['.adobe',
#                        '.esd_auth',
#                        '.macromedia',
#                        '.dbus',
#                        '.gconf',
#                        '.gconfd',
#                        '.links',
#                        '.lynx',
#                        '.lyrics',
#                        '.gem',
#                        '.cpan',
#                        '.xsel.log',
#                        '.dmenu_cache',
#                        '.fmenu_cache',
#                        '.Xauthority',
#                        '.fontconfig',
#                        'Desktop',
#                        '.local/share/gegl-0.1',
#                        ],

   # Example.
#   "/var/log"       => ['mail.log.1',
#                        'syslog.log.1',
#                        'uucp.log.1',
#                        'kernel.log.1',
#                        ],
                      );

Offline

#33 2010-06-02 06:23:52

rransom
Member
Registered: 2010-04-26
Posts: 92

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

Perhaps trying to delete unwanted files after the fact is the wrong approach:

Martin Kopta ([url wrote:

http://lists.suckless.org/dev/1006/4482.html[/url])]Few months ago I set my $HOME as read only and removed dotfiles and dotdirs what I didn't create myself or explicitly want. Many apps showed their true nature.

Offline

#34 2010-06-02 11:03:29

Dieter@be
Forum Fellow
From: Belgium
Registered: 2006-11-05
Posts: 2,001
Website

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

rransom wrote:

Perhaps trying to delete unwanted files after the fact is the wrong approach:

Martin Kopta ([url wrote:

http://lists.suckless.org/dev/1006/4482.html[/url])]Few months ago I set my $HOME as read only and removed dotfiles and dotdirs what I didn't create myself or explicitly want. Many apps showed their true nature.

interesting, I wonder how a readonly scheme can be made compatible with apps that need to write changes legitimately (or where the user wants to update things)
i guess you could make your ~ readonly, but not ~/.cache and such. ~/.config should be readonly except when you want to tweak things in there yourself..


< Daenyth> and he works prolifically
4 8 15 16 23 42

Offline

#35 2010-07-06 01:27:18

tlvince
Member
Registered: 2010-07-06
Posts: 68
Website

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

I tried to do something similar using inotifywait: prowler

Offline

#36 2010-07-19 05:29:15

dmz
Member
From: Sweden
Registered: 2008-08-27
Posts: 881
Website

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

Dieter@be wrote:

I think deleting files on rmshit startup is OK.
after all, it's the users responsability to configure rmshit correctly

Finally I got around to fix this, also implemented a -clean option in case one
only wants to remove the crap and not having $DIR monitored.

Also wrote documentation. sad

Offline

#37 2010-07-21 07:27:23

dmz
Member
From: Sweden
Registered: 2008-08-27
Posts: 881
Website

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

... and finally got around to write a PKGBUILD, thanks to S1G1   http://aur.archlinux.org/packages.php?ID=39056.

I hope it works like it should.

Last edited by dmz (2010-07-21 07:28:30)

Offline

#38 2010-09-06 08:33:06

gtklocker
Member
Registered: 2009-09-01
Posts: 462

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

How can I execute rmshit?

Offline

#39 2010-09-06 08:39:11

dmz
Member
From: Sweden
Registered: 2008-08-27
Posts: 881
Website

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

Edit the configuration file and...

rmshit

and...

tailf $XDG_CONFIG_HOME/rmshit/rmshit.log

and

man rmshit

Offline

#40 2010-09-08 05:46:44

Inxsible
Forum Fellow
From: Chicago
Registered: 2008-06-09
Posts: 9,183

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

I installed rmshit-git from AUR, and it installed correctly, but I cannot invoke it.

╔═[01:44]═[inxs @ wolfdale]
╚═══===═══[~]>> rmshit
bash: rmshit: command not found

╔═[01:44]═[inxs @ wolfdale]
╚═══===═══[~]>> rmshit -c
bash: rmshit: command not found

╔═[01:44]═[inxs @ wolfdale]
╚═══===═══[~]>> pacloc rmshit-git
Name           : rmshit-git
Version        : 20100908-1
URL            : http://github.com/trapd00r/rmshit
Licenses       : GPLv3
Groups         : None
Provides       : None
Depends On     : perl  perl-linux-inotify2
Optional Deps  : None
Required By    : None
Conflicts With : None
Replaces       : None
Installed Size :  72.00 K
Packager       : Unknown Packager
Architecture   : any
Build Date     : Wed 08 Sep 2010 01:41:32 AM EDT
Install Date   : Wed 08 Sep 2010 01:41:32 AM EDT
Install Reason : Explicitly installed
Install Script : No
Description    : Keep your home directory (or other dir) clean from unwanted mess

man rmshit works, but none of the rmshit commands work


Forum Rules

There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !

Offline

#41 2010-09-08 06:00:26

Inxsible
Forum Fellow
From: Chicago
Registered: 2008-06-09
Posts: 9,183

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

Update to earlier post :

Did a find on rmshit in my system and found this

╔═[01:48]═[inxs @ wolfdale]
╚═══===═══[~]>> sudo find / -name rmshit >> shit
Password: 
/tmp/clyde-inxs/rmshit-git/rmshit-git/src/rmshit-build/blib/arch/auto/rmshit
/tmp/clyde-inxs/rmshit-git/rmshit-git/src/rmshit-build/blib/script/rmshit
/tmp/clyde-inxs/rmshit-git/rmshit-git/src/rmshit-build/blib/lib/auto/rmshit
/tmp/clyde-inxs/rmshit-git/rmshit-git/src/rmshit-build/rmshit
/tmp/clyde-inxs/rmshit-git/rmshit-git/src/rmshit
/tmp/clyde-inxs/rmshit-git/rmshit-git/src/rmshit/rmshit
/tmp/clyde-inxs/rmshit-git/rmshit-git/pkg/usr/lib/perl5/vendor_perl/bin/rmshit
/tmp/clyde-inxs/rmshit-git/rmshit-git/pkg/usr/lib/perl5/vendor_perl/auto/rmshit
/home/inxs/.config/rmshit
/usr/lib/perl5/vendor_perl/bin/rmshit
/usr/lib/perl5/vendor_perl/auto/rmshit

So I ran /usr/lib/perl5/vendor_perl/bin/rmshit and it worked !!

I would suggest that you add another source file (rmshit.sh) to your AUR package like this one

#!/bin/bash
/usr/lib/perl5/vendor_perl/auto/rmshit

and install that file as /usr/bin/rmshit.

so basically add this line in your build function in your PKGBUILD

install -Dm755 $srcdir/rmshit.sh $pkgdir/usr/bin/rmshit

Forum Rules

There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !

Offline

#42 2010-09-08 07:29:24

dmz
Member
From: Sweden
Registered: 2008-08-27
Posts: 881
Website

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

But... that's actually not my fault. I agree that this 'bin' directory placement is stupid and I have asked *why* on earth someone decided it was a good idea, but I got no good answers.
Also... according to /etc/profile.d/perlbin.sh the $PATH *SHOULD* be updated, but it wasnt for me, not for you and not for a lot of other people.

I'm not very tempted to 'fix' this issue since something else, out of my control, appearantly is very wrong.
Thanks for the suggestion though.

Offline

#43 2010-09-08 07:36:43

Inxsible
Forum Fellow
From: Chicago
Registered: 2008-06-09
Posts: 9,183

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

No worries. I edited your PKGBUILD and installed it the way I wanted it anyway. I just find it annoying to have to remember /usr/lib/perl5/vendor_perl/bin/rmshit, just to invoke a program.

I simply created the sh file under /usr/bin and use that to invoke the program.


Forum Rules

There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !

Offline

#44 2010-09-10 07:03:57

xelados
Member
Registered: 2007-06-02
Posts: 314
Website

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

This sounds like a great script. I'll check it out over the weekend!

Offline

#45 2010-09-15 02:16:55

Inxsible
Forum Fellow
From: Chicago
Registered: 2008-06-09
Posts: 9,183

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

if i make a change to the rmshit.conf file and rerun the command

rmshit -c

it does not delete the new file that i just added to the shittyfiles array.

it just keeps saying

rmshit is running

but i can't find the pidof rmshit either nor can see it under htop. Am i understanding the workings correctly? when you start it once, does it always keep running?


Forum Rules

There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !

Offline

#46 2010-09-15 02:34:58

dmz
Member
From: Sweden
Registered: 2008-08-27
Posts: 881
Website

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

It will keep running until you or something else kills it. I assume rmshit -k didn't do you any good. Have you issued 'killall rmshit' or similar? That will not shut it down properly. Remove /tmp/rmshit.pid and try again.

Offline

#47 2010-09-15 03:15:44

Inxsible
Forum Fellow
From: Chicago
Registered: 2008-06-09
Posts: 9,183

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

yes killall rmshit doesn't do anything (I believe) and rmshit -k again simply says

rmshit is running

in fact any flags I use with rmshit gives me that message


Forum Rules

There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !

Offline

#48 2010-09-15 14:49:43

dmz
Member
From: Sweden
Registered: 2008-08-27
Posts: 881
Website

Re: rmshit Deletes annoying files(Desktop/, .gconf*) from ~/ upon creation

Again - you should not kill rmshit without using the -k switch since it will not shut down properly - that's why I asked you to remove /tmp/rmshit.pid and try again - or are there still this errors?

Offline

Board footer

Powered by FluxBB