Changeset 233 in tailor
- Timestamp:
- 03/22/05 18:31:53 (8 years ago)
- Hash name:
- 20050322173153-97f81-ec7b53123e3a9635cdea9d363c2920fd8db31d20
- Location:
- vcpx
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
vcpx/cvsps.py
r201 r233 14 14 __docformat__ = 'reStructuredText' 15 15 16 from shwrap import SystemCommand 16 from shwrap import SystemCommand, shrepr 17 17 from source import UpdatableSourceWorkingDir, ChangesetApplicationFailure, \ 18 18 InvocationError … … 299 299 module=module, 300 300 revision=revision, 301 workingdir=s ubdir)301 workingdir=shrepr(subdir)) 302 302 if c.exit_status: 303 303 raise TargetInitializationFailure( … … 424 424 425 425 c = CvsAdd(working_dir=root) 426 c(entry= entry)426 c(entry=shrepr(entry)) 427 427 428 428 def __forceTagOnEachEntry(self, root): … … 477 477 478 478 if entries: 479 entries = ' '.join( entries)479 entries = ' '.join([shrepr(e) for e in entries]) 480 480 else: 481 481 entries = '.' … … 490 490 491 491 c = CvsRemove(working_dir=root) 492 c(entry= entry)492 c(entry=shrepr(entry)) 493 493 494 494 def _renameEntry(self, root, oldentry, newentry): -
vcpx/target.py
r230 r233 14 14 15 15 import socket 16 from shwrap import shrepr 16 17 17 18 HOST = socket.getfqdn() … … 269 270 if subdir<>'.': 270 271 c = addentry(working_dir=root) 271 c(entry= repr(subdir))272 c(entry=shrepr(subdir)) 272 273 273 274 for dir, subdirs, files in walk(join(root, subdir)): … … 283 284 if subdirs or files: 284 285 c = addentry(working_dir=dir) 285 c(entry=' '.join([ repr(e) for e in subdirs+files]))286 286 c(entry=' '.join([shrepr(e) for e in subdirs+files])) 287 -
vcpx/darcs.py
r224 r233 12 12 __docformat__ = 'reStructuredText' 13 13 14 from shwrap import SystemCommand 14 from shwrap import SystemCommand, shrepr 15 15 from source import UpdatableSourceWorkingDir, ChangesetApplicationFailure, \ 16 16 GetUpstreamChangesetsFailure … … 193 193 c = SystemCommand(working_dir=root, 194 194 command="darcs pull --all --patches=%(patch)s") 195 output = c(output=True, patch= repr(changeset.revision))195 output = c(output=True, patch=shrepr(changeset.revision)) 196 196 if c.exit_status: 197 197 raise ChangesetApplicationFailure("'darcs pull' returned status %d saying \"%s\"" % (c.exit_status, output.getvalue().strip())) … … 229 229 230 230 output = dpull(output=True, repository=repository, 231 tag=(revision<>'HEAD' and '--tag=%s'%repr(revision) 231 tag=(revision<>'HEAD' and 232 '--tag=%s' % shrepr(revision) 232 233 or '')) 233 234 if dpull.exit_status: … … 257 258 command="darcs add --case-ok --recursive" 258 259 " --quiet %(entry)s") 259 c(entry=' '.join([ e.namefor e in entries]))260 c(entry=' '.join([shrepr(e.name) for e in entries])) 260 261 261 262 def _commit(self,root, date, author, remark, changelog=None, entries=None): … … 267 268 268 269 if entries: 269 entries = ' '.join( entries)270 entries = ' '.join([shrepr(e) for e in entries]) 270 271 else: 271 272 entries = '.' … … 298 299 c = SystemCommand(working_dir=root, 299 300 command="darcs mv %(old)s %(new)s") 300 c(old= oldentry, new=newentry)301 c(old=shrepr(oldentry), new=shrepr(newentry)) 301 302 302 303 def _initializeWorkingDir(self, root, repository, module, subdir, addentry=None): … … 325 326 command="darcs add --case-ok --recursive" 326 327 " --quiet %(entry)s") 327 c(entry=s ubdir)328 c(entry=shrepr(subdir)) -
vcpx/svn.py
r215 r233 12 12 __docformat__ = 'reStructuredText' 13 13 14 from shwrap import SystemCommand 14 from shwrap import SystemCommand, shrepr 15 15 from source import UpdatableSourceWorkingDir, \ 16 16 ChangesetApplicationFailure, GetUpstreamChangesetsFailure … … 310 310 svnco = SvnCheckout(working_dir=basedir) 311 311 svnco(output=True, repository=repository, module=module, 312 wc=s ubdir, revision=revision)312 wc=shrepr(subdir), revision=revision) 313 313 if svnco.exit_status: 314 314 raise TargetInitializationFailure( … … 339 339 340 340 c = SvnAdd(working_dir=root) 341 c(entry=' '.join([ e.namefor e in entries]))341 c(entry=' '.join([shrepr(e.name) for e in entries])) 342 342 343 343 def _commit(self,root, date, author, remark, changelog=None, entries=None): … … 354 354 355 355 if entries: 356 entries = ' '.join( entries)356 entries = ' '.join([shrepr(e) for e in entries]) 357 357 else: 358 358 entries = '.' … … 366 366 367 367 c = SvnRemove(working_dir=root) 368 c(entry=' '.join([ e.namefor e in entries]))368 c(entry=' '.join([shrepr(e.name) for e in entries])) 369 369 370 370 def _renameEntry(self, root, oldentry, newentry): … … 374 374 375 375 c = SvnMv(working_dir=root) 376 c(old= oldentry, new=newentry)376 c(old=shrepr(oldentry), new=repr(newentry)) 377 377 378 378 def _initializeWorkingDir(self, root, repository, module, subdir, addentry=None): -
vcpx/shwrap.py
r65 r233 9 9 from StringIO import StringIO 10 10 from sys import stderr 11 12 def shrepr(str): 13 str = str.replace("'", "\\'") 14 return "'" + str + "'" 11 15 12 16 class VerboseStringIO(StringIO):
Note: See TracChangeset
for help on using the changeset viewer.
