Package Details: bleachbit-cli 1.10-2

Git Clone URL: https://aur.archlinux.org/bleachbit-cli.git (read-only)
Package Base: bleachbit-cli
Description: Deletes unneeded files to free disk space and maintain privacy. CLI version/no GUI.
Upstream URL: http://bleachbit.sourceforge.net/
Licenses: GPL3
Conflicts: bleachbit
Provides: bleachbit=1.10
Submitter: graysky
Maintainer: graysky
Last Packager: graysky
Votes: 15
Popularity: 0.068517
First Submitted: 2011-11-18 19:35
Last Updated: 2016-02-11 20:53

Latest Comments

ansatz commented on 2016-02-11 09:00

==> ERROR: conflicts should be an array

==> ERROR: the build failed
-> Status failed (1): bleachbit-cli

fix:
-conflicts='bleachbit'
+conflicts=('bleachbit')

graysky commented on 2015-12-25 15:52

Try building in a clean chroot. You can use clean-chroot-manager if you don't wanna mess with the Arch scripts.

cli-cker commented on 2015-12-25 15:02

Does anyone know why this error occurs where it fails to build? I've tried building on both "linux" and "linux-grsec" kernel with the same issue each time: https://bpaste.net/raw/825e82fa7096

graysky commented on 2015-12-03 19:56

@JBecker - Actually 1.92 is beta...

graysky commented on 2015-02-01 12:03

Thanks for the detailed explanation. Timely discussion as the dev for another package I maintain, backintime, is doing the same to remove gksu from his code as well... although his .policy file looks a little different that your version[1]. I found your bug report against bleachbit[2], pity they haven't assigned it in over a year. In any case, I don't want deviate from upstream when packaging this since calling via sudo does actually work (but as you pointed out uses /root as the config dir) and since the PKGBUILD itself does not require gksu. I'd say let's wait and see but after a year of inactivity...

1. http://bazaar.launchpad.net/~bit-team/backintime/trunk/view/head:/qt4/net.launchpad.backintime.policy
2. https://bugs.launchpad.net/bleachbit/+bug/1111061

msx commented on 2015-02-01 00:07

Interesting discussion about the differences between pkexec and sudo: https://www.mail-archive.com/kde-frameworks-devel@kde.org/msg20449.html

msx commented on 2015-02-01 00:05

Oh great, I see a couple of typos (on my recent comment), sorry about that, I wish I could just edit the post.

msx commented on 2015-02-01 00:03

Hello and thanks for bringing this up, TBH I needed to do a little research as I was unsure too... Well, in fact I was as puzzled as you; thankfully I started to remember:

a) There are a handful of issues that may arise when running X applications with sudo, namely:
. Depending on how sudo is configured the invoked application may write configuration files into the $USER directories but with root ownership;
. The application can simply default to /root directory and write its configuration files there when invoked with sudo;
- Sudo does not provide a graphical frontend (i.e. for the cases when you want to create launcher, gksudo/kdesudo does that);
- Sudo does not handle the X11 cookie file correctly (gksudo/kdesudo does);
- Anything else?
b) On the other hand about PolicyKit/pkexec:
. I remember I started to learn PolicyKit at that time so it was a nice exercise to just start using it :)
. PolicyKit does handle X applications in a proper way and it seems to be may be not that much but still a bit more flexible than gksudo/kdesudo;
. From what I understand PolicyKit is a cleaner way to escalate privileges than to use sudo - albeit a complicated one;
. The problem I describe above about root owning $USER files when the X application is launched via sudo does not apply to pkexec;
. While both sudo and pkexec have a timeout feature they work slightly different: with sudo the timeout counter is reset every time you invoke it within the window of the timeout, in pkexec the timeout only works on the invoked application; no matter you quit the app within the timeout window if you launch another application pkexec will ask again for the password.

Both sudo/gksu/kdesu and pkexec aim to address the same target so they share a lot of functionality but at the time they are slightly different; IMHO pkexec is a nicer way to escalate some X app privileges and should be preferred over sudo/gksudo, problem is that the PolicyKit rules that enable pkexec to do its magic should be provided by developers or packagers while with a moderately well configured sudo/gksudo you are on your feet w/o since minute zero.

Finally: take this note with a grain of salt. I encourage anybody who reads this and isn't bored to death to do his/her own research and don't take my word as a final one, also if anybody sees anything wrong please be kind to enlighten us!

Cheers.

graysky commented on 2015-01-31 19:31

