Mercurial > hg
comparison mercurial/cmdutil.py @ 31320:1b0db28dadf1
cmdutil: directly use repo.vfs.join
The 'repo.join' method is about to be deprecated.
author | Pierre-Yves David <pierre-yves.david@ens-lyon.org> |
---|---|
date | Wed, 08 Mar 2017 16:53:09 -0800 |
parents | 8908f985570c |
children | 53865692a354 |
comparison
equal
deleted
inserted
replaced
31319:42a7195541a1 | 31320:1b0db28dadf1 |
---|---|
199 else: | 199 else: |
200 tobackup = [f for f in newfiles if f in modified or f in \ | 200 tobackup = [f for f in newfiles if f in modified or f in \ |
201 newlyaddedandmodifiedfiles] | 201 newlyaddedandmodifiedfiles] |
202 backups = {} | 202 backups = {} |
203 if tobackup: | 203 if tobackup: |
204 backupdir = repo.join('record-backups') | 204 backupdir = repo.vfs.join('record-backups') |
205 try: | 205 try: |
206 os.mkdir(backupdir) | 206 os.mkdir(backupdir) |
207 except OSError as err: | 207 except OSError as err: |
208 if err.errno != errno.EEXIST: | 208 if err.errno != errno.EEXIST: |
209 raise | 209 raise |
3410 for f, clearable, allowcommit, msg, hint in unfinishedstates: | 3410 for f, clearable, allowcommit, msg, hint in unfinishedstates: |
3411 if not clearable and repo.vfs.exists(f): | 3411 if not clearable and repo.vfs.exists(f): |
3412 raise error.Abort(msg, hint=hint) | 3412 raise error.Abort(msg, hint=hint) |
3413 for f, clearable, allowcommit, msg, hint in unfinishedstates: | 3413 for f, clearable, allowcommit, msg, hint in unfinishedstates: |
3414 if clearable and repo.vfs.exists(f): | 3414 if clearable and repo.vfs.exists(f): |
3415 util.unlink(repo.join(f)) | 3415 util.unlink(repo.vfs.join(f)) |
3416 | 3416 |
3417 afterresolvedstates = [ | 3417 afterresolvedstates = [ |
3418 ('graftstate', | 3418 ('graftstate', |
3419 _('hg graft --continue')), | 3419 _('hg graft --continue')), |
3420 ] | 3420 ] |