File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -149,13 +149,16 @@ def cli_path(self):
149149 logger .debug (f"{ self .cli_name } CLI not found." )
150150 return
151151
152- # Normalize CLI path and check it is a file.
153- cli_path = Path (cli_path ).resolve (strict = True )
154- logger .debug (f"CLI found at { cli_path } " )
155-
156- if not cli_path .is_file ():
152+ # Check if path exist and is a file.
153+ # Do not resolve symlink here. Some manager like Homebrew on Linux rely on some
154+ # sort of synlink trickery to set environment variables.
155+ cli_path = Path (cli_path )
156+ if not cli_path .exists ():
157+ raise FileNotFoundError (f"{ cli_path } " )
158+ elif not cli_path .is_file ():
157159 logger .warning (f"{ cli_path } is not a file." )
158- return
160+ else :
161+ logger .debug (f"CLI found at { cli_path } " )
159162
160163 return cli_path
161164
Original file line number Diff line number Diff line change @@ -43,9 +43,6 @@ class Homebrew(PackageManager):
4343 # 2.7.0 is the first release to enforce the use of --cask option.
4444 requirement = "2.7.0"
4545
46- # Help mpm a little bit in its search for the `brew` binary on Linux.
47- cli_search_path = ["~/.linuxbrew" ]
48-
4946 # Declare this manager as virtual, i.e. not tied to a real CLI.
5047 cli_name = None
5148
You can’t perform that action at this time.
0 commit comments