sdss_install Reference

Install

Install SDSS-IV and SDSS-V software.

class sdss_install.install.Install.Install(options=None)[source]

Bases: object

Main class which calls Install4 and Install5 for SVN and GitHub installations, respectively

build()[source]

Build the installed product.

build_documentation()[source]

Build the documentaion of the installed product.

build_package()[source]

Build the C/C++ product.

checkout()[source]

Call Install5.checkout

clean()[source]

Remove the work directory tree.

clean_directory_install(install_dir=None)[source]

Remove existing install directory if exists and if option –force.

execute_command(command=None, argument=None)[source]

Execute the passed terminal command.

export_data()[source]

Sync class Import data to class Import4 or class Import5.

fetch()[source]

Call set_fetch() of class Install4 or class Install5

finalize()[source]

Log installation final result message.

import_data()[source]

Sync data from class Import4 or class Import5 to class Import.

initialize_data()[source]

Initialize class Install data.

install_external_dependencies()[source]

Install external dependencies.

install_external_github_product(github_product=None)[source]

Install external dependency from GitHub

install_external_product(install_product=None)[source]

Install external products

install_external_svn_product(svn_product=None)[source]

Install external dependency from SVN

logger_build_message()[source]

Log the build message.

make_directory_install()[source]

Make install directory.

reset_options_from_config()[source]

Set absent command-line options from etc/config.ini file, if it exists.

set_build_type()[source]

Analyze the code to determine the build type

set_directory()[source]

Initialize dict self.directory and set value for key ‘original’ to current working directory.

set_directory_install()[source]

Set dict self.directory values for keys ‘root’ and ‘install’.

set_directory_work()[source]

Set dict self.directory value for key ‘work’, used to install product and/or module file. Remove existing work directory.

set_environ()[source]

Set environment variables WORKING_DIR and INSTALL_DIR.

set_exists()[source]

Call set_exists() of class Install4 or class Install5

set_external_path(path=None, path_type=None)[source]

Prepend the given path to the given path_type.

set_external_paths(paths=None)[source]

Set external paths, like PATH, IDL_PATH, and PYTHONPATH

set_external_product_install_dir()[source]

Set the directory for external dependencies.

set_install4()[source]

Set a class Install4 instance.

set_install5()[source]

Set a class Install5 instance.

set_logger(options=None)[source]

Set the logger used by all classes in the package.

set_modules()[source]

Set a class Modules instance.

set_options(options=None)[source]

Set self.options wrapper

set_product()[source]

Call set_product() of class Install4 or class Install5.

set_ready()[source]

Call set_ready() of class Install4 or class Install5.

set_sdss_github_remote_url(use_public=None)[source]

Set the set_sdss_github_remote_url() of class Install5

set_svncommand()[source]

Wrapper for method Install4.set_svncommand()

Install SDSS-IV software.

class sdss_install.install4.Install4.Install4(logger=None, options=None)[source]

Bases: object

Class for sdss_install’ation of SVN repositories.

execute_command(command=None)[source]

Execute the passed terminal command.

fetch()[source]

SVN checkout or export the product version.

set_exists()[source]

Check for existence of the product URL.

set_logger(logger=None)[source]

Set the class logger

set_options(options=None)[source]

Set command line argument options

set_product()[source]

Set self.product dict containing product and version names etc.

set_ready()[source]

Set self.ready after sanity check self.options.

set_svncommand()[source]

Set the SVN command for public, otherwise add username to SVN command.

Install SDSS-V software.

class sdss_install.install5.Install5.Install5(logger=None, options=None)[source]

Bases: object

Class for sdss_installation of GitHub repositories.

checkout()[source]

Checkout branch or tag and, if tag, remove git remote origin.

clone()[source]

Clone the GitHub repository for the product.

execute_command(command=None)[source]

Execute the passed terminal command.

export()[source]

Remove git remote origin.

fetch()[source]

Clone master branch of product version from GitHub then checkout other branch or tag if necessary.

get_bootstrap_version()[source]

Return latest sdss_install tag, if present, otherwise ‘master’.

get_valid_product(github_url=None, product=None, version=None)[source]

Validate the product

get_valid_version(github_url=None, product=None, version=None)[source]

Validate the product version

is_type(type=None, github_url=None, product=None, version=None)[source]

Check if the product_version is a valid Github branch.

set_attributes()[source]

Set class attributes.

set_logger(logger=None)[source]

Set the class logger

set_options(options=None)[source]

Set command line argument options

set_product()[source]

Set self.product dict containing product and version names etc.

set_ready()[source]

Set self.ready after sanity check self.options and product/version validation

set_sdss_github_remote_url(use_public=None)[source]

Set the SDSS GitHub HTTPS remote URL

validate_product_and_version(github_url=None, product=None, version=None)[source]

Validate the product and product version.

Modules

class sdss_install.install.modules.Modules(options=None, logger=None, product=None, directory=None, build_type=None)[source]

Bases: object

Class for handling and preparing the installation of module files

build()[source]

Install the product modulefile (and versionfile if –default is specified).

check_options()[source]

Check for / create a modulefile directory (if there is an etc/product.module file or for the tree product)

load(product=None, version=None)[source]

Hook to module load function.

load_dependencies()[source]

Load dependencies.

set_dependencies()[source]

Set the dependencies by looking for modules loaded in the modules file

set_directory()[source]

Make module file installation directory.

set_file(ext='.module')[source]

Set product module file path.

set_keywords(build_type=None)[source]

Set keywords to configure module.

set_ready()[source]

Set up Modules.

Module

class sdss_install.utils.module.Module(logger=None, options=None)[source]

Bases: object

Class for system module’s shell in python. Replaces system module’s python shell, which has poor pipe handling.

list_modules()[source]

List the currently loaded modules

set_logger(logger=None)[source]

Set the class logger

set_modules_home()[source]

Set modules_home.

set_options(options=None)[source]

Set command line argument options

set_ready()[source]

Set self.ready after setting modules information.

set_tclsh()[source]

Set tclsh exec directory.

set_version()[source]

Set the Modules Release Tcl version string returned by modules –version.

set_version_major_minor_patch()[source]

From the the Modules Release Tcl version string, set version major, minor, and patch.