mirror of
				https://github.com/AdnanHodzic/auto-cpufreq.git
				synced 2025-11-03 21:26:16 +01:00 
			
		
		
		
	Check if lsb_release exists before using it (#302)
This commit is contained in:
		
							parent
							
								
									4c5681b2d8
								
							
						
					
					
						commit
						4d30f771e2
					
				@ -7,9 +7,14 @@ SCRIPT_PATH=$(readlink -f "$0")
 | 
			
		||||
SCRIPT_DIR=$(dirname "${SCRIPT_PATH}")
 | 
			
		||||
cd "${SCRIPT_DIR}"
 | 
			
		||||
 | 
			
		||||
# check if lsb_release exists on the system before using it
 | 
			
		||||
if command -v lsb_release > /dev/null
 | 
			
		||||
then
 | 
			
		||||
  distro="$(lsb_release -is)"
 | 
			
		||||
  release="$(lsb_release -rs)"
 | 
			
		||||
  codename="$(lsb_release -cs)"
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
sep="\n-------------------------------------------------------------------------------"
 | 
			
		||||
 | 
			
		||||
# functions
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user