Welcome to jaraco.packaging documentation!¶
A script for uploading already packaged sdists and eggs to a cheeseshop
-
class
jaraco.packaging.cheese.
DistFile
(command, pyversion, filename)¶ Bases:
tuple
-
command
¶ Alias for field number 0
-
filename
¶ Alias for field number 2
-
pyversion
¶ Alias for field number 1
-
-
class
jaraco.packaging.cheese.
RevivedDistribution
(source_url)¶ Bases:
setuptools.dist.Distribution
-
cleanup
()¶
-
get_name
()¶
-
get_version
()¶
-
has_ext_modules
()¶
-
-
class
jaraco.packaging.cheese.
TarGZAdapter
(archive)¶ Bases:
object
Wrap a TarFile object to emulate a ZipFile object
-
namelist
()¶
-
open
(filename)¶
-
-
jaraco.packaging.cheese.
URL
(spec)¶ If spec already looks like a URL, just return it. Otherwise, assume it is a filename and return it as a file url.
-
jaraco.packaging.cheese.
do_upload
()¶
-
jaraco.packaging.cheese.
get_args
()¶
-
jaraco.packaging.cheese.
get_prefix_dir
(archive)¶ Often, all files are in a single directory. If so, they’ll all have the same prefix. Determine any such prefix. archive is a ZipFile
-
jaraco.packaging.cheese.
open_archive
(stream, filename)¶ Open an archive (tarball or zip) and return the object.
-
jaraco.packaging.cheese.
register_dist
(repository, distribution)¶
-
jaraco.packaging.cheese.
upload_dist
(repository, distribution, **command_params)¶
-
jaraco.packaging.cheese.
upload_file
(repository, source, **command_params)¶
This module should only import modules from stdlib and setuptools
-
class
jaraco.packaging.depends.
DependencyTree
(dist, **kw)¶ Bases:
setuptools.Command
-
description
= 'Report a tree of resolved dependencies'¶
-
finalize_options
()¶ Set final values for all the options that this command supports. This is always called as late as possible, ie. after any option assignments from the command-line or from other commands have been done. Thus, this is the place to code option dependencies: if ‘foo’ depends on ‘bar’, then it is safe to set ‘foo’ from ‘bar’ as long as ‘foo’ still has the same value it was assigned in ‘initialize_options()’.
This method must be implemented by all command classes.
-
initialize_options
()¶ Set default values for all the options that this command supports. Note that these defaults may be overridden by other commands, by the setup script, by config files, or by the command-line. Thus, this is not the place to code dependencies between options; generally, ‘initialize_options()’ implementations are just a bunch of “self.foo = None” assignments.
This method must be implemented by all command classes.
-
run
()¶ A command’s raison d’etre: carry out the action it exists to perform, controlled by the options initialized in ‘initialize_options()’, customized by other commands, the setup script, the command-line, and config files, and finalized in ‘finalize_options()’. All terminal output and filesystem interaction should be done by ‘run()’.
This method must be implemented by all command classes.
-
user_options
= [('requirement=', 'r', "A setuptools requirement spec (e.g. 'eggmonster' or 'eggmonster==0.1')"), ('python=', 'p', 'Use a remote environment rather than the local one.')]¶
-
-
jaraco.packaging.depends.
check_dependencies
(req, indent=1, history=None)¶ Given a setuptools package requirement (e.g. ‘gryphon==2.42’ or just ‘gryphon’), print a tree of dependencies as they resolve in this environment.
-
jaraco.packaging.depends.
check_dependencies_remote
(args)¶ Invoke this command on a remote Python.
-
jaraco.packaging.depends.
load_dependencies
(req, history=None)¶ Load the dependency tree as a Python object tree, suitable for JSON serialization.
>>> deps = load_dependencies('jaraco.packaging') >>> import json >>> doc = json.dumps(deps)
-
jaraco.packaging.depends.
parse_extras
(req)¶
-
jaraco.packaging.depends.
print_package
(requirement, indent)¶
-
jaraco.packaging.depends.
tree_cmd
()¶
-
class
jaraco.packaging.info.
Show
(dist, **kw)¶ Bases:
setuptools.Command
>>> import sys, functools >>> show_cmd = [sys.executable, "setup.py", "show"] >>> run = functools.partial( ... subprocess.check_output, universal_newlines=True) >>> print(run(show_cmd + ['-a', 'name']), end='') running show jaraco.packaging >>> print(run(show_cmd + ['-a', 'install_requires']), end='') running show "['six>=1.4', 'setuptools']"
-
description
= "Report attributes of a distribution's metadata"¶
-
finalize_options
()¶ Set final values for all the options that this command supports. This is always called as late as possible, ie. after any option assignments from the command-line or from other commands have been done. Thus, this is the place to code option dependencies: if ‘foo’ depends on ‘bar’, then it is safe to set ‘foo’ from ‘bar’ as long as ‘foo’ still has the same value it was assigned in ‘initialize_options()’.
This method must be implemented by all command classes.
-
initialize_options
()¶ Set default values for all the options that this command supports. Note that these defaults may be overridden by other commands, by the setup script, by config files, or by the command-line. Thus, this is not the place to code dependencies between options; generally, ‘initialize_options()’ implementations are just a bunch of “self.foo = None” assignments.
This method must be implemented by all command classes.
-
run
()¶ A command’s raison d’etre: carry out the action it exists to perform, controlled by the options initialized in ‘initialize_options()’, customized by other commands, the setup script, the command-line, and config files, and finalized in ‘finalize_options()’. All terminal output and filesystem interaction should be done by ‘run()’.
This method must be implemented by all command classes.
-
user_options
= [('attributes=', 'a', 'space or comma-separated attributes')]¶
-
-
jaraco.packaging.sphinx.
add_package_url
(app, pagename, templatename, context, doctree)¶
-
jaraco.packaging.sphinx.
load_config_from_setup
(app)¶ Replace values in app.config from package metadata
-
jaraco.packaging.sphinx.
setup
(app)¶