Change git Index use shared Ptr