set permanent script options
Page Version: 1.6 Page Updated: 2014-02-21
Please go to the options page if you are just looking for how to use script options, not set them permanently.
Sometimes you might want to always use a script option, or change some other value in a script. Now you can do this easily, by simply adding an option file, which the script will read.
This feature is available in smxi, svmi, and sgfxi.
ALERT: remember, you cannot override most of these options when you set them sticky. The only ones you can override are the ones that have a value other than 'true', otherwise it will always run, so be sure to only set options you always use.
All items in this file will be logged each time you run the script to assist with debugging (it's guaranteed, of course, that people will make typos or mistakes). Remember, if you don't spell the variable name right, it will get ignored in the script completely.
The first step is to make the script values file, which the script will always test for before running, and it will include automatically any options values you set in there. Remember, this is going to change the default global script values, so try to be careful.
You can either edit the /usr/local/bin/XXXX-values file directly, or simply echo the value to it. I'll use the echo method here to show it here to keep it simple.
For non standard use, advanced testing and development features, look at developer only options and information.
smxi :: sticky option file
First, make the file, which smxi will test for and use if present:
# create the file first, as root in terminal touch /usr/local/bin/smxi-values
Here's a list of supported variables and option hard coding values, nothing else will be officially supported.
-
smxi -K is deprecated and has been replaced by using experimental repos in your sources.list or sidux.list or liquorix.list file. Just add exp.main to your existing entry.
# for sidux, add (use sidux.com repo only for experimental packages): deb http://sidux.com/debian/ main exp.main # for liquorix, assuming you already have liquorix sources: deb http://liquorix.net/debian/ main exp.main
Note that these experimental repos don't always have stuff in them, so you might have to remove them to avoid file not found errors from apt, it depends, try it and see. -
To change color scheme. 0 is standard, default, single color, the default for your console; 1 is script default colors; 2 is a gray/blue type theme; 3 is a earth type color theme (fine for dark/light or light/dark consoles), 4 is a darker scheme which is good for light background consoles.
echo SCRIPT_COLORS=1 >> /usr/local/bin/smxi-values
- This bypasses the hit enter to continue questions in script (same as: smxi -e).
echo SKIP_ENTER='true' >> /usr/local/bin/smxi-values
- Never show the graphics install question, largely useless (same as: smxi -g).
echo SKIP_GRAPHICS='true' >> /usr/local/bin/smxi-values
- Never show your system information, last updated, etc, information when script starts (same as: smxi -i).
echo SKIP_INFO='true' >> /usr/local/bin/smxi-values
- Never show the first kernel install question. It's preferred to use the script option in Post Upgrade Options -> Miscelanious Tweaks -> Advanced Tweaks -> default-system-kernel set to: no-kernel instead of hardcoding it here, but you can also use this if you prefer (same as: smxi -k).
echo SKIP_KERNEL='true' >> /usr/local/bin/smxi-values
- Never show the post upgrade options section, skip right to graphics install (same as: smxi -t).
echo SKIP_TWEAKS='true' >> /usr/local/bin/smxi-values
- Force install of non-pae kernel on a system that supports pae kernels. Currently (2014-02-21) this option only is useful for siduction kernels because siductions kernel guy towo is the only person shipping pae/non pae 686 kernels in Debian based systems that I am aware of and that smxi supports as a kernel option.
echo B_FORCE_NON_PAE='true' >> /usr/local/bin/smxi-values
- Always use debdelta-upgrade for system upgrades (same as: smxi -! 40).
echo B_USE_DEBDELTA='true' >> /usr/local/bin/smxi-values
Note: you must have debdelta installed to use this feature or smxi will exit with error. debdelta is useful if you are bandwidth limited, or if your connection is very slow. If you don't know what this is please read up on it (debdelta-upgrade man page) before implementing it, and make sure it works for your system.
If you picked for example the ADVANCED_KERNEL and SCRIPT_COLORS options, your /usr/local/bin/smxi-values file would look like this:
ADVANCED_KERNEL='true' SCRIPT_COLORS=3
And if you wanted to change that in the future, you can just edit that file, or delete it, and smxi will return to its defaults.
smxi :: manual settings in /etc/smxi.conf
There are a few options you can set in the smxi configuration file if you want. You will need to edit /etc/smxi.conf as root to make these changes.
-
Set manual hold install packages for smxi to use during your dist-upgrade/upgrade. Note, these lists must be separated by a ^ character and must NOT contain any spaces. First make sure the item: hold-install= does not appear, then add it, or update it if it's already there.
hold-install=<package-one>^<package2>
You can have as many items in this list as you want.
-
Change your default apt program. The options are apt-get, and aptitude, if you have it installed. If you don't see the choice of which apt-type to use in Miscellaneous Tweaks -> Advanced Tweaks, then you can just add it to your smxi.conf file like this:
apt-type=apt-get
or, if you want aptitude:
apt-type=aptitude
Remember, aptitude cannot be added here if you don't have it installed, you'll get errors all over the place if you try that.
Remember that you made these changes, they will run every time smxi runs.
sgfxi :: sticky options
There are a few options you might want to set to always run, but overall, because sgfxi changes so often, I don't recommend making very many options sticky.
First, create the sticky option file:
touch /usr/local/bin/sgfxi-values
-
This one is to force composite ON for your card (same as: sgfxi -c). Note that sgfxi now always turns by default composite ON for most nvidia cards, so this isn't needed.
echo B_COMPOSITE='true' >> /usr/local/bin/sgfxi-values
-
This one is to force composite OFF for your card (same as: sgfxi -q). Note that sgfxi now always turns by default composite ON for most nvidia cards, so if you don't use or want composite, set this:.
echo B_FORCE_NO_COMPOSITE='true' >> /usr/local/bin/sgfxi-values
-
If you have an xorg file that you want to never update or change, you can use this option, but make sure you know why you do this before selecting it. Usually only complex xorg.conf files, like ones that handle one monitor but two cards, for instance, should be left alone (same as: sgfxi -C).
echo B_SKIP_CONFIG='true' >> /usr/local/bin/sgfxi-values
-
This is for nVidia only. Turns off ignoreDisplayDevices, lets TV be used (same as: sgfxi -d).
echo B_DISPLAY_DEVICES='true' >> /usr/local/bin/sgfxi-values
-
To change color scheme. 0 is standard, default, single color, the default for your console; 1 is script default colors; 2 is a gray/blue type theme; 3 is a earth type color theme (fine for dark/light or light/dark consoles), 4 is a darker scheme which is good for light background consoles.
echo SCRIPT_COLORS=2 >> /usr/local/bin/sgfxi-values
Since sgfx can also run in X to build modules and so on, and if you use a dark on light terminal like konsole or xterm, you'll probably want to set this or use -j 4 manually. -
If you always want to install the Debian/Ubuntu version of the driver, this will do it (same as: sgfxi -s):
echo B_USE_DISTRO_DRIVER='true' >> /usr/local/bin/sgfxi-values
-
If you always want to install FGLRX using the often failing fglrx run package deb / build install method, this will do it (same as: sgfxi -F):
echo B_FGLRX_DEB_BUILDER='true' >> /usr/local/bin/sgfxi-values
-
If you always want to install the latest nVidia beta driver (if available), this will do it (same as: sgfxi -B):
echo B_USE_BETA='true' >> /usr/local/bin/sgfxi-values
svmi :: sticky options
svmi doesn't really have many options you'd want to set routinely, but in case you can think of anything, here's how.
# create the file first, as root in terminal touch /usr/local/bin/svmi-values
In general, there really aren't that many options you'd want to always have on, because the only useful ones override script and run things automatically, which is a pain if you want to do anything else at some point. So I'm not going to recommend anything here.