mirror of
https://github.com/nvbn/thefuck.git
synced 2025-01-31 02:01:13 +00:00
Merge branch 'reitermarkus-patch-1'
This commit is contained in:
commit
ec5b69ca63
@ -280,7 +280,6 @@ Enabled by default only on specific platforms:
|
||||
* `brew_uninstall` – adds `--force` to `brew uninstall` if multiple versions were installed;
|
||||
* `brew_unknown_command` – fixes wrong brew commands, for example `brew docto/brew doctor`;
|
||||
* `brew_update_formula` – turns `brew update <formula>` into `brew upgrade <formula>`;
|
||||
* `brew_upgrade` – appends `--all` to `brew upgrade` as per Homebrew's new behaviour;
|
||||
* `pacman` – installs app with `pacman` if it is not installed (uses `yaourt` if available);
|
||||
* `pacman_not_found` – fixes package name with `pacman` or `yaourt`.
|
||||
|
||||
|
@ -1,15 +0,0 @@
|
||||
import pytest
|
||||
from thefuck.rules.brew_upgrade import match, get_new_command
|
||||
from thefuck.types import Command
|
||||
|
||||
|
||||
@pytest.mark.parametrize('command', [
|
||||
Command('brew upgrade', '')])
|
||||
def test_match(command):
|
||||
assert match(command)
|
||||
|
||||
|
||||
@pytest.mark.parametrize('command, new_command', [
|
||||
(Command('brew upgrade', ''), 'brew upgrade --all')])
|
||||
def test_get_new_command(command, new_command):
|
||||
assert get_new_command(command) == new_command
|
@ -1,17 +0,0 @@
|
||||
# Appends --all to the brew upgrade command
|
||||
#
|
||||
# Example:
|
||||
# > brew upgrade
|
||||
# Warning: brew upgrade with no arguments will change behaviour soon!
|
||||
# It currently upgrades all formula but this will soon change to require '--all'.
|
||||
from thefuck.specific.brew import brew_available
|
||||
|
||||
enabled_by_default = brew_available
|
||||
|
||||
|
||||
def match(command):
|
||||
return command.script == 'brew upgrade'
|
||||
|
||||
|
||||
def get_new_command(command):
|
||||
return command.script + ' --all'
|
Loading…
x
Reference in New Issue
Block a user