hooks icon indicating copy to clipboard operation
hooks copied to clipboard

Prefer tools.is_apple_os instead of settings.os check

Open prince-chrismc opened this issue 5 years ago • 3 comments

        if tools.is_apple_os(self.settings.os):

Originally posted by @madebr in https://github.com/conan-io/conan-center-index/pull/3623#discussion_r531101411

prince-chrismc avatar Nov 26 '20 17:11 prince-chrismc

I think the hooks have no way to post recommendations yet and I think that there are valid cases to only check of macOS but not iOS and the rest. Hence, I don't think we can write a hook for that right now.

In general, I think there can be many things where recommendations / hints / warnings would be great for hooks.

Croydon avatar Nov 26 '20 17:11 Croydon

Agree, while many self.settings.os == "Macos" should be replaced by tools.is_apple_os(self.settings.os), there is no simple rule.

SpaceIm avatar Apr 29 '21 14:04 SpaceIm

Recently I discovered, some hooks are warnings, perhaps this might be a suggestive warning?

prince-chrismc avatar Apr 29 '21 16:04 prince-chrismc