Sha256: f1c5285e3e23422fddac5fc14bbdecc0d4441a5a3c3bf67d9b1a2c8c41bd25a2

Contents?: true

Size: 702 Bytes

Versions: 1

Compression:

Stored size: 702 Bytes

Contents

require "blue_printer/version"
require "fileutils"

module BluePrinter
  class Error < StandardError; end

  XCODE_TEMPLATE_PATH = File.join("Library", "Developer", "Xcode", "Templates")
  TEMPLATE_DIR = File.join(File.expand_path('~'), XCODE_TEMPLATE_PATH)
  TEMPLATE_NAME = "Clean Swift VIP.xctemplate"
  TEMPLATE_NAME_TESTS = "Clean Swift Tests.xctemplate"

  def self.root
    File.dirname __dir__
  end

  def self.move_to_xcode_template_directory
    FileUtils.mkdir_p TEMPLATE_DIR
    FileUtils.copy_entry File.join(root, TEMPLATE_NAME), File.join(TEMPLATE_DIR, TEMPLATE_NAME)
    FileUtils.copy_entry File.join(root, TEMPLATE_NAME_TESTS), File.join(TEMPLATE_DIR, TEMPLATE_NAME_TESTS)
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
blue_printer-0.1.5 lib/blue_printer.rb