mirror of
				https://github.com/nvbn/thefuck.git
				synced 2025-11-04 09:02:08 +00:00 
			
		
		
		
	@@ -189,6 +189,7 @@ using the matched rule and runs it. Rules enabled by default are as follows:
 | 
				
			|||||||
* `sudo` – prepends `sudo` to previous command if it failed because of permissions;
 | 
					* `sudo` – prepends `sudo` to previous command if it failed because of permissions;
 | 
				
			||||||
* `switch_layout` – switches command from your local layout to en;
 | 
					* `switch_layout` – switches command from your local layout to en;
 | 
				
			||||||
* `systemctl` – correctly orders parameters of confusing systemctl;
 | 
					* `systemctl` – correctly orders parameters of confusing systemctl;
 | 
				
			||||||
 | 
					* `test.py` &ndasg; runs `py.test` instead of `test.py`;
 | 
				
			||||||
* `whois` – fixes `whois` command.
 | 
					* `whois` – fixes `whois` command.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Enabled by default only on specific platforms:
 | 
					Enabled by default only on specific platforms:
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										10
									
								
								thefuck/rules/test.py.py
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										10
									
								
								thefuck/rules/test.py.py
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,10 @@
 | 
				
			|||||||
 | 
					def match(command, settings):
 | 
				
			||||||
 | 
					    return command.script == 'test.py' and 'not found' in command.stderr
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					def get_new_command(command, settings):
 | 
				
			||||||
 | 
					    return 'py.test'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# make it come before the python_command rule
 | 
				
			||||||
 | 
					priority = 900
 | 
				
			||||||
		Reference in New Issue
	
	Block a user