Tweak regex used to determine PHP version
This commit is contained in:
		
							parent
							
								
									a77b1ec100
								
							
						
					
					
						commit
						ab822411be
					
				
					 1 changed files with 1 additions and 1 deletions
				
			
		| 
						 | 
					@ -73,7 +73,7 @@ def get_php_version(c):
 | 
				
			||||||
    """
 | 
					    """
 | 
				
			||||||
    result = c.sudo('php --version')
 | 
					    result = c.sudo('php --version')
 | 
				
			||||||
    if not result.failed:
 | 
					    if not result.failed:
 | 
				
			||||||
        match = re.match(r'^PHP (\d+\.\d+)\.\d+-', result.stdout)
 | 
					        match = re.match(r'^PHP (\d+\.\d+)\.\d+', result.stdout)
 | 
				
			||||||
        if match:
 | 
					        if match:
 | 
				
			||||||
            return float(match.group(1))
 | 
					            return float(match.group(1))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue