Menu to install applications from default repositories, third-party ones or other sources on any Ubuntu 14.04, Debian 7, Linux Mint 17 or LMDE system (desktop or server). Users can easily customize their application list just editing a single text file and extend menu functionality by adding custom subscripts.
Shell
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
common
etc
eula
icons
languages
non-repository-apps
post-installation
pre-installation
scripts
third-party-repo
LEEME.md
LICENSE
README.md
installer.sh

README.md

Linux app installer

Menu to install applications from default repositories, third-party ones or external sources on any Ubuntu 14.04, Debian 7, Linux Mint 17 or LMDE system (desktop or server). There are a lot of applications included in the default list, but this list can be modified by the user by just editing a single text file. Furthermore, users can add subscripts to extend main menu functionality, for example, add new repositories, setup applications, etc. In addition, exist one separate script for each application as an alternative way to do the installation proccess without the main menu.

Main menu screenshot through Zenity box for desktop system

Main menu screenshot through Dailog box for terminal system

Index
  1. Features
  2. Installing this project
  3. Executing a script
  4. Execution's lifecycle
  5. Extend functionality and customize applications to install
  6. Add new translation file
Valid for:   Ubuntu v14.04, Debian 7, Linux Mint 17 and LMDE (for all desktops o server).
             With some changes in config files, it can be 100% compatible with previous versions.
Version:     1.2
Last change: 25/05/2014 (dd/mm/yyyy)
DONE
  • Added compatibility with Ubuntu 14.04 (unity/gnome/kde/xfce/lxde/server)
  • Added compatibility with Debian 7
  • Added compatibility with Linux Mint 17 (cinnamon/mate)
  • Added compatibility with LMDE (cinnamon/mate)
  • Created spanish translation of this document in LEEME.md file
TODO
  • Develop Github web page

1. Features

  • One main script that shows a menu of aplications wich can be selected for installation.
  • Alternatively, there is one separate script for each application, so it can be installed by just executing the appropriate script.
  • Install official repository applications.
  • Add third-party repositories and install related applications when needed.
  • Download, extract and install non-repository applications through custom subscripts that extend the main script functionality. It includes several subscripts by default.
  • Set up applications after they are installed through custom subscripts.
  • Customize your own application list to install and third party repositories to add by just editing some config files (no need to edit main script at all for this purpose).
  • EULA support. Install applications automatically with no need of user interaction to accept legal terms of the application.
  • The script runs with an interface adapted to the detected enviroment: Dialog for terminal. Zenity for desktop or terminal emulator.
  • Installation log file that shows installation steps and errors if they have occurred.
  • Multilingual support. Easy to add new translations. For the time being English and Spanish languages are included. The script detects system language and it use the appropiate translation.

Back to index

2. Installing this project

2.1 Method 1. Clone this repository

$ sudo apt-get install git
$ git clone -b master https://github.com/cesar-rgon/linux-app-installer.git
$ cd linux-app-installer

2.2 Method 2. Download and extract files

$ wget https://github.com/cesar-rgon/linux-app-installer/archive/master.tar.gz
$ tar -xvf master.tar.gz
$ cd linux-app-installer-master

Back to index

3. Executing a script

3.1 Main script

It shows a menu of applications to be installed which are ordered by categories. The user navigates through categories and selects the applications to be installed. After that, installation process begins.

$ bash installer.sh

3.2 Application script

There is one separate script for each application, so it can be installed just by running the appropriate script.

$ bash ./scripts/applicationName.sh

Back to index

4. Execution's lifecycle

  1. The user must select the applications to install.
  2. The script would add third-party repositories of the selected third-party applications, when required.
  3. The script executes custom subscripts to prepare the installation of some applications.
  4. The script installs all the selected repository applications with EULA support if required.
  5. The script executes custom subscripts to install the selected non-repository applications.
  6. The script executes custom subscripts to setup selected applications.
  7. The script runs final operations to finish installation process and to clean temporal files.
  8. The script shows an installation log file which contains installation steps and errors if they have occurred.

Main script runs all the previous steps, whereas individual application scripts skip step 1 and run the remaining.


Back to index

5. Extend functionality and customize applications to install

To extend script functionality is required to add subscripts for custom purposes. To customize applications to install, it's necessary to edit some config files. These actions will be detailed in next chapters.

5.1 Understanding project structure

Tree of folders and some files:

