# setup

Module to prepare a distribution package for uploading to PyPI.

### Global Attributes

Version
appdataFileName
infoFileName
sourceDir

### Classes

None

### Functions

__pyName | Local function to create the Python source file name for the compiled .ui file.
cleanupSource | Cleanup the sources directory to get rid of leftover files and directories.
compileUiFiles | Compile the .ui files to Python sources.
getDataFiles | Function to return data_files in a platform dependent manner.
getLongDescription | Function to get the long description via the README file.
getPackageData | Function to return data files of a package with givene extensions.
getVersion | Function to get the version from file.
prepareAppdataFile | Function to prepare a .appdata.xml file.
prepareInfoFile | Function to prepare an Info.py file.

## __pyName

__pyName(py_dir, py_file)

Local function to create the Python source file name for the compiled .ui file.

py_dir
  suggested name of the directory (string)
py_file
  suggested name for the compile source file (string)

Returns:
  tuple of directory name (string) and source file name (string)

Up

## cleanupSource

cleanupSource(dirName)

Cleanup the sources directory to get rid of leftover files and directories.

dirName
  name of the directory to prune (string)

Up

## compileUiFiles

compileUiFiles(dirName)

Compile the .ui files to Python sources.

dirName
  name of the directory to compile UI files for (string)

Up

## getDataFiles

getDataFiles()

Function to return data_files in a platform dependent manner.

Returns:
  list containing the platform specific data files

Return Type:
  list of tuples of (str, list of str)

Up

## getLongDescription

getLongDescription()

Function to get the long description via the README file.

Returns:
  long description

Return Type:
  str

Up

## getPackageData

getPackageData(package, extensions)

Function to return data files of a package with givene extensions.

package (str)
  name of the package directory
extensions (list of str)
  list of extensions to test for

Returns:
  list of package data files

Return Type:
  list of str

Up

## getVersion

getVersion()

Function to get the version from file.

Returns:
  string containing the version

Return Type:
  str

Up

## prepareAppdataFile

prepareAppdataFile(fileName, version)

Function to prepare a .appdata.xml file.

fileName
  name of the .appdata.xml file (string)
version
  version string for the package (string)

Up

## prepareInfoFile

prepareInfoFile(fileName, version)

Function to prepare an Info.py file.

fileName
  name of the Python file containing the info (string)
version
  version string for the package (string)

Up