PyFoam.Basics.GeneralVCSInterface module¶
General interface to VCS implementations
-
class
PyFoam.Basics.GeneralVCSInterface.
GeneralVCSInterface
(path, init=False)[source]¶ Bases:
object
This is an abstract class that implements an interface to general VCS operations
-
addGlobToIgnore
(expr)[source]¶ Add to the ignore-facility of the current VCS :param expr: a glob expression
-
addPath
(path, rules=[])[source]¶ Add the path to the repository (no commit) :param path: the path (directory or file) to commit :param rules: a list of tuples: first is whether to include or exclude the regular expression that is the second member of the tuple
-
addRegexpToIgnore
(expr)[source]¶ Add to the ignore-facility of the current VCS :param expr: a regular expression
-
doInPath
(func, *args, **kwargs)[source]¶ Execute a function in the root directory of the repository. Afterwards change back ot the original directory. Result of the function is returned
Parameters: func – the function to be executed
-
-
PyFoam.Basics.GeneralVCSInterface.
getVCS
(vcs, path, init=False, tolerant=False)[source]¶ Factory to create a proper VCS-interface :param vcs: name of the VCS-implementation :param path: path which is under version control :param init: whether the Version-control should be initialized here :param tolerant: If there is no interface for the VCS in question return None