4Suite™ API Documentation

# ► Module Ft.Lib.DistExt.InstallConfig

distutils command for installing the configuration file.

    Copyright 2006 Fourthought, Inc. (USA).
    Detailed license and copyright information: http://4suite.org/COPYRIGHT
    Project home, documentation, distributions: http://4suite.org/

Classes: InstallConfig |  |  |  | Globals: CONFIG_KEYS, CONFIG_MAPPING, CONFIG_STUB, METADATA_KEYS

## Classes

class InstallConfig(distutils.cmd.Command)

  ### Methods

  finalize_options(self)
    Overrides: finalize_options from class Command
  get_outputs(self)
  get_source_files(self)
  initialize_options(self)
    Overrides: initialize_options from class Command
  run(self)
    Overrides: run from class Command
  write_config_module(self, file, install_config)
    Write the configuration variables to a file object.

  ### Methods inherited from class distutils.cmd.Command

  __getattr__, __init__, announce, copy_file, copy_tree, debug_print, dump_options, ensure_dirname, ensure_filename, ensure_finalized, ensure_string, ensure_string_list, execute, get_command_name, get_finalized_command, get_sub_commands, make_archive, make_file, mkpath, move_file, reinitialize_command, run_command, set_undefined_options, spawn, warn

  ### Members

  command_name = 'install_config'
  description = 'install configuration file'
  user_options = [('install-dir=', 'd', 'directory to install to')]

  ### Members inherited from class distutils.cmd.Command

  sub_commands

## Globals

CONFIG_KEYS = ('resourcebundle', 'pythonlibdir', 'bindir', 'datadir', 'sysconfdir', 'localstatedir', 'libdir', 'localedir')
CONFIG_MAPPING = {'bindir': 'scripts', 'datadir': 'data', 'libdir': 'devel', 'localedir': 'l10n', 'localstatedir': 'localstate', 'pythonlibdir': 'lib', 'sysconfdir': 'sysconf'}
CONFIG_STUB = '# Configuration variables\n%(metadata)s\n\nimport s...ation directories\n %(install_config)s\ndel sys\n'
METADATA_KEYS = ('name', 'version', 'fullname', 'url')