atelier.projects¶
A minimalistic command-line project management.
See Usage.
(This module’s source code is available here.)
Functions
|
To be called from your |
|
Find the project info for the given Python module. |
Find the project info for the given nickname. |
|
|
Find the project info for the given directory. |
|
Return SETUP_INFO defined in the |
|
|
|
Execute the |
|
Classes
|
Represents a project. |
-
atelier.projects.
load_inv_namespace
(root_dir)¶ Execute the
tasks.py
file of this project and return its ns.
-
atelier.projects.
add_project
(root_dir, nickname=None)¶ To be called from your
config.py
file.root_dir is the name of a directory which is expected to contain a
tasks.py
.If no nickname is specified, the nickname will be the leaf name of that directory.
Returns a
Project
instance describing the project.
-
atelier.projects.
get_project_from_module
(modname)¶ Find the project info for the given Python module.
-
atelier.projects.
get_project_from_nickname
(name)¶ Find the project info for the given nickname.
-
atelier.projects.
get_project_from_path
(root_dir)¶ Find the project info for the given directory.
-
atelier.projects.
get_setup_info
(root_dir)¶ Return SETUP_INFO defined in the
setup.py
file of the specified root_dir.
-
class
atelier.projects.
Project
(i, root_dir, nickname=None)¶ Bases:
object
Represents a project.
-
main_package
¶ The main package (a Python module object).
-
index
¶ An integer representing the sequence number of this project in the global projects list.
-
config
¶ A dict containing the configuration options of this project. See Project configuration settings.
-
load_info
()¶ The project can be:
Loaded from a config file: we know only the root_dir
instantiated by get_project_from_path() called in setup_from_tasks(): we know also the inv_namespace
instantiated by get_project_from_module() (by sphinxconf.interproject) : we know also the main_package
A project can have no inv_namespace
-
get_xconfig
(name, default=None)¶ Return the specified setting from either main module or tasks.py.
TODO: explain why we need this.
-