├── common                  It contains common functions and variables used by installation scripts
│   ├── commonFunctions.sh
│   ├── commonVariables.sh
│   ├── menuFunctions.sh
│   └── *
│
├── etc                     It contains application list and some config files used by subscripts
│   ├── applicationList.debian
│   ├── applicationList.linuxmint
│   ├── applicationList.lmde
│   ├── applicationList.ubuntu
│   └── *
│
├── eula                    It contains files who set parameters to skip questions during installation's process
│   ├── template-eula
│   └── *
│
├── icons                   It contains sets of application icons used by subscripts
│   ├── *
│   └── installer           It contains icons used by installation scripts
│       └── *
├── installer.sh
│
├── languages               It contains language translations used by installation scripts
│   ├── en.properties
│   └── es.properties
│
├── non-repository-apps     It contains subscripts to install non-repository applications
│   ├── template-non-repo-app.sh
│   ├── *                   Subscripts used on any linux system
│   ├── debian              Subscripts only used on a Debian system
│   │   └── *
│   ├── linuxmint           Subscripts only used on a Linux Mint system
│   │   └── *
│   ├── lmde                Subscripts only used on a LMDE system
│   │   └── *
│   └── ubuntu              Subscripts only used on an Ubuntu system
│       └── *
│
├── post-installation       It contains subscripts to setup applications after installation
│   ├── template-post-installation.sh
│   ├── *                   Subscripts used on any linux system
│   ├── debian              Subscripts only used on a Debian system
│   │   └── *
│   ├── linuxmint           Subscripts only used on a Linux Mint system
│   │   └── *
│   ├── lmde                Subscripts only used on a LMDE system
│   │   └── *
│   └── ubuntu              Subscripts only used on an Ubuntu system
│       └── *
│
├── pre-installation       It contains subscripts to prepare the installation of some applications
│   ├── template-pre-installation.sh
│   ├── *                   Subscripts used on any linux system
│   ├── debian              Subscripts only used on a Debian system
│   │   └── *
│   ├── linuxmint           Subscripts only used on a Linux Mint system
│   │   └── *
│   ├── lmde                Subscripts only used on a LMDE system
│   │   └── *
│   └── ubuntu              Subscripts only used on an Ubuntu system
│       └── *
├── README.md
│
├── scripts                 It contains one installation script per application
│   ├── template-script.sh
│   └── *.sh
│
└── third-party-repo        It contains subscripts to add third-party repositories for some applications
    ├── template-repository.sh
    ├── *                   Subscripts used on any linux system
    ├── debian              Subscripts only used on a Debian system
    │   └── *
    ├── keys                It contains key files used by third-party repository's subscripts
    │   └── *
    ├── linuxmint           Subscripts only used on a Linux Mint system
    │   └── *
    ├── lmde                Subscripts only used on a LMDE system
    │   └── *
    └── ubuntu              Subscripts only used on an Ubuntu system
        └── *
Some important files Description
commonFunctions.sh It contains common functions used by all the installation scripts
commonVariables.sh It contains common variables available for all subscripts
menuFunctions.sh It contains menu functions. Used only by main script
applicationList.debian It defines categories, applications and packages used by main script for a Debian system
applicationList.linuxmint It defines categories, applications and packages used by main script for a Linux Mint system
applicationList.lmde It defines categories, applications and packages used by main script for a LMDE system
applicationList.ubuntu It defines categories, applications and packages used by main script for an Ubuntu system
installer.sh Main script file
en.properties English translation file
es.properties Spanish translation file
template-script.sh Template file to help to create new script file to install an application
template-repository.sh Template file to help to create new subscript to add a third-party repository
template-pre-installation.sh Template file to help to create new application subscript to run pre-installation commands
template-eula Template file to help to create new subscript to setup EULA support for a package
template-non-repo-app.sh Template file to help to create new subscript to install a non-repository application
template-post-installation.sh Template file to help to create new application subscript to run post-installation commands

Back to index

5.2 Add new application to a category. Modify or delete an existing one

To add an application to be installed follow next steps:

  1. Edit applicationList.ubuntu, applicationList.debian, applicationList.linuxmint or applicationList.lmde file and add a new line with the next syntax:
1st column - Category (*) 2nd column - Application Name (*) Other columns (Packages)
Existing/New_category_name Application_name repository package(s)

