Class: BetaBuilder::Tasks

Inherits:
Rake::TaskLib
  • Object
show all
Defined in:
lib/beta_builder.rb

Defined Under Namespace

Classes: Configuration

Instance Method Summary collapse

Constructor Details

#initialize(namespace = :beta) {|@configuration| ... } ⇒ Tasks

Returns a new instance of Tasks.

Yields:

  • (@configuration)


10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# File 'lib/beta_builder.rb', line 10

def initialize(namespace = :beta, &block)
  @configuration = Configuration.new(
    :configuration => "Adhoc",
    :build_dir => :derived,
    :auto_archive => false,
    :archive_path  => File.expand_path("~/Library/Developer/Xcode/Archives"),
    :xcodebuild_path => "xcodebuild",
    :project_file_path => nil,
    :workspace_path => nil,
    :scheme => nil,
    :app_name => nil,
    :arch => nil,
    :xcode4_archive_mode => false,
    :skip_clean => false,
    :verbose => false,
    :dry_run => false,
    :use_avgtool => true
  )
  @namespace = namespace
  yield @configuration if block_given?
  define
end

Instance Method Details

#xcodebuild(*args) ⇒ Object



33
34
35
36
# File 'lib/beta_builder.rb', line 33

def xcodebuild(*args)
  # we're using tee as we still want to see our build output on screen
  system("#{@configuration.xcodebuild_path} #{args.join(" ")} | tee build.output")
end