summaryrefslogtreecommitdiff
path: root/column.c
diff options
context:
space:
mode:
authorLibravatar Derrick Stolee <dstolee@microsoft.com>2020-09-17 18:11:47 +0000
committerLibravatar Junio C Hamano <gitster@pobox.com>2020-09-17 11:30:05 -0700
commit090511bc0b73bf3054f11df6f275ad3a3abbf34f (patch)
tree66b06389aab543032b7c8b1ec0edaabec196336b /column.c
parentmaintenance: add commit-graph task (diff)
downloadtgif-090511bc0b73bf3054f11df6f275ad3a3abbf34f.tar.xz
maintenance: add --task option
A user may want to only run certain maintenance tasks in a certain order. Add the --task=<task> option, which allows a user to specify an ordered list of tasks to run. These cannot be run multiple times, however. Here is where our array of maintenance_task pointers becomes critical. We can sort the array of pointers based on the task order, but we do not want to move the struct data itself in order to preserve the hashmap references. We use the hashmap to match the --task=<task> arguments into the task struct data. Keep in mind that the 'enabled' member of the maintenance_task struct is a placeholder for a future 'maintenance.<task>.enabled' config option. Thus, we use the 'enabled' member to specify which tasks are run when the user does not specify any --task=<task> arguments. The 'enabled' member should be ignored if --task=<task> appears. Signed-off-by: Derrick Stolee <dstolee@microsoft.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'column.c')
0 files changed, 0 insertions, 0 deletions