The 'feHappyScripts' subsystem

INSTALLATION DETAILS

NOTE:
'feHappyScripts' is DEPRECATED.
Replaced by 'tkScriptApplicator'
in the 'FILEmanagers' toolchest of
the FE 'tkGooies' subsystem.
(FE = Freedom Environment)

The ability to run
'feNautilusScripts'

even if the various
Linux file managers
eventually fail to
preserve that capability

makes me as happy as
this icon.
Javascript is disabled. Please enable Javascript
in order to see image changes on 'mouse-overs'.

FE Home page > FE Downloads page >

'feHappyScripts' Download page >

This
'feHappyScripts' INSTALLATION DETAILS
page

! Note !
The 'feHappyScripts' subsystem is DEPRECATED
. . . to be replaced by the 'tkScriptApplicator'
utility of the FE 'tkGooies' subsystem.

The 'feHappyScripts' DOWNLOAD page
(and this download-details page) are
provided for historical notes. These notes
may be referenced if the 'tkScriptApplicator'
is ever packaged separate from
the 'tkGooies' system.

'FE HappyScripts' INSTALLATION DETAILS :

The following instructions assume that you have downloaded the 'feHappyScripts' install file (a self-extracting shell script, with appended installation files) from the 'feHappyScripts' download page.

The install file has a suffix of '.sh.exe' or '.sh.tar'.

There is a quick version of installing 'feHappyScripts', in the SUMMARY section at the bottom of that web page.

This install description is meant to provide details that are not provided there.


The install steps, in detail :

Your home directory or the 'Desktop' directory of your home directory will do, as the download directory. BUT ...

    You may find it better to make a directory named 'DOWNLOADS', for example, in your Home directory --- if a Downloads directory does not already exist.

    Then save ALL your 'third party' application install files there, from then on.

    By 'third party', I mean applications that are NOT distributed via an interactive software-package management system of your Linux/Unix system --- like the FE apps are not.

    Seamonkey2 (a Mozilla.org web browser, son of Netscape) is another example of such an app. In mid-2010, it was not available via the 'Ubuntu Software Center' nor via the 'Synaptic Package Manager'.

    I downloaded the Seamonkey2 Linux install file from the Seamonkey website into my $HOME/DOWNLOADS directory --- and I installed it into a $HOME/apps directory that I created for apps that I want to preserve during Linux upgrades.

    I preserve the apps simply by not overlaying my home directory (and backing up my home directory as a precaution).

    I have also installed the SciTE text editor --- 'gscite' --- in my $HOME/apps directory, in a 'gscite_2.27' subdirectory.

    Similarly, the 'feHappyScripts' subsystem will install into a subdirectory of $HOME/apps.


Preparing the downloaded
'.sh' install file for execution :

First, rename the file --- remove the '.exe' or '.tar' suffix.

    If you are positioned at your download directory with the Nautilus file manager, simply right click on the install file, choose 'Rename' in the popup menu, and use the Backspace or Delete key to remove the last 4 characters from the filename.

    If you are in a terminal window, positioned at the download directory, you can use the 'mv' (rename) Linux/Unix command in a form like this :

    mv   whatever.sh.exe   whatever.sh

    NOTE:
    When you download the self-extracting script file to your file system, it may lose its execute permissions.

    [This is a nice security feature on some operating systems, making it harder for people to run rogue programs on your computer.]

    You can make sure the '.sh' file is executable as follows.

    • Navigate to it in the Nautilus file-manager --- if you're not there already.

    • Right-click on it and choose 'Properties' at the bottom of the Nautilus options window that pops up.

    • Go to the 'Permissions' panel on that 'Properties' window and make sure the checkbox labelled 'Allow executing file as program' is turned on.

    Altnernatively, in a terminal window, when you are positioned in the directory in which you put the '.sh' install file, issue the 'chmod 755' command on the filename of the self-extracting script.

    The command format :

    chmod   755   whatever.sh


Content of the '.sh' file :

While you are in that terminal window, you can check out the script lines of the file by issuing the 'head -350' command against the file.

You will see about 325 lines of script text (with lots of comment lines) --- and then some gobbledy-gook characters in the terminal window.

That gobbledy-gook is the starting contents of the gzipped tar file that contains the 'feHappyScripts' installation files.

The self-extracting script is a combination of text lines and binary data.

If you try to view the install script with a text editor, like 'gedit', it will not view the file, because the editor detects the binary data and thinks it is dealing with a binary file.