Considerations:

  • Blank or comment lines are ignored in this file.
  • First column - Category: is mandatory.
  • Category name is repeated once per application contained in it.
  • If the category name is new in the file, the script will generate a new window for this category.
  • Each category should contain at least one application.
  • The category name shall contain only letters, digits and/or underscores '_' and it can't start with a digit.
  • Second column - Application name: is mandatory.
  • Just one row per application.
  • The application name shall contain only letters, digits and/or underscores '_' and it can't start with a digit.
  • The application source can be official repositories, third-party repositories even other sources (non-repositories).
  • The order in which applications are listed in the menu is the same as set in this file.
  • Third column - Packages: is mandatory only if the application belongs to a repository.
  • Packages must be separated by whitespaces.
  • Non-repository applications must leave this field empty.
  1. Edit en.properties file and add a description for categories (if it's new) and applications with the next syntax: CategoryNameDescription=Here goes the category description that is used by the main menu
    ApplicationNameDescription=Here goes the application description that is used by the main menu

    Considerations:

    • CategoryNameDescription is composed by CategoryName word: must be identical (case-sensitive) to the category name defined in applicationList.ubuntu, applicationList.debian, applicationList.linuxmint or applicationList.lmde file. Description word: must always follow the category name word.
    • To be intuitive, CategoryNameDescription should be defined in the 'CATEGORIES' section of the file.
    • ApplicationNameDescription is composed by: ApplicationName word: must be identical (case-sensitive) to the application name defined in applicationList.ubuntu, applicationList.debian, applicationList.linuxmint or applicationList.lmde file. Description word: must always follow the application name word.
    • To be intuitive, ApplicationNameDescription should be defined in the 'APPLICATIONS' section of the file.
    • It's recommended, but not mandatory, to add those descriptions to other translation files.
    • You can create a new translation file in your native language to be easier for your understanding. See chapter Add new translation file for more information.

To modify or delete an application or category just edit applicationList.ubuntu, applicationList.debian, applicationList.linuxmint or applicationList.lmde file and change the corresponding lines.


Back to index

5.3 Add new subscript to install an application

To add a new installation script for an application follow next steps:

  1. Create a new file './scripts/application-name.sh' taking, as base, next commands from template-script.sh file

    #!/bin/bash
    scriptRootFolder=`pwd`/..
    . $scriptRootFolder/common/commonFunctions.sh
    appName=""  # Here goes application name. It must be identically (case-sensitive) to the application name defined in ../etc/applicationList.<distro> file.
    logFile=""  # Here goes log file name that will be created in ~/logs/logFile
    
    prepareScript "$scriptRootFolder" "$logFile"
    installAndSetupApplications $appName
  2. Modify content to asign values to variables: appName and logFile
    Considerations:


Back to index

5.4 Add new subscript to add third-party repository

To add a new subscript to add a third-party repository for an application follow next steps:

  1. Create a new file 'applicationName.sh' taking, as base, the template-repository.sh file.

    Considerations:

    • The filename must be identically (case-sensitive) to the application name defined in applicationList.ubuntu, applicationList.debian, applicationList.linuxmint or applicationList.lmde file.
    • If the script is valid for all linux distros, it must be placed in ./third-party-repo folder.
    • If the script is only valid for Ubuntu distros, it must be placed in ./third-party-repo/ubuntu folder.
    • If the script is only valid for Debian distros, it must be placed in ./third-party-repo/debian folder.
    • If the script is only valid for Linux Mint distros, it must be placed in ./third-party-repo/linuxmint folder.
    • If the script is only valid for LMDE distros, it must be placed in ./third-party-repo/lmde folder.
    • The scripts placed within the specific distro folders have more preference over the scripts placed in ./third-party-repo folder.
  2. Add neccessary commands at the end of the file to add the repository
    Considerations:

    • No need to use 'sudo' in commands because the subscript will be executed as root user.
    • Use common variables supplied by main script as needed.
    • This script must be non-interactive, this means, no echo to monitor, no read from keyboard, no wait confirmation.
    • If commands need to use a key file, it should be placed in keys folder.

Back to index

5.5 Add new subscript to prepare the installation of an application

To add a new subscript to prepare the installation of an application before the installation proccess begins just follow next steps:

  1. Create a new file 'applicationName.sh' taking, as base, the template-pre-installation.sh file.

    Considerations:

    • The filename must be identically (case-sensitive) to the application name defined in applicationList.ubuntu, applicationList.debian, applicationList.linuxmint or applicationList.lmde file.
    • If the script is valid for all linux distros, it must be placed in ./pre-installation folder.
    • If the script is only valid for Ubuntu distros, it must be placed in ./pre-installation/ubuntu folder.
    • If the script is only valid for Debian distros, it must be placed in ./pre-installation/debian folder.
    • If the script is only valid for Linux Mint distros, it must be placed in ./third-party-repo/linuxmint folder.
    • If the script is only valid for LMDE distros, it must be placed in ./third-party-repo/lmde folder.
    • The scripts placed within the specific distro folders have more preference over the scripts placed in ./pre-installation folder.
  2. Add neccessary commands at the end of the file to setup the application Considerations:

    • No need to use 'sudo' in commands because the subscript will be executed as root user.
    • Use common variables supplied by main script as needed.
    • This script must be non-interactive, this means, no echo to monitor, no read from keyboard, no wait confirmation.

Back to index

5.6 Add new subscript to install a non-repository application

To add a new subscript to install a non-repository application just follow next steps:

  1. Create a new file 'applicationName.sh' taking, as base, the template-non-repo-app.sh file.

    Considerations:

    • The filename must be identically (case-sensitive) to the application name defined in applicationList.ubuntu, applicationList.debian, applicationList.linuxmint or applicationList.lmde file.
    • If the script is valid for all linux distros, it must be placed in ./non-repository-apps folder.
    • If the script is only valid for Ubuntu distros, it must be placed in ./non-repository-apps/ubuntu folder.
    • If the script is only valid for Debian distros, it must be placed in ./non-repository-apps/debian folder.
    • If the script is only valid for Linux Mint distros, it must be placed in ./third-party-repo/linuxmint folder.
    • If the script is only valid for LMDE distros, it must be placed in ./third-party-repo/lmde folder.
    • The scripts placed within the specific distro folders have more preference over the scripts placed in ./non-repository-apps folder.
  2. Add neccessary commands at the end of the file to download and install the non-repository application Considerations:

    • No need to use 'sudo' in commands because the subscript will be executed as root user.
    • Use common variables supplied by main script as needed.
    • This script must be non-interactive, this means, no echo to monitor, no read from keyboard, no wait confirmation.

Back to index

5.7 Add new subscript to setup an application

To add a new subscript to setup an application after installation proccess just follow next steps:

  1. Create a new file 'applicationName.sh' taking, as base, the template-post-installation.sh file.

    Considerations:

    • The filename must be identically (case-sensitive) to the application name defined in applicationList.ubuntu, applicationList.debian, applicationList.linuxmint or applicationList.lmde file.
    • If the script is valid for all linux distros, it must be placed in ./post-installation folder.
    • If the script is only valid for Ubuntu distros, it must be placed in ./post-installation/ubuntu folder.
    • If the script is only valid for Debian distros, it must be placed in ./post-installation/debian folder.
    • If the script is only valid for Linux Mint distros, it must be placed in ./third-party-repo/linuxmint folder.
    • If the script is only valid for LMDE distros, it must be placed in ./third-party-repo/lmde folder.
    • The scripts placed within the specific distro folders have more preference over the scripts placed in ./post-installation folder.
  2. Add neccessary commands at the end of the file to setup the application Considerations:

    • No need to use 'sudo' in commands because the subscript will be executed as root user.
    • Use common variables supplied by main script as needed.
    • This script must be non-interactive, this means, no echo to monitor, no read from keyboard, no wait confirmation.

Back to index

5.8 Add new subscript to setup EULA support

To add a new subscript to setup EULA support for a package just follow next steps:

  1. Create a new file './eula/packageName' taking, as base, next commands from template-eula file.

    ##########################################################################
    # This file contains debconf's parameters to avoid interactive
    # installation of the package to confirm EULA.
    #
    # Format: <package> <module>/<parameter> <command> <value>.
    # See man debconf or debconf-set-selections for more information.
    ##########################################################################
    
    # ...

    Considerations:

  2. Add parameters at the end of the file with the syntax indicated in template file to skip EULA questions during installation proccess.


Back to index

6. Add new translation file

To add a new translation file for a specific language just follow next steps:

  1. Create a new file './languages/xx.properties' with the content of an existing translation file, for example, en.properties Considerations:

    • 'xx' must consist of two lowercase characters based on ISO639-1 code for the specific language.
  2. Translate values of all variables to the specific language.
    Considerations:

    • The variable names must not be changed at all.

Back to index

Author notes

Any contribution to this project would be appreciated.
I hope you find it useful.