本文整理汇总了Python中datalad.support.annexrepo.AnnexRepo.annex_proxy方法的典型用法代码示例。如果您正苦于以下问题:Python AnnexRepo.annex_proxy方法的具体用法?Python AnnexRepo.annex_proxy怎么用?Python AnnexRepo.annex_proxy使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类datalad.support.annexrepo.AnnexRepo
的用法示例。
在下文中一共展示了AnnexRepo.annex_proxy方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: ok_clean_git_annex_proxy
# 需要导入模块: from datalad.support.annexrepo import AnnexRepo [as 别名]
# 或者: from datalad.support.annexrepo.AnnexRepo import annex_proxy [as 别名]
def ok_clean_git_annex_proxy(path):
"""Helper to check, whether an annex in direct mode is clean
"""
# TODO: May be let's make a method of AnnexRepo for this purpose
ar = AnnexRepoNew(path)
cwd = os.getcwd()
os.chdir(path)
try:
out = ar.annex_proxy("git status")
except CommandNotAvailableError, e:
raise SkipTest
示例2: ok_clean_git_annex_proxy
# 需要导入模块: from datalad.support.annexrepo import AnnexRepo [as 别名]
# 或者: from datalad.support.annexrepo.AnnexRepo import annex_proxy [as 别名]
def ok_clean_git_annex_proxy(path):
"""Helper to check, whether an annex in direct mode is clean
"""
# TODO: May be let's make a method of AnnexRepo for this purpose
ar = AnnexRepo(path)
cwd = getpwd()
chpwd(path)
try:
out = ar.annex_proxy("git status")
except CommandNotAvailableError as e:
raise SkipTest
finally:
chpwd(cwd)
assert_in("nothing to commit, working directory clean", out[0], "git-status output via proxy not plausible: %s" % out[0])