GSoC : Week 2
This week I worked on two patch series:
- environment: remove sparse-checkout related global variables: As I mentioned in the previous patch, I sent a v3 of this patch where I use getters and setters for the settings. But I got this review from Junio where he suggested that since the variable is commonly used. We can instead load it only once in
prepare_repo_settings()
(in the previous version I calledprepare_repo_settings()
everytime in getter and setter function) and just access the member directly afterwards. So, I removed getter/setter functions. And while doing so, I realized the other sparse-checkout-related global variables(core_sparse_checkout_cone
&sparse_expect_files_outside_of_patterns
) could be cleaned up as well. So I made two new patches and sent to the mailing list. This patch series also removes the definition#define USE_THE_REPOSITORY_VARIABLE
from the filesbuiltin/backfill.c
andsparse-index.c
. - preload-index: remove dependency on global variables and ‘the_repository’: This patch eliminates the global variable
core_preload_index
and localize it in the function which calls it. Also, it removes the definition#define USE_THE_REPOSITORY_VARIABLE
from the filepreload-index.c
. Junio said that he will merge this to next.
I hope to get some reviews on the patch I mentioned above and this patch which I sent in the first week.
Next week, I plan to work on refactoring the comment_line_str
global variable, as mentioned in my last blog post. I also hope to identify and clean up more files where the_repository
can be removed.
As for my laptop, I think I’ll have to manage with this small ThinkPad for a while now.
-Ayush:)