Show More
@@ -177,11 +177,14 b' def createcmd(ui, repo, pats, opts):' | |||||
177 | hasmq = util.safehasattr(repo, 'mq') |
|
177 | hasmq = util.safehasattr(repo, 'mq') | |
178 | if hasmq: |
|
178 | if hasmq: | |
179 | saved, repo.mq.checkapplied = repo.mq.checkapplied, False |
|
179 | saved, repo.mq.checkapplied = repo.mq.checkapplied, False | |
|
180 | backup = repo.ui.backupconfig('phases', 'new-commit') | |||
180 | try: |
|
181 | try: | |
|
182 | repo.ui. setconfig('phases', 'new-commit', phases.secret) | |||
181 | editor = cmdutil.getcommiteditor(editform='shelve.shelve', **opts) |
|
183 | editor = cmdutil.getcommiteditor(editform='shelve.shelve', **opts) | |
182 | return repo.commit(message, user, opts.get('date'), match, |
|
184 | return repo.commit(message, user, opts.get('date'), match, | |
183 | editor=editor) |
|
185 | editor=editor) | |
184 | finally: |
|
186 | finally: | |
|
187 | repo.ui.restoreconfig(backup) | |||
185 | if hasmq: |
|
188 | if hasmq: | |
186 | repo.mq.checkapplied = saved |
|
189 | repo.mq.checkapplied = saved | |
187 |
|
190 | |||
@@ -235,8 +238,6 b' def createcmd(ui, repo, pats, opts):' | |||||
235 | ui.status(_("nothing changed\n")) |
|
238 | ui.status(_("nothing changed\n")) | |
236 | return 1 |
|
239 | return 1 | |
237 |
|
240 | |||
238 | phases.retractboundary(repo, phases.secret, [node]) |
|
|||
239 |
|
||||
240 | fp = shelvedfile(repo, name, 'files').opener('wb') |
|
241 | fp = shelvedfile(repo, name, 'files').opener('wb') | |
241 | fp.write('\0'.join(shelvedfiles)) |
|
242 | fp.write('\0'.join(shelvedfiles)) | |
242 |
|
243 | |||
@@ -559,10 +560,13 b' def unshelve(ui, repo, *shelved, **opts)' | |||||
559 | if hasmq: |
|
560 | if hasmq: | |
560 | saved, repo.mq.checkapplied = repo.mq.checkapplied, False |
|
561 | saved, repo.mq.checkapplied = repo.mq.checkapplied, False | |
561 |
|
562 | |||
|
563 | backup = repo.ui.backupconfig('phases', 'new-commit') | |||
562 | try: |
|
564 | try: | |
|
565 | repo.ui. setconfig('phases', 'new-commit', phases.secret) | |||
563 | return repo.commit(message, 'shelve@localhost', |
|
566 | return repo.commit(message, 'shelve@localhost', | |
564 | opts.get('date'), match) |
|
567 | opts.get('date'), match) | |
565 | finally: |
|
568 | finally: | |
|
569 | repo.ui.restoreconfig(backup) | |||
566 | if hasmq: |
|
570 | if hasmq: | |
567 | repo.mq.checkapplied = saved |
|
571 | repo.mq.checkapplied = saved | |
568 |
|
572 |
General Comments 0
You need to be logged in to leave comments.
Login now