The authors of 'gedit' do not allow you to try to display the file --- partly because 'lines' in (some) binary data files are thousands of bytes long.

    As an interesting note (at least I think so), the FE 'xpg' utility is not as finicky as 'gedit'.

    If a binary file is not too large (in some sense or another), 'xpg' WILL show the binary file.

    Of course, most of the bytes in the file show as gobbledy-gook characters in the 'xpg' text area.

    But you CAN read strings of human-readable text in the binary file.

    In particular, you can use 'xpg' on the 'feHappyScripts' self-extracting script file.

    It will bring that combined text-and-binary file up quickly with no complaints (no error messages).

    You can see the text of the script at the top of the file.

    In fact, if you scroll down to the part of the file where the binary data starts, the 'xpg' window should not complain or go bye-bye --- even if you scroll to the bottom of that binary data.

    Similarly, for some of the other FE self-extracting script files --- like the ones for the 'FE Nautilus Scripts' releases, you should be able to scroll through the entire self-extracting script file, with 'xpg'.


How to execute the '.sh' install script :

If you are still in a terminal, positioned at the download directory that contains the self-extracting script file, say after doing the 'head' command on the '.sh' file, you could execute the '.sh' script right there via the command line.

(See a GUI mouse-click method, below.)

Enter a command of the form

./whatever.sh

That is, type a dot and slash, then type (or 'mouse-paste') the '.sh' filename and press Enter.

