Sha256: 1828c47f8bcdd084c9d7bafb4faf66f4e65bb5d2f20af6c59543b22bc94e2448
Contents?: true
Size: 471 Bytes
Versions: 15
Compression:
Stored size: 471 Bytes
Contents
# frozen_string_literal: true module Dsu class << self def env @env ||= Struct.new(:env) do def test? env.fetch('DSU_ENV', nil) == 'test' end def development? env.fetch('DSU_ENV', nil) == 'development' end def local? test? || development? end def production? env.fetch('DSU_ENV', 'production') == 'production' end end.new(ENV) end end end
Version data entries
15 entries across 15 versions & 1 rubygems