class GoNative::Plugins::IOS::Publish

Public Instance Methods

assert_staging_clear!() click to toggle source
# File lib/gonative/plugins/ios/publish.rb, line 23
def assert_staging_clear!
  return if `git status --porcelain`.empty?

  raise Error, "There are uncommitted changes in the repository"
end
assert_valid_plugin!() click to toggle source
# File lib/gonative/plugins/ios/publish.rb, line 17
def assert_valid_plugin!
  return if File.file?('create-framework.sh')
  
  raise Error, "File 'create-framework.sh' does not exist. Please make sure this is a valid GoNative plugin directory"
end
build_framework!() click to toggle source
# File lib/gonative/plugins/ios/publish.rb, line 29
def build_framework!
  Utils::UI.info 'Building framework'
  return if system('sh create-framework.sh >/dev/null 2>/dev/null')
  
  raise Error, "Error building framework. Please run the create-framework file manually to fix any errors"
end
call() click to toggle source
# File lib/gonative/plugins/ios/publish.rb, line 10
def call
  assert_valid_plugin!
  assert_staging_clear!
  build_framework!
  release_pod!
end