You will see some output from the execution of the script, including

  • 'mkdir' commands that make the 'feHappyScripts_yyyymmmdd' install directory, under $HOME/apps

  • the 'tail' command that is used to extract the gzipped tar file from the '.sh' file --- putting the '.tgz' file in the '/tmp' directory

  • output of the 'file' command applied to the extracted file --- confirming (hopefully) that the extracted file is indeed a 'gzip compressed data' file

  • the output of 'ls -l' on that extracted file --- to show the number of bytes in that gzipped tar file     (It should be 206,320 bytes for the 2013mar08 file.)

  • the output of 'tar ztvf' on the extracted '.tgz' file --- to show the 'table of contents' of the extracted file

      (The table of contents will simply be the directory names and filenames that make up the installation --- along with some file permissions information.)

  • a 'cd' command that sets up the 'working directory' of the install script at the 'feHappyScripts' install directory, for execution of the following un-tar command

  • the output of 'tar zxvf' on the extracted '.tgz' file, which gunzips the file into a tar file and then extracts the contents of that tar file into the install directory

      (The output of 'tar zxvf' will look a lot like the 'table of contents' output, the output of 'tar ztvf' --- but without the file permissions info.)

      (The 't' in the tar command stands for table of contents, the 'x' for extract.)

  • the 'mkdir' commands that make a '.freedomenv' directory in your home directory --- and a subdirectory named 'feHappyScripts' under that directory --- if they did not exist already.

  • two 'cp' commands that copy the 'set_FEDIR.shi' and 'set_feDIR.tki' shell 'include' files from the installation directories 'includes_sh' and 'includes_tk', respectively, to the

    $HOME/.freedomenv/feHappyScripts/

    directory.

      (The 'set_FEDIR.shi' shell 'include' file is code that figures out the install directory from the fully-qualified name of the FE script being called --- that name being available in the $0 variable of the calling script.

      More than you wanted, or needed, to know, eh?)

      (The 'set_feDIR.tki' Tk script 'include' file does a similar thing for the '.tk' scripts of the FE subsystems.)

  • there is also a 'cp' command that copies the file 'fave_dirs.lis' from the installation directory 'lists' to the '$HOME/.freedomenv/feHappyScripts/' directory.

      (The 'fave_dirs.lis' file holds the names of the user's 'favorite' directories to 'jump-navigate' to.)

  • the 'mkdir' command that makes a 'bin' directory in the $HOME/apps directory, if a 'bin' directory did not exist already

  • a link command ( 'ln' ) that makes a link from filename 'feHappyScripts_START.sh' in the 'bin' directory to the 'feHappyScripts_START.sh' startup script in the

    $HOME/apps/feHappyScripts_yyyymmmdd/scripts

    directory.

Some of the many ways to implement that 'feHappyScripts' startup script are described further below.


An alternative to running
the install script by typing its name
in a terminal-shell window --- namely,
a GUI mouse-click method :

If you are positioned at the '.sh' install script (that is, positioned in your download directory) with a GUI file manager like Nautilus, you could double-click on the '.sh' file --- after making sure that it has execute permission, as described above --- and choose the option to 'Run in a terminal'.

You will see the messages described above appearing in the terminal that pops up.

    If the terminal window just flashes and does not stay open (or the installation goes so fast that the terminal window does not even flash), navigate to the '$HOME/apps' directory, and see if the 'feHappyScripts_yyyymmmdd' directory was created.

    Check whether the 'scripts' subdirectory of that directory was created, containing the 'feHappyScripts_START.sh' script.

    And check the 'tkGUIs' subdirectory of the install directory, which should contain a directory named 'tkGUIs_listbox' and several '.tk' files including the 'shofil.tk' file.

    If those directories and files exist, then the installation probably went OK.


Where the application files 'land' :
(via a safer-than-most install strategy)
('root' permissions not required)

When the self-extracting shell script file executes, it automatically puts a set of directories in a

$HOME/apps/feHappyScripts_yyyymmmdd

directory --- that is, under your home directory --- where yyyymmmdd represents a release date.

Example: $HOME/apps/feHappyScripts_2013mar08

Note that you do not have to change to 'root' to do the install.

In fact, I never like having to switch to 'root' to do an install.

    When I have to supply the root password to do an install, I am being put in the position of having to trust the people who put the install package together that they are not going to use that all powerful permission to do serious damage to the root-owned directories and files on my machine.

    And I am trusting that they are NOT going to install key-loggers or Linux/Unix viruses/trojan-horses on my machine, hidden in that massive directory structure.

    Or, 'they' could install a 'hidden' program that sends data to an organization (or person), over the Internet, or do some other useless-to-me thing, whenever their program is 'triggered', hidden among all those directories (and when I have my connection to the Internet on).

      [I, and my wife, have been a victim of these several things on MS Windows. I now setup separate 'admin' and 'user' accounts on MS Windows, similar to 'root' and 'user' on Linux/Unix. This, at least, makes one aware of when a web page or email is trying to install a program unbeknownst to the 'user' --- because an error message will appear when the 'user' does not have 'admin' access to Windows system directories and ProgramFiles directories, where viruses and trojan horses are typically installed.]

    Do you hear that HP, Microsoft, Google, and a large number of software distributors? Cut the nonsense out!

    At least prompt us, before taking liberties with our computers.

    For example, let us decide whether we want your programs to start up as part of our computer's boot up process.

    Maybe we don't want your 'stuff' shoved in our faces every time we log on --- or every time we start up an app in which your personal-data-collecting stuff has been included as an intrusive plugin.

    Furthermore, we do not like lots of ad-riddled games (and other junk programs that most of us will never use) put on our computers.

    (Hear that, Mozilla Firefox and Google and Yahoo??)

So rest easy. This install does not require you to open yourself to damage like mangling of your root-owned directories --- or commandeering of root-owned processes.

No 'root' access/permission/password is required.

And nothing is added to your computer's startup processes.

YOU are the one who decides when the 'feHappyScripts' components are run.

For some simplicity, this install does not ask for an install directory.

It simply makes an 'apps' directory in your home directory, if you do not have one.

And it makes a directory called 'feHappyScripts_yyyymmmdd' under the 'apps' directory.


    Having apps like this in your home directory can be a real boon at Linux OS upgrade time.

    If you follow the procedure of preserving your home directory (as a separate disk partition) during a Linux OS upgrade, then you do not have to re-install the FE 'HappyScripts' subsystem installation files, after your Linux upgrade.

    Since these installation files are not in a system directory like '/usr', they will not be wiped out in a Linux system upgrade.

    And even if you allow the Linux OS upgrade to wipe out your home directory, if you simply drag your 'apps' directory --- and the '.freedomenv' directory --- of your home directory onto a USB stick (or some other storage device) before the Linux upgrade, you can simply drag those two directories back to your home directory after the Linux upgrade is complete.


Size of the installation :

After installation, the 'feHappyScripts' files occupy on the order of 1 Megabyte of disk space.

The 2013mar08 self-extracting install script is 216,683 bytes in size.

About 99% of that is the compressed installation files (mostly scripts and text files).

The installation files, after extraction from the compressed file that was appended to the self-extracting install script, expand to about 1 megabyte in size.

These are very small sizes compared to applications like GIMP or Firefox.

I contend that you can get a lot of bang, for zero bucks, from this relatively small set of small (script) files.


The sub-directories of the FE 'HappyScripts' install :

The install directories go under the 'feHappyScripts_yyyymmmdd' directory --- fullname

$HOME/apps/feHappyScripts_yyyymmmdd.

It is a simple, 'almost-flat' directory structure --- only one level of directories (except for the 'images' directory --- which contains an 'icons' directory ; and except for the 'tkGUIs' directory --- which contains a 'tkGUIs_listbox' directory).

The directory names are

  • helps
  • images
  • includes_sh
  • includes_tk
  • lists
  • scripts
  • tkGUIs

There are less than 10 files in most of these directories and subdirectories.

The main file for the user to be aware of is the main startup script 'feHappyScripts_START.sh' in the 'scripts' directory.


Running 'feHappyScripts' :

If you want to make an 'alias' for the 'feHappyScripts_START.sh' startup script in your '.bashrc' or '.bash_aliases' file, you can use a statement like

alias hs="$HOME/apps/bin/feHappyScripts_START.sh"

which does not contain the 'yyyymmmdd' release identifier.

Hence you will not need to change this alias for future releases.


    "$HOME/apps/bin/feHappyScripts_START.sh" is a 'soft link' to

    "$HOME/apps/feHappyScripts_yyyymmmdd/ scripts/feHappyScripts_START.sh"

    where 'yyyymmmdd' represents the release identifier.

    That link was made during the installation process.


You can also make a desktop icon for 'feHappyScripts', if you wish --- in the usual way for your desktop environment (say Gnome or KDE).

Gnome2 :

    For Gnome 2, you can right-click on the desktop and choose 'Create Launcher ...'.

    In the 'Create Launcher' window that pops up, in the 'Name:' field enter a name like 'feHappyScripts', and in the 'Command:' field, enter the name

    $HOME/apps/bin/feHappyScripts_START.sh

      Note that there is a 'Browse...' option, so you do not have to key in the fully-qualified name of the startup script.

      You can simply navigate to the 'bin' directory of $HOME/apps, and click on the 'feHappyScripts_START.sh' filename.

    Then click 'OK'.

    (If you want to use a different icon from the standard Gnome launcher icon --- a platform on a spring --- click on that launcher icon in the upper left of the 'Create Launcher' window and choose a different icon, before you press OK.)

KDE3 :

    For KDE 3, you could right-click on the desktop and choose 'CreateNew -> Link to Application'.

    In the 'General' panel that pops up, fill in a short name, like 'feHappyScripts', which will appear on the screen under your desktop icon.

    (You can click on the default gear-icon in the panel, and choose a different icon from a large array of icons.)

    Then click on the 'Application' panel and click on the 'Browse' button to find the 'feHappyScripts_START.sh' script that is to be associated with the icon.

    Navigate to

    $HOME/apps/bin

    to find (and select) filename "feHappyScripts_START.sh".


After you have your desktop icon
(for Gnome, KDE, or whatever) :

    You can click on the 'feHappyScripts' icon to bring up the starting directory-navigator-and-file(s)-selector GUI of 'feHappyScripts'.


You can also make feHappyScripts available via a 'quick-launch' icon on the Gnome panel across the top of a Gnome2 desktop.

Simply right-click on the top Gnome 2.x panel and use 'Add to Panel ...'. I leave the rest of the steps as an exercise.

The steps are similar to those for making an icon on the Gnome 'desktop'.


    The self-extracting install script makes a link from the 'feHappyScripts' startup script to a release-ID-independent file,

    $HOME/apps/bin/feHappyScripts_START.sh .

    By using that soft-link, instead of a fully-qualified name like

    $HOME/apps/feHappyScripts_yyyymmmdd/ scripts/feHappyScripts_START.sh,

    where $HOME represents your home directory name, we do not have to remember to make changes to command aliases or desktop icon properties.

For example, I can edit an Ubuntu '.bash_aliases' file in my home directory and set an alias like

alias hs="$HOME/apps/bin/feHappyScripts_START.sh"

instead of

alias hs="$HOME/apps/feHappyScripts_2013mar08/ scripts/feHappyScripts_START.sh"

NOTE: By using

alias hs="$HOME/apps/bin/feHappyScripts_START.sh"

which does not contain a yyyymmmdd qualifier, one does not have to change the alias with each new release.

For an existing 'feHappyScripts' Gnome Desktop icon, you can right-click on the 'feHappyScripts' desktop icon and, in the popup menu that appears, choose 'Properties' at the bottom.

In the 'feHappyScripts Properties' panel that appears, there is a 'Basic' sub-panel with a 'Command:' entry field.

In that entry field, make sure it contains a string of the form

/home/userid/apps/bin/ feHappyScripts_START.sh

rather than

/home/userid/apps/feHappyScripts_yyyymmmdd/ scripts/feHappyScripts_START.sh

NOTE:
With this icon install method, which does not contain a yyyymmmdd qualifier, one does not have to change the command name associated with the icon, for each new release.

If you added 'feHappyScripts' as a quick-launch icon in the Gnome panel at the top of the screen, you could use the same technique to avoid having to update the properties of that quick-launch-panel icon with new releases of feHappyScripts.

We are now ready to use the new installation, via desktop (or panel) icon or via command alias.

FE . . . . Software to Make You Happier
than a Witch in a Broom Factory.

Bottom of this page of
FE 'HappyScripts' INSTALLATION DETAILS.

FE = Freedom Environment

To return to a previously visited web page, click on the Back button of your web browser a sufficient number of times. OR, use the History-list option of your web browser.
OR ...

< Go to Top of Page, above. >

Page history:

Page was created 2013 Mar 08.

Page was changed 2018 Aug 07.
(Added css and javascript to try to handle text-size for smartphones, esp. in portrait orientation.)

Page was changed 2019 Jul 23.
(Specified an image width in percents to size the image according to width of the browser window. Did some minor text reformatting for readability. Added some notes on 'tkGooies' replacing 'feHandyTools' and 'feHappyScripts'.)