mirror of
				https://github.com/luc-github/ESP3D.git
				synced 2025-10-24 11:50:52 -07:00 
			
		
		
		
	
		
			
				
	
	
		
			20 lines
		
	
	
		
			296 B
		
	
	
	
		
			Bash
		
	
	
	
	
	
			
		
		
	
	
			20 lines
		
	
	
		
			296 B
		
	
	
	
		
			Bash
		
	
	
	
	
	
| #!/bin/bash
 | |
| 
 | |
| function build_sketch()
 | |
| {
 | |
| 	local sketch=$1
 | |
| 
 | |
| 	# buld sketch with arudino ide
 | |
| 	echo -e "\n Build $sketch \n"
 | |
| 	arduino --verbose --verify $sketch
 | |
| 
 | |
| 	# get build result from arduino
 | |
| 	local re=$?
 | |
| 
 | |
| 	# check result
 | |
| 	if [ $re -ne 0 ]; then
 | |
| 		echo "Failed to build $sketch"
 | |
| 		return $re
 | |
| 	fi
 | |
| }
 |