Sha256: 9717f9b1c8217a3bd1864b53e5bd970ece87df531ac97221674530a421518c4d
Contents?: true
Size: 664 Bytes
Versions: 2
Compression:
Stored size: 664 Bytes
Contents
# Wrap project in object to allow lazy loading of status class Cody::List class Project include Cody::AwsServices extend Memoist delegate :build_status, :start_time, :end_time, to: :build attr_reader :name def initialize(name) @name = name # Simple string end def build resp = codebuild.batch_get_builds(ids: [build_id]) resp.builds.first # most recent build end memoize :build alias_method :load, :build # interface to eager load def build_id resp = codebuild.list_builds_for_project(project_name: @name) resp.ids.first # most recent build_id end memoize :build_id end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
cody-0.9.5 | lib/cody/list/project.rb |
cody-0.9.4 | lib/cody/list/project.rb |