25 lines
566 B
Ruby
Raw Normal View History

2020-10-10 14:16:11 +02:00
# typed: strict
# frozen_string_literal: true
module Utils
module Analytics
class << self
2020-10-28 18:49:10 +11:00
extend T::Sig
sig { params(verbose: T::Boolean).returns(String) }
def custom_prefix_label(verbose: false)
return generic_custom_prefix_label(verbose: verbose) if Hardware::CPU.arm?
"non-/usr/local"
end
sig { params(verbose: T::Boolean).returns(String) }
def arch_label(verbose: false)
return "Rosetta" if Hardware::CPU.in_rosetta2?
generic_arch_label(verbose: verbose)
end
end
end
end