mirror of
				https://github.com/kewlfft/ansible-aur.git
				synced 2025-11-04 10:02:30 +03:00 
			
		
		
		
	combine auto tests
This commit is contained in:
		@@ -272,18 +272,17 @@ def make_module():
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
    params = module.params
 | 
					    params = module.params
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if params['use'] == 'auto' and params['extra_args'] is not None:
 | 
					    use = params['use']
 | 
				
			||||||
        module.fail_json(msg="'extra_args' option cannot be used with 'auto', a tool must be specified.")
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if params['use'] == 'auto':
 | 
					    if use == 'auto':
 | 
				
			||||||
 | 
					        if params['extra_args'] is not None:
 | 
				
			||||||
 | 
					            module.fail_json(msg="'extra_args' cannot be used with 'auto', a tool must be specified.")
 | 
				
			||||||
        use = 'makepkg'
 | 
					        use = 'makepkg'
 | 
				
			||||||
        # auto: select the first helper for which the bin is found
 | 
					        # auto: select the first helper for which the bin is found
 | 
				
			||||||
        for k in use_cmd:
 | 
					        for k in use_cmd:
 | 
				
			||||||
            if module.get_bin_path(k):
 | 
					            if module.get_bin_path(k):
 | 
				
			||||||
                use = k
 | 
					                use = k
 | 
				
			||||||
                break
 | 
					                break
 | 
				
			||||||
    else:
 | 
					 | 
				
			||||||
        use = params['use']
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if use != 'makepkg' and (params['skip_pgp_check'] or params['ignore_arch']):
 | 
					    if use != 'makepkg' and (params['skip_pgp_check'] or params['ignore_arch']):
 | 
				
			||||||
        module.fail_json(msg="This option is only available with 'makepkg'.")
 | 
					        module.fail_json(msg="This option is only available with 'makepkg'.")
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user