Manage your packages when you install a new version of TERR
When a new version of TERR is released, you might want to install it to take advantage of the changes. You can run older and newer versions of TERR on the same computer, or you can uninstall the older version(s). In either case, you probably want to make sure any custom-created packages or packages downloaded from a repository are kept available to the TERR version(s) you are running.
As of TERR version 3.2, the TERR installation includes the directory TERR_HOME/site-library, which is used by default. If you want to use another directory, you can define the environment variable TERR_LIBS_SITE and set it to the directory of your choice.
Initially, the site-library directory is empty. If you have permission to write to the TERR_HOME directory, any packages you create or download are installed in TERR_HOME/site-library.
Installing packages to the site-library directory provides the following advantages.
- It provides you with the means to protect and manage the packages you installed and want to keep, separate from the new installation.
- It separates the packages shipped with TERR so they can be updated with new releases, and so you do not accidentally change or remove them.
The directory TERR_HOME/site-library is added to the head of the search path, which is returned by .libPaths(). For example, on a Windows computer where you have permission to write to the TERR_HOME directory, this function call would appear as follows.
> .libPaths() [1] "C:/Program Files/TIBCO/terr60/site-library" [2] "C:/Program Files/TIBCO/terr60/library"
After installing the new version of TERR, you can just copy the packages from the older TERR_HOME/site-library directory to the new TERR_HOME/site-library directory.
> .libPaths() [1] "C:/users/jdoe/Documents/TERR/x86_64-pc-windows-library/terr6.0" [2] "C:/Program Files/TIBCO/terr60/site-library" [3] "C:/Program Files/TIBCO/terr60/library"