Thu, 10 Nov 2016 03:15:41 -0800 shelve: move shelve-finishing logic to a separate function
Kostia Balytskyi <ikostia@fb.com> [Thu, 10 Nov 2016 03:15:41 -0800] rev 30385
shelve: move shelve-finishing logic to a separate function With future obs-based shelve, finishing shelve will be different from just aborting a transaction and I would like to keep both variants of this functionality in a separate function.
Thu, 10 Nov 2016 03:20:28 -0800 shelve: move unknown files handling to a separate function
Kostia Balytskyi <ikostia@fb.com> [Thu, 10 Nov 2016 03:20:28 -0800] rev 30384
shelve: move unknown files handling to a separate function This change has nothing to do with future obsshelve introduction, it is done just for readability purposes.
Thu, 10 Nov 2016 03:07:20 -0800 shelve: move actual created commit shelving to a separate function
Kostia Balytskyi <ikostia@fb.com> [Thu, 10 Nov 2016 03:07:20 -0800] rev 30383
shelve: move actual created commit shelving to a separate function Currently, this code does not have any branching, it just bundles a commit and saves a patch file. Later, obsolescence-based shelve will be added, so this code will also create some obsmarkers and will be one of the few places where obsshelve will be different from traditional shelve.
Thu, 10 Nov 2016 03:33:01 -0800 shelve: move 'nothing changed' messaging to a separate function
Kostia Balytskyi <ikostia@fb.com> [Thu, 10 Nov 2016 03:33:01 -0800] rev 30382
shelve: move 'nothing changed' messaging to a separate function This has nothing to do with the future obsshelve implementation, I just thought that moving this messaging to a separate function will improve shelve code readability.
Thu, 10 Nov 2016 03:26:31 -0800 shelve: move commitfunc creation to a separate function
Kostia Balytskyi <ikostia@fb.com> [Thu, 10 Nov 2016 03:26:31 -0800] rev 30381
shelve: move commitfunc creation to a separate function Special commitfuncs are created as closures at least twice in shelve's code and one time special commitfunc is used within another closure. They all serve very specific purposes like temporarily tweak some configuration or enable editor, etc. This is not immediately important to someone reading shelve code, so I think moving this logic to a separate function is a good idea.
Thu, 10 Nov 2016 03:24:07 -0800 shelve: move mutableancestors to not be a closure
Kostia Balytskyi <ikostia@fb.com> [Thu, 10 Nov 2016 03:24:07 -0800] rev 30380
shelve: move mutableancestors to not be a closure There's no value in it being a closure and everyone who tries to read the outer function code will be distracted by it. IMO moving it out significantly improves readability, especially given how clear it is what mutableancestors function does from its name.
Thu, 10 Nov 2016 03:22:55 -0800 shelve: move shelve name generation to a separate function
Kostia Balytskyi <ikostia@fb.com> [Thu, 10 Nov 2016 03:22:55 -0800] rev 30379
shelve: move shelve name generation to a separate function This has nothing to do with future obsshelve introduction, done just for readability purposes.
Thu, 10 Nov 2016 03:07:20 -0800 shelve: move possible shelve file extensions to a single place
Kostia Balytskyi <ikostia@fb.com> [Thu, 10 Nov 2016 03:07:20 -0800] rev 30378
shelve: move possible shelve file extensions to a single place This and a couple of following patches are a preparation to implementing obsolescense-enabled shelve which was discussed on a Sprint. If this refactoring is not done, shelve is going to look even more hackish than now. This particular commit introduces a slight behavior change. Previously, if only .hg/shelve/name.patch file exists, but .hg/name.hg does not, 'hg shelve -d name' would fail saying "shelve not found". Now deletion will only fail if .patch file does not exist (since .patch is used as an indicator of an existing shelve). Other shelve files being absent are skipped silently to accommodate for future introduction of obs-based shelve, which will mean that for some shelves .hg and .patch files exist, while for others .hg and .oshelve.
Thu, 10 Nov 2016 02:13:19 -0800 manifest: delete manifest.manifest class
Durham Goode <durham@fb.com> [Thu, 10 Nov 2016 02:13:19 -0800] rev 30377
manifest: delete manifest.manifest class Now that nothing uses the primary manifest class, we can delete it.
Thu, 10 Nov 2016 02:13:19 -0800 localrepo: delete localrepo.manifest
Durham Goode <durham@fb.com> [Thu, 10 Nov 2016 02:13:19 -0800] rev 30376
localrepo: delete localrepo.manifest Now that nothing uses normal manifests, we can delete localrepo.manifest.
(0) -30000 -10000 -3000 -1000 -300 -100 -10 +10 +100 +300 +1000 +3000 +10000 tip