aboutsummaryrefslogtreecommitdiffstats
path: root/libbe
diff options
context:
space:
mode:
authorAaron Bentley <abentley@panoramicfeedback.com>2005-03-09 20:28:18 +0000
committerAaron Bentley <abentley@panoramicfeedback.com>2005-03-09 20:28:18 +0000
commit53f475a31b97cb3e3a84ae099565cb1858af5014 (patch)
treeee4266eda8daaf8306ef2998217ed995ed4376be /libbe
parentcddfa700fd6f22bb0ea9f0a4c1f4566b69494748 (diff)
downloadbugseverywhere-53f475a31b97cb3e3a84ae099565cb1858af5014.tar.gz
Implemented set-root command
Diffstat (limited to 'libbe')
-rw-r--r--libbe/bugdir.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/libbe/bugdir.py b/libbe/bugdir.py
index 5e1d409..7fc1eda 100644
--- a/libbe/bugdir.py
+++ b/libbe/bugdir.py
@@ -26,6 +26,14 @@ def tree_root(dir):
def test_version(path):
assert (file(path, "rb").read() == "Bugs Everywhere Tree 0 0\n")
+def create_bug_dir(path):
+ root = os.path.join(path, ".be")
+ os.mkdir(root)
+ os.mkdir(os.path.join(root, "bugs"))
+ f = file(os.path.join(root, "version"), "wb")
+ f.write("Bugs Everywhere Tree 0 0\n")
+ return BugDir(path)
+
class BugDir:
def __init__(self, dir):
self.dir = dir