do not fail if code is missing, but inform
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
This commit is contained in:
		
					parent
					
						
							
								35d4760c13
							
						
					
				
			
			
				commit
				
					
						838d43d74c
					
				
			
		
					 1 changed files with 2 additions and 2 deletions
				
			
		| 
						 | 
				
			
			@ -29,7 +29,7 @@ __cdist_object="$1"; shift
 | 
			
		|||
__cdist_code_type="$1"; shift
 | 
			
		||||
 | 
			
		||||
if [ ! -d "$(__cdist_object_dir "$__cdist_object")" ]; then
 | 
			
		||||
   __cdist_exit_err "Object $__cdist_object is missing."
 | 
			
		||||
   __cdist_exit_err "Object undefined"
 | 
			
		||||
fi  
 | 
			
		||||
 | 
			
		||||
code="$(__cdist_object_code "$__cdist_object")-${__cdist_code_type}"
 | 
			
		||||
| 
						 | 
				
			
			@ -48,5 +48,5 @@ if [ -e "$code" ]; then
 | 
			
		|||
      __cdist_exit_err "$code exists, but is not a file."
 | 
			
		||||
   fi
 | 
			
		||||
else
 | 
			
		||||
   __cdist_exit_err "Missing code for ${__cdist_object}."
 | 
			
		||||
   __cdist_echo info "No code-${__cdist_code_type}"
 | 
			
		||||
fi
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue