dotfiles icon indicating copy to clipboard operation
dotfiles copied to clipboard

brew install got Invalid option error

Open hazz1925 opened this issue 7 years ago • 8 comments

What I did: git pull and rake update

Error found:

[Running] brew install macvim --with-override-system-vim --with-lua --with-luajit
Usage: brew install [options] formula

Install formula.

formula is usually the name of the formula to install, but it can be specified
in several different ways.

Unless HOMEBREW_NO_INSTALL_CLEANUP is set, brew cleanup will be run for the installed formulae or, every 30 days, for all formulae.

    -d, --debug                      If brewing fails, open an interactive
                                     debugging session with access to IRB or a
                                     shell inside the temporary build directory
        --env                        If std is passed, use the standard build
                                     environment instead of superenv.If super
                                     is passed, use superenv even if the formula
                                     specifies the standard build environment.
        --ignore-dependencies        Skip installing any dependencies of any
                                     kind. If they are not already present, the
                                     formula will probably fail to install.
        --only-dependencies          Install the dependencies with specified
                                     options but do not install the specified
                                     formula.
        --cc                         Attempt to compile using provided
                                     compiler. compiler should be the name
                                     of the compiler's executable, for instance
                                     gcc-7 for GCC 7. In order to use LLVM's
                                     clang, use llvm_clang. To specify the
                                     Apple-provided clang, use clang. This
                                     parameter will only accept compilers that
                                     are provided by Homebrew or bundled with
                                     macOS. Please do not file issues if you
                                     encounter errors while using this flag.
    -s, --build-from-source          Compile the specified formula from source
                                     even if a bottle is provided. Dependencies
                                     will still be installed from bottles if
                                     they are available.
        --force-bottle               Install from a bottle if it exists for the
                                     current or newest version of macOS, even if
                                     it would not normally be used for
                                     installation.
        --include-test               Install testing dependencies required to
                                     run brew test.
        --devel                      If formula defines it, install the
                                     development version.
        --HEAD                       If formula defines it, install the HEAD
                                     version, aka. master, trunk, unstable.
        --fetch-HEAD                 Fetch the upstream repository to detect if
                                     the HEAD installation of the formula is
                                     outdated. Otherwise, the repository's HEAD
                                     will be checked for updates when a new
                                     stable or development version has been
                                     released.
        --keep-tmp                   Don't delete the temporary files created
                                     during installation.
        --build-bottle               Prepare the formula for eventual bottling
                                     during installation.
        --bottle-arch=               Optimise bottles for the given architecture
                                     rather than the oldest architecture
                                     supported by the version of macOS the
                                     bottles are built on.
    -f, --force                      Install without checking for previously
                                     installed keg-only or non-migrated
                                     versions.
    -v, --verbose                    Print the verification and postinstall
                                     steps.
        --display-times              Print install times for each formula at the
                                     end of the run.
    -i, --interactive                Download and patch formula, then open a
                                     shell. This allows the user to run
                                     ./configure --help and otherwise
                                     determine how to turn the software package
                                     into a Homebrew package.
    -g, --git                        Create a Git repository, useful for
                                     creating patches to the software.
    -h, --help                       Show this message.
Error: invalid option: --with-override-system-vim

hazz1925 avatar Mar 16 '19 09:03 hazz1925

Could you solve this? Maybe with recent versions of brew and/or macvim one of those options got deprecated or renamed... Feel free to send a PR fixing it (nowadays I mainly use my own fork, with neovim, so I don't have much time to invest in this repo anymore...)

lfilho avatar Apr 27 '19 22:04 lfilho

Install options have been removed from homebrew. Which is really annoying. https://github.com/Homebrew/homebrew-core/issues/31510

fizz avatar May 17 '19 01:05 fizz

just like brew install macvim -- --with-override-system-vim --with-lua --with-luajit add --

GuyZhangZhang avatar May 29 '19 09:05 GuyZhangZhang

I solve it by installing macvim through macvim's brew tap. Here is my PR https://github.com/skwp/dotfiles/pull/822

hazz1925 avatar May 29 '19 15:05 hazz1925

just like brew install macvim -- --with-override-system-vim --with-lua --with-luajit add --

it works, so strange

achillesss avatar Jul 08 '19 03:07 achillesss

The error only happens when you update your brew to the latest version since the latest version of brew does not allow install options anymore.

Install options have been removed from homebrew. Which is really annoying. Homebrew/homebrew-core#31510

hazz1925 avatar Jul 08 '19 03:07 hazz1925

@achillesss @GuyCheung when you say "it works" have you confirmed the install options actually do what they are expected to do? Maybe is just not erring out, but also not working as intended... Can you confirm for example:

  1. system vim was actually overridem with brew's one?
  2. installed vim has lua support
  3. installed vim has luajit support

as expected?

lfilho avatar Jul 13 '19 16:07 lfilho

Closing as per last PR merged, fixing brew formula.

lfilho avatar Aug 17 '19 20:08 lfilho