This class represent a worktree
Construct a new worktree
Parameters: |
|
---|---|
Raise : | WorkTreeException if two projects have the same name or if two git directories have the same basename |
The root of the work tree.
A dict {name : Project} of projects found in this worktree Initialized with
A dict {name : path} of git repostories found in this worktree
Open a qi worktree.
Returns: | a valid WorkTree instance. If worktree is None, guess it from the current working dir. |
---|
Typical usage from an action is:
# To handle --work-tree option
def configure_parser(parser):
qibuild.worktree.work_tree_parser(parser)
def do(args):
qiwt = qibuild.worktree_open(args.work_tree)
Try to guess the current project directory using the current working dir.