Forgive my ignorance, but what is the difference between `sudo bleachbit --switch1 --switch2` and pkexec bleachbit --switch1 --switch2`?

msx commented on 2013-01-31 03:54

Hi,
I just stumbled across an issue trying to run Bleachbit with pkexec since the upstream doesn't provide the needed .policy file.
Until they finally add it -they proven to be very diligent on fixing bugs and accepting patches- may be it could be a good idea to add it to it's PKGBUILD.

If you choose to add it, maybe you would like to name it something like 'org.archlinux.pkexec.bleachbit.policy' (I chosen to follow the naming scheme other AUR packagers used).

The file must be installed in /usr/share/polkit-1/actions and it will enable pkexec to launch Bleachbit effectively rendering sudo/gksu/kdesu obsolete.

Grab it here: http://pastebin.com/Nj36aWDw

graysky commented on 2012-09-13 19:35

@koz -

1) Should be but I have not tested.
2a) That problem is on your end. I had no problems myself.

$ sha256sum bleachbit-0.9.3.tar.bz2
76bb62166d05ebf209dff4811342ba5a7acafc534597709152b314aa06936c47 bleachbit-0.9.3.tar.bz2

2b) Try building with makepkg... I never liked AUR helpers due to quirks with certain PKGBUILDs.

kozaki commented on 2012-09-13 10:17

Thanks to graysky for maintaining this other usefull cli-tool.

1) is latjay's bleachbit-bonus compatible with this one?

2) Got an error today - installing bleachbit-cli:

a - validating bealchbit source file fails (three time). sha256sum gives me different values each time !? eg:
413ada88f2110b1bcc32c29bba33c72a93d87f6f3dc56df0dc1bc456302659ad bleachbit-0.9.3.tar.bz2
f7a636ef8fde927fb4889ec6d276d3b77e77b06cce42a2f47203734f23fdff24 bleachbit-0.9.3.tar.bz2

b - probably linked to (a) if i edit the PKGBUILD the build fails as the tarball is not uncompressed:
/tmp/yaourt-tmp-archie/aur-bleachbit-cli/./PKGBUILD: ligne 24 : cd: /tmp/yaourt-tmp-archie/aur-bleachbit-cli/src/bleachbit-0.9.3: Aucun fichier ou dossier de ce type
[me@pc aur-bleachbit-cli]$ ls src/
bleachbit-0.9.3.tar.bz2

graysky commented on 2012-09-02 15:24

Fek... I stand corrected as does the PKGBUILD. Thank you for your persistence :)

luolimao commented on 2012-09-02 14:08

In fact, latjay maintains bleachbit-bonus (which is probably why they posted the recommendation in the first place).

luolimao commented on 2012-09-02 14:06

Actually, bleachbit-bonus [1] requires bleachbit.

[1] https://aur.archlinux.org/packages.php?ID=61195

graysky commented on 2012-09-02 14:03

@luoimao - Right you are. The more I think about it, the provides array is pretty useless as no other packages require bleachbit... at least now.

luolimao commented on 2012-09-02 05:31

the provides array should be (as latjay noted)
provides=("bleachbit=${pkgver}")
not
provides=("bleachbit-${pkgver}")

graysky commented on 2012-08-22 20:33

Bump to 0.9.3-2

Changelog: Added provides array per user suggestion.
Commit:

lukpod commented on 2012-08-22 16:01

Adding provides array with "bleachbit=${pkgver}" would be a good idea.

lukpod commented on 2012-08-22 15:53

@graysky
Could you make this package provide bleachbit?

graysky commented on 2012-05-07 23:32

Bump to v0.9.2-2

Changelog: Took Meow's suggestion to force cli mode with this package and removed unnecessary .desktop and .png files.
PKGCommit: http://pkgbuild.com/git/aur-mirror.git/commit/bleachbit-cli?id=718a9d9b8c42be2ee67c2d483768c1ec7902f291

graysky commented on 2012-05-07 20:34

@Meow - thanks for the suggestion. Will look into it.

Meow commented on 2012-05-06 16:49

I think this PKGBUILD script might need a little tweak intead of just copying the "GUI" version with simply excluding pygtk for dependency.
As the package name said is a cli version of bleachbit, but after you installed the package and run bleachbit from console without any arguments, it'll still try to import gtk module in order to get GUI in action, while if it happens you have no pygtk package installed, ImportError will be thrown.
I suggest you add some workarounds like 'sed' replacement in PKGBUILD to change the default behavior of bleachbit script.
Here is the snippet of original script:
#########################
if 1 == len(sys.argv): # 1-> 0
import gtk
import bleachbit.GUI
gui = bleachbit.GUI.GUI()
gtk.main()
else:
import bleachbit.CLI
bleachbit.CLI.process_cmd_line()
#########################
I suggest changing "1" in the first line to "0", then it will always execute the else block, even you run bleachbit without arguments(some usage info will showed).
And of course, don't forget to remove the "$pkgdir"/usr/share/applications" folder during makepkg session.

Meow commented on 2012-05-06 16:47

I think this PKGBUILD script might need a little tweak intead of just copying the "GUI" version with simply excluding pygtk for dependency.
As the package name said is a cli version of bleachbit, but after you installed the package and run bleachbit from console without any arguments, it'll still try to import gtk module in order to get GUI in action, while if it happens you have no pygtk package installed, ImportError will be threw.
I suggest you add some workarounds like 'sed' replacement in PKGBUILD to change the default behavior of bleachbit script.
Here is the snippet of original script:
#########################
if 1 == len(sys.argv): # 1-> 0
import gtk
import bleachbit.GUI
gui = bleachbit.GUI.GUI()
gtk.main()
else:
import bleachbit.CLI
bleachbit.CLI.process_cmd_line()
#########################
I suggest changing "1" in the first line to "0", then it will always execute the else block, even you run bleachbit without arguments(some usage info will showed).
And of course, don't forget to remove the "$pkgdir"/usr/share/applications" folder during makepkg session.

Anonymous comment on 2012-01-26 11:55

thanks.

graysky commented on 2011-11-18 19:37

For those of us not wanting to bring down the 177 megs of pygtk dependencies, this PKG provides the same functionality of bleachbit but with no GUI. I call it from an alias in my ~/.bashrc:

alias bb="sudo bleachbit --clean system.cache system.localizations system.trash system.tmp"