Class: Avm::Launcher::Instances::Settings

Inherits:
Object
  • Object
show all
Defined in:
lib/avm/launcher/instances/settings.rb

Constant Summary collapse

DEFAULT_CURRENT_REVISION =
'origin/master'
DEFAULT_PUBLISH_REMOTE =
'publish'
PUBLISHABLE_KEY =
:publishable

Instance Method Summary collapse

Instance Method Details

#git_current_revisionObject



17
18
19
# File 'lib/avm/launcher/instances/settings.rb', line 17

def git_current_revision
  data[__method__] || DEFAULT_CURRENT_REVISION
end

#git_publish_remoteObject



21
22
23
# File 'lib/avm/launcher/instances/settings.rb', line 21

def git_publish_remote
  data[__method__] || DEFAULT_PUBLISH_REMOTE
end

#publishable?Boolean

Returns:

  • (Boolean)


25
26
27
# File 'lib/avm/launcher/instances/settings.rb', line 25

def publishable?
  !!publishable_value
end

#stereotype_publishable?(stereotype) ⇒ Boolean

Returns:

  • (Boolean)


29
30
31
32
33
# File 'lib/avm/launcher/instances/settings.rb', line 29

def stereotype_publishable?(stereotype)
  return publishable? unless publishable_value.is_a?(::Hash)

  parse_publishable_value(publishable_value[stereotype.stereotype_name], true)
end