mirror of
				https://github.com/avatao-content/baseimage-tutorial-framework
				synced 2025-11-04 06:22:55 +00:00 
			
		
		
		
	Fix SnapshotProvider failing on taking_snapshot without changes
This commit is contained in:
		@@ -66,10 +66,14 @@ class SnapshotProvider:
 | 
			
		||||
            'git', 'add',
 | 
			
		||||
            '-A'
 | 
			
		||||
        ))
 | 
			
		||||
        self._run((
 | 
			
		||||
            'git', 'commit',
 | 
			
		||||
            '-m', 'Snapshot'
 | 
			
		||||
        ))
 | 
			
		||||
        try:
 | 
			
		||||
            self._get_stdout((
 | 
			
		||||
                'git', 'commit',
 | 
			
		||||
                '-m', 'Snapshot'
 | 
			
		||||
            ))
 | 
			
		||||
        except CalledProcessError as err:
 | 
			
		||||
            if b'nothing to commit, working tree clean' not in err.output:
 | 
			
		||||
                raise
 | 
			
		||||
 | 
			
		||||
    def _check_head_not_detached(self):
 | 
			
		||||
        if self._head_detached:
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user