How to run Ubuntu Tweak's janitor automatically?

6,419

for the moment the answer is no...

Let me expand on that statement.

In many ways, your question is similar to this Q&A:

Ubuntu Tweak only offers (currently) a limited API call for the executable itself.

Therefore - when trying to invoke a Ubuntu-Tweak feature when starting from startup applications or via a quick list, you can only use the command line parameters that have been made available.

ubuntu-tweak -f janitor is one such feature. There are no command-line parameters (currently) for what you are seeking to do.

You can test this yourself by running ubuntu-tweak -h. The linked answer above shows the typical result you could expect.

Some programs - once running - expose an interface such as dbus that allows you to invoke features via an external program. Rhythmbox is one such software with its rhythmbox-client which can be called externally. Ubuntu-tweak unfortunately does not offer the same external interface.


What you'll need to do is submit a patch to the author that would add a command-line parameter to do the function you are seeking.

Alternatively - add an externally callable interface such as dbus when ubuntu-tweak is actually running.

Share:
6,419

Related videos on Youtube

Eliran Malka
Author by

Eliran Malka

I'm a full stack developer, here's my user story on stackoverflow and linkedin. I like electric guitars, electronic music, user experience, design, programming, sketching, and haiku/poetry. I really enjoy exploring the physics world, specifically high-energy physics, quantum mechanics and string theory. and I love learning.                             #SOreadytohelp

Updated on September 18, 2022

Comments

  • Eliran Malka
    Eliran Malka over 1 year

    My aim is to have the janitor running at startup, with a pre-configured profile (e.g. clean old packages and empty the browser cache), much like CCleaner's /AUTO parameter on Windows.

    The website is lacking any documentation or usage instructions, and I could not find any information on this here on AskUbuntu as well.

    I tried, naturally, to start Ubuntu Tweak from the command line, hoping additional API exists that will come through in this (allegedly) simple task.

    I only got as far as:

    ubuntu-tweak -f janitor
    

    which is a step in the right direction, but what's still missing is a command for the clear action. Is such a command available, or is there any better way of achieving the described behavior?