Changeset 1584 in tailor
- Timestamp:
- 05/30/08 10:26:45 (5 years ago)
- Hash name:
- 20080530082645-bb3d1-e730328812d7929b56c431ece3c8d053fa4c0b72
- Files:
-
- 2 edited
-
test-scripts/test-darcs2aegis-simple.sh (modified) (4 diffs)
-
vcpx/repository/aegis/target.py (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
test-scripts/test-darcs2aegis-simple.sh
r1578 r1584 129 129 if test $? -ne 0; then no_result; fi 130 130 131 cat > $work/darcs-repo/bar.txt <<EOF 132 This will be baz.txt 133 EOF 134 if test $? -ne 0; then no_result; fi 135 131 136 darcs mv bar.txt baz.txt --repodir=$work/darcs-repo > log 2>&1 132 137 if test $? -ne 0; then cat log; no_result; fi … … 139 144 # Initialize the aegis repository 140 145 # 141 142 146 unset AEGIS_PROJECT 143 147 unset AEGIS_CHANGE … … 261 265 262 266 diff -u $work/ok $work/history 267 if test $? -ne 0; then fail; fi 268 269 activity="check the aegis baseline vs. darcs repository" 270 diff $work/darcs-repo/baz.txt $workproj/baseline/baz.txt 271 if test $? -ne 0; then fail; fi 272 273 diff $work/darcs-repo/dir/foo.txt $workproj/baseline/dir/foo.txt 263 274 if test $? -ne 0; then fail; fi 264 275 … … 604 615 if test $? -ne 0; then fail; fi 605 616 606 activity="check baz.txt baseline copy" 607 cat > $work/ok <<EOF 608 A simple text file 609 wit some more text. 610 more text again! 611 ancora piu\` test 612 EOF 613 if test $? -ne 0; then no_result; fi 614 615 diff ok $workproj/baseline/baz.txt 617 diff $work/darcs-repo/baz.txt $workproj/baseline/baz.txt 616 618 if test $? -ne 0; then fail; fi 617 619 -
vcpx/repository/aegis/target.py
r1570 r1584 315 315 316 316 def __move_file(self, old_name, new_name): 317 # 318 # The aegis command to rename files does not have the -keep 319 # option to preserve the content of the file, do it manually. 320 # 321 fp = open(os.path.join(self.repository.basedir, new_name), 'rb') 322 content = fp.read() 323 fp.close() 317 324 cmd = self.repository.command("-move", 318 325 "-not-logging", … … 326 333 "%s returned status %d, saying: %s" % 327 334 (str(move_file), move_file.exit_status, output.read())) 335 336 # 337 # Restore the previously saved content of the renamed file. 338 # 339 fp = open(os.path.join(self.repository.basedir, new_name), 'wb') 340 fp.write(content) 341 fp.close() 328 342 329 343 def __remove_file(self, file_name):
Note: See TracChangeset
for help on using the changeset viewer.
