Sorry, this is a long answer. I hope you learn something from it, but I tried to most directly answer your question in the next paragraph and then use the rest of the answer to elaborate on what this means for editing settings outside the caja GUI itself.
A lot of caja's info and settings can usually be found stored in a
dconf GVariant database (a binary file), the same as many other GUI programs use. The file is likely stored in
Not all of Caja's functionality is changed using dconf (for instance, file associations are handled separately and independently of Caja itself per freedesktop.org's specifications), but in a general sense the dconf database is likely where you need to be looking.
Note that the following presumes caja is using dconf, which is only true when
$GSETTINGS_BACKEND is not set or is set to
dconf in caja's environment (it uses dconf in probably at least 90% of all installs, and by default in Debian/Ubuntu/Mint). If the variable is set equal to
gconf, the same basic idea applies but different tools are used and the settings are likely saved in XML files under
~/.gconf instead of in a binary database.
For most users,
dconf has largely replaced
gconf for a few years and MATE uses
dconf by default. One can also directly use the
gsettings CLI tool to largely bypass this confusion (technically MATE is using gsettings (a part of GIO), which can use either), but the dconf syntax is very nice. Nearly everyone using MATE will be using dconf, and this can be easily adapted to using
gconf if necessary as it mostly works similarly from a user perspective.
You can use either a GUI like
dconf-editor or a CLI program like
dconf to manipulate dconf's database. For simple edits I tend to prefer the GUI, despite not being a huge fan of its Gnome3-style look (personally). However, the
dconf CLI tool is quite handy if you want to use a text editor to tweak things or want to do changes programmatically. Thus, the following is a run-down on the
dconf CLI tool and a few suggestions based on how I've used it in the past.
In Debian (and presumably Ubuntu, Linux Mint, and so forth), the
dconf-editor GUI is in the
dconf-editor package, while the CLI tool is in
dconf-cli. In the distant past when I used Mint, this also was true.
For CLI usage, a few examples can be handy. So using
dconf (the CLI tool), to dump all settings for caja, you can do
$ dconf dump /org/mate/caja/
/org/mate/caja/ is the internal 'key' in the database file. Note that the
dconf tool requires that all keys end with trailing slashes. If you want, you can redirect
dconf's output to a file, edit the file more traditionally, and then restore it:
$ dconf dump /org/mate/caja/ > cajaprefs.txt
$ $EDITOR cajaprefs.txt
$ dconf load /org/mate/caja/ < cajaprefs.txt
$EDITOR is your editor of choice (I like emacs a lot, but the MATE default editor would be
dconf load [PATH] restores the data passed on
stdin. Due to this, I use
< to take input from a file, but one could also do
cat cajaprefs.txt | dconf load /org/mate/caja/. My method simply avoids a
cat process being spawned but they should both function the same way.
/org/mate/caja/, one could also export the entire database in text form. Note that this can potentially be dangerous if misused, but it's also quite handy sometimes for searching through the database.
You can also read or write an individual setting with single commands, such as:
$ dconf read /org/mate/caja/preferences/use-iec-units
$ dconf write /org/mate/caja/preferences/use-iec-units true
Note that I think you may have to restart caja for these settings to stick if applied outside its own GUI. It can vary between programs how they deal with manual changes to the dconf database. I use Caja, but within FVWM instead of MATE these days so it's possible some background service isn't running that would normally handle things like this.
dconf help or
dconf help [COMMAND] can be useful in figuring out further usage.
Additionally, you can find the system-wide defaults and the general schema information in the system's schema directory. This is often either the value of
$GSETTINGS_SCHEMA_DIR, or usually
/usr/share/glib-2.0/schemas/org.mate.caja.gschema.xml if not set. Debian uses this path and so does Mint last I checked. These XML files also usually include a textual description of what various settings actually do, which is a handy reference point. You can also read the descriptions using external tools like this one if that's more your cup of tea than looking at XML files.