Git pipeline is failing due to missing commit in one of submodules. It is not possible to recover that commit because it was lost during hardware crash. How can we make a branch use older version (commit) of submodule, even after we have the newer version in commit history?
            Asked
            
        
        
            Active
            
        
            Viewed 107 times
        
    1
            
            
        - 
                    1Where and how is the submodule linked to the ci ? – CharybdeBE Aug 17 '21 at 08:15
1 Answers
0
            If the submodule is a real submodule registered in .gitmodules then you should do this in a local worktree:
cd <superproject>
git checkout <abranch>
cd <submodule_path>
git checkout <old_commit>
cd <superproject>
git add <submodule_path>
git commit -m "Update submodule"
git push
 
    
    
        phd
        
- 82,685
- 13
- 120
- 165
