Sha256: 56ee1910e9d8080b31ea80f9af35d4e2ca6ac3b3cf9a700d28f7103d38dfc665

Contents?: true

Size: 428 Bytes

Versions: 6

Compression:

Stored size: 428 Bytes

Contents

# frozen_string_literal: true

module Capistrano
  module DataPlaneApi
    class Configuration < Type
      class Server < Type
        attribute :name, ::Shale::Type::String
        attribute :stage, ::Shale::Type::String

        # @return [String, nil]
        def stage
          @stage || @name
        end

        # @return [String, nil]
        def name
          @name || @stage
        end
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
capistrano-data_plane_api-0.1.5 lib/capistrano/data_plane_api/configuration/server.rb
capistrano-data_plane_api-0.1.4 lib/capistrano/data_plane_api/configuration/server.rb
capistrano-data_plane_api-0.1.3 lib/capistrano/data_plane_api/configuration/server.rb
capistrano-data_plane_api-0.1.2 lib/capistrano/data_plane_api/configuration/server.rb
capistrano-data_plane_api-0.1.1 lib/capistrano/data_plane_api/configuration/server.rb
capistrano-data_plane_api-0.1.0 lib/capistrano/data_plane_api/configuration/server.rb