Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions apps/server/src/provider/providerMaintenance.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -332,6 +332,21 @@ it.layer(NodeServices.layer)("providerMaintenance", (it) => {
});
});

it("does not treat an Ubuntu /usr/local/bin executable as Homebrew-managed", () => {
expect(
packageToolUpdate.resolve({
binaryPath: "/usr/local/bin/package-tool",
env: {
PATH: "",
},
}),
).toEqual({
provider: driver("packageTool"),
packageName: "@example/package-tool",
update: null,
});
});

it.effect(
"switches native-package-tool to native updates when the binary resolves through the native installer",
() =>
Expand Down
3 changes: 1 addition & 2 deletions apps/server/src/provider/providerMaintenance.ts
Original file line number Diff line number Diff line change
Expand Up @@ -268,8 +268,7 @@ function isHomebrewCommandPath(commandPath: string): boolean {
normalized.includes("/opt/homebrew/caskroom/") ||
normalized.includes("/usr/local/caskroom/") ||
normalized.includes("/homebrew/caskroom/") ||
normalized.startsWith("/opt/homebrew/bin/") ||
normalized.startsWith("/usr/local/bin/")
normalized.startsWith("/opt/homebrew/bin/")
);
}

Expand Down
Loading