First two weeks of the coding period went well and I had sent a patch on the first prototype of the functionality that I have coded up. I had only used the usual mergestate format for that. Starting from week 3, I worked on storing mergestate records in the changeset extras so that it can be exchanged to other repositories. I updated the patch that I had sent here[1]. Also, the patch[2] which added documentation on internals.mergestate
got merged too.
The mergestate record information is stored as a list of tuples and I had to store it in the extra mapping mergerecords
. I had to write an encoder and decorder for this as the information from the extra mapping can only be parsed as a string. I have used the following code for the encoder and decoder.
The read/write operations that can be performed on mergestate information were already implemented on merge.py
. So, I used that right away. You can find the complete code for the functionality with documentation here[3].
The next week, I got some interesting ideas from my mentor outside the project sample space. I worked on moving shelve extension to core and sent a patch[4] for that. I am looking forward to work on extending the functionality to store/restore mergestate to multi-step commands like rebase
and histedit
, exchanging shelves and moving show extension to core.