tug 0.2.2 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 6f3fb8d373e828eeb29fd2336e21876f2dd3231d
4
- data.tar.gz: 58dbb84525181422c8ce41e770870cbaa72d050b
3
+ metadata.gz: 70f71a202e5d6b95e088e3a789e655fded4a3bec
4
+ data.tar.gz: a9352a94603727ac51b126149e26d2deaae3ac3a
5
5
  SHA512:
6
- metadata.gz: e3475d85ed439d3db2287cebc875dc7e32249fd1334fb722fd965f7c4d9d043f91312275e46d33ce04378ba4010e042b6404338d5e084a4f68158024d6abbd9c
7
- data.tar.gz: 5ddcced1b6bbe45377f0e40ebd4eef3f1941fdb9a589bec5088145fbbd7013dd05e49cae386b287bb6b8952fde25ccd17d9ddc0fc32d09b736d684e08455f583
6
+ metadata.gz: e45442dd1bfdf87d914f0b049c2b9ab82ba569edcaf3f3e4b983356660610ccdf4225a0698e2d73f7d50ed554da7e4da232d80de01264dbeb118bb316f077a92
7
+ data.tar.gz: 9bafc986a4b997aa3cac4ced243b677d09045e9b58856fb22c368602320304b4d6c7f433f147ab89d9012e65f6f8e28ece7f9732f9881291916155e1e2ef2897
@@ -0,0 +1 @@
1
+ 2.3.1
@@ -1,67 +1,72 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- tug (0.2.1)
4
+ tug (0.2.2)
5
5
  thor
6
6
 
7
7
  GEM
8
8
  remote: https://rubygems.org/
9
9
  specs:
10
- celluloid (0.16.0)
11
- timers (~> 4.0.0)
12
- codeclimate-test-reporter (0.4.5)
10
+ codeclimate-test-reporter (0.4.8)
13
11
  simplecov (>= 0.7.1, < 1.0.0)
14
12
  coderay (1.1.0)
15
13
  diff-lcs (1.2.5)
16
14
  docile (1.1.5)
17
- ffi (1.9.3)
15
+ ffi (1.9.10)
18
16
  formatador (0.2.5)
19
- guard (2.6.1)
17
+ guard (2.13.0)
20
18
  formatador (>= 0.2.4)
21
- listen (~> 2.7)
19
+ listen (>= 2.7, <= 4.0)
22
20
  lumberjack (~> 1.0)
21
+ nenv (~> 0.1)
22
+ notiffany (~> 0.0)
23
23
  pry (>= 0.9.12)
24
+ shellany (~> 0.0)
24
25
  thor (>= 0.18.1)
25
- guard-rspec (4.3.1)
26
+ guard-compat (1.2.1)
27
+ guard-rspec (4.6.4)
26
28
  guard (~> 2.1)
27
- rspec (>= 2.14, < 4.0)
28
- hitimes (1.2.2)
29
- listen (2.7.9)
30
- celluloid (>= 0.15.2)
29
+ guard-compat (~> 1.1)
30
+ rspec (>= 2.99.0, < 4.0)
31
+ json (1.8.3)
32
+ listen (3.0.3)
31
33
  rb-fsevent (>= 0.9.3)
32
34
  rb-inotify (>= 0.9)
33
35
  lumberjack (1.0.9)
34
36
  method_source (0.8.2)
35
- multi_json (1.10.1)
37
+ nenv (0.2.0)
38
+ notiffany (0.0.7)
39
+ nenv (~> 0.1)
40
+ shellany (~> 0.0)
36
41
  pry (0.10.1)
37
42
  coderay (~> 1.1.0)
38
43
  method_source (~> 0.8.1)
39
44
  slop (~> 3.4)
40
- rake (10.3.2)
41
- rb-fsevent (0.9.4)
45
+ rake (10.4.2)
46
+ rb-fsevent (0.9.6)
42
47
  rb-inotify (0.9.5)
43
48
  ffi (>= 0.5.0)
44
- rspec (3.1.0)
45
- rspec-core (~> 3.1.0)
46
- rspec-expectations (~> 3.1.0)
47
- rspec-mocks (~> 3.1.0)
48
- rspec-core (3.1.0)
49
- rspec-support (~> 3.1.0)
50
- rspec-expectations (3.1.0)
49
+ rspec (3.3.0)
50
+ rspec-core (~> 3.3.0)
51
+ rspec-expectations (~> 3.3.0)
52
+ rspec-mocks (~> 3.3.0)
53
+ rspec-core (3.3.2)
54
+ rspec-support (~> 3.3.0)
55
+ rspec-expectations (3.3.1)
51
56
  diff-lcs (>= 1.2.0, < 2.0)
52
- rspec-support (~> 3.1.0)
53
- rspec-mocks (3.1.0)
54
- rspec-support (~> 3.1.0)
55
- rspec-support (3.1.0)
56
- simplecov (0.9.1)
57
+ rspec-support (~> 3.3.0)
58
+ rspec-mocks (3.3.2)
59
+ diff-lcs (>= 1.2.0, < 2.0)
60
+ rspec-support (~> 3.3.0)
61
+ rspec-support (3.3.0)
62
+ shellany (0.0.1)
63
+ simplecov (0.10.0)
57
64
  docile (~> 1.1.0)
58
- multi_json (~> 1.0)
59
- simplecov-html (~> 0.8.0)
60
- simplecov-html (0.8.0)
65
+ json (~> 1.8)
66
+ simplecov-html (~> 0.10.0)
67
+ simplecov-html (0.10.0)
61
68
  slop (3.6.0)
62
69
  thor (0.19.1)
63
- timers (4.0.0)
64
- hitimes
65
70
 
66
71
  PLATFORMS
67
72
  ruby
@@ -73,3 +78,6 @@ DEPENDENCIES
73
78
  rake
74
79
  rspec
75
80
  tug!
81
+
82
+ BUNDLED WITH
83
+ 1.10.5
data/lib/tug.rb CHANGED
@@ -20,10 +20,10 @@ require "tug/config/missing_config_file"
20
20
 
21
21
  require "tug/project/project"
22
22
 
23
- require "tug/tool/xcode_build"
24
- require "tug/tool/xctool"
25
- require "tug/tool/xctool_build"
26
- require "tug/tool/xctool_archive"
23
+ require "tug/tool/buildtool"
24
+ require "tug/tool/buildtool_archive"
25
+ require "tug/tool/buildtool_build"
26
+ require "tug/tool/buildtool_export"
27
27
 
28
28
  require "tug/keychain/keychain"
29
29
 
@@ -3,8 +3,8 @@ module Tug
3
3
 
4
4
  private
5
5
 
6
- def xctool(config)
7
- xctool = Tug::XCTool.tool_for_config("Debug")
6
+ def build_tool(config)
7
+ build_tool = Tug::BuildTool.tool_for_config("Debug")
8
8
  end
9
9
  end
10
- end
10
+ end
@@ -20,16 +20,16 @@ module Tug
20
20
 
21
21
  def execute(config_file)
22
22
  project = config_file.project
23
- @xctool = xctool(project.ipa_config)
23
+ @build_tool = build_tool(project.ipa_config)
24
24
  project.schemes.each do |scheme|
25
- @xctool.build(project.workspace, scheme)
25
+ @build_tool.build(project.workspace, scheme)
26
26
  end
27
27
  end
28
28
 
29
29
  private
30
30
 
31
- def xctool(config)
32
- xctool = Tug::XCTool.tool_for_config(config)
31
+ def build_tool(config)
32
+ build_tool = Tug::BuildTool.tool_for_config(config)
33
33
  end
34
34
  end
35
- end
35
+ end
@@ -11,9 +11,9 @@ module Tug
11
11
  private
12
12
 
13
13
  def export_ipa(project)
14
- xcodebuild = Tug::XcodeBuild.new
14
+ build_tool_export = Tug::BuildToolExport.new
15
15
  project.schemes.each do |scheme|
16
- xcodebuild.export_ipa(scheme)
16
+ build_tool_export.export_ipa(scheme)
17
17
  end
18
18
  end
19
19
 
@@ -25,8 +25,8 @@ module Tug
25
25
 
26
26
  def zip_and_move_dsym(project)
27
27
  project.schemes.each do |scheme|
28
- zipfile = zip_file "/tmp/#{scheme}.xcarchive/dSYMs", "#{scheme}.app.dSYM"
29
- FileUtils.mv zipfile, "#{project.ipa_export_path}/#{scheme}.app.dSYM.zip"
28
+ zipfile = zip_file "/tmp/#{scheme}.xcarchive/dSYMs", "#{scheme}.app.dSYM"
29
+ FileUtils.mv zipfile, "#{project.ipa_export_path}/#{scheme}.app.dSYM.zip"
30
30
  end
31
31
  end
32
32
 
@@ -37,4 +37,4 @@ module Tug
37
37
  return folder + "/" + file + ".zip"
38
38
  end
39
39
  end
40
- end
40
+ end
@@ -1,5 +1,5 @@
1
1
  module Tug
2
- class XCTool
2
+ class BuildTool
3
3
 
4
4
  attr_reader :config
5
5
 
@@ -7,9 +7,9 @@ module Tug
7
7
  def tool_for_config(config)
8
8
  case config.downcase
9
9
  when "inhouse", "release", /release/, /inhouse/
10
- Tug::XCToolArchive.new(config)
10
+ Tug::BuildToolArchive.new(config)
11
11
  else
12
- Tug::XCToolBuild.new(config)
12
+ Tug::BuildToolBuild.new(config)
13
13
  end
14
14
  end
15
15
  end
@@ -19,7 +19,7 @@ module Tug
19
19
  end
20
20
 
21
21
  def build(workspace, scheme)
22
- system("xctool #{build_options(workspace, scheme)}")
22
+ system("xcodebuild #{build_options(workspace, scheme)}")
23
23
  end
24
24
 
25
25
  private
@@ -28,4 +28,4 @@ module Tug
28
28
  "-workspace #{workspace} -scheme #{scheme} -configuration #{config}"
29
29
  end
30
30
  end
31
- end
31
+ end
@@ -1,5 +1,5 @@
1
1
  module Tug
2
- class XCToolArchive < XCTool
2
+ class BuildToolArchive < BuildTool
3
3
 
4
4
  private
5
5
 
@@ -7,4 +7,4 @@ module Tug
7
7
  super + " archive -archivePath /tmp/#{scheme}.xcarchive"
8
8
  end
9
9
  end
10
- end
10
+ end
@@ -1,5 +1,5 @@
1
1
  module Tug
2
- class XCToolBuild < XCTool
2
+ class BuildToolBuild < BuildTool
3
3
 
4
4
  private
5
5
 
@@ -7,4 +7,4 @@ module Tug
7
7
  super + " -sdk iphonesimulator"
8
8
  end
9
9
  end
10
- end
10
+ end
@@ -1,5 +1,5 @@
1
1
  module Tug
2
- class XcodeBuild
2
+ class BuildToolExport
3
3
 
4
4
  def export_ipa(name)
5
5
  system("xcodebuild #{archive_options(name)} #{export_options(name)} #{profile_options}")
@@ -19,4 +19,4 @@ module Tug
19
19
  "-archivePath /tmp/#{name}.xcarchive"
20
20
  end
21
21
  end
22
- end
22
+ end
@@ -1,3 +1,3 @@
1
1
  module Tug
2
- VERSION = "0.2.2"
2
+ VERSION = "0.3.0"
3
3
  end
@@ -13,9 +13,9 @@ describe Tug::BuildCommand do
13
13
  allow(@config).to receive(:project).and_return(@project)
14
14
  end
15
15
 
16
- it "should build using xctool" do
17
- expect_any_instance_of(Tug::XCTool).to receive(:system).with("xctool -workspace workspace -scheme scheme -configuration Debug -sdk iphonesimulator")
16
+ it "should build using xcodebuild" do
17
+ expect_any_instance_of(Tug::BuildTool).to receive(:system).with("xcodebuild -workspace workspace -scheme scheme -configuration Debug -sdk iphonesimulator")
18
18
  @command.execute(@config)
19
19
  end
20
20
  end
21
- end
21
+ end
@@ -0,0 +1,25 @@
1
+ require 'spec_helper'
2
+
3
+ describe Tug::BuildTool do
4
+ describe "when returning an xctool" do
5
+ it "should return a build tool" do
6
+ xctool = Tug::BuildTool.tool_for_config("Debug")
7
+ expect(xctool).to be_kind_of(Tug::BuildToolBuild)
8
+ end
9
+
10
+ it "should return an archive tool" do
11
+ xctool = Tug::BuildTool.tool_for_config("InHouse")
12
+ expect(xctool).to be_kind_of(Tug::BuildToolArchive)
13
+ end
14
+
15
+ it "should return an archive tool when release is in the config" do
16
+ xctool = Tug::BuildTool.tool_for_config("TestRelease")
17
+ expect(xctool).to be_kind_of(Tug::BuildToolArchive)
18
+ end
19
+
20
+ it "should return an archive tool when inhouse is in the config" do
21
+ xctool = Tug::BuildTool.tool_for_config("TestInHouse")
22
+ expect(xctool).to be_kind_of(Tug::BuildToolArchive)
23
+ end
24
+ end
25
+ end
@@ -5,8 +5,8 @@ describe Tug::IpaCommand do
5
5
  describe "when executing" do
6
6
  before(:each) do
7
7
  @command = Tug::IpaCommand.new
8
- allow_any_instance_of(Tug::XcodeBuild).to receive(:system)
9
- allow_any_instance_of(Tug::XCTool).to receive(:system)
8
+ allow_any_instance_of(Tug::BuildToolExport).to receive(:system)
9
+ allow_any_instance_of(Tug::BuildTool).to receive(:system)
10
10
  allow(FileUtils).to receive(:mv)
11
11
  allow(@command).to receive(:system)
12
12
 
@@ -18,13 +18,13 @@ describe Tug::IpaCommand do
18
18
  allow(@config).to receive(:project).and_return(@project)
19
19
  end
20
20
 
21
- it "should generate an archive using xctool" do
22
- expect_any_instance_of(Tug::XCTool).to receive(:system).with("xctool -workspace workspace -scheme scheme -configuration InHouse archive -archivePath /tmp/scheme.xcarchive")
21
+ it "should generate an archive using xcodebuild" do
22
+ expect_any_instance_of(Tug::BuildTool).to receive(:system).with("xcodebuild -workspace workspace -scheme scheme -configuration InHouse archive -archivePath /tmp/scheme.xcarchive")
23
23
  @command.execute(@config)
24
24
  end
25
25
 
26
26
  it "should export an ipa using xcode build" do
27
- expect_any_instance_of(Tug::XcodeBuild).to receive(:system).with("xcodebuild -archivePath /tmp/scheme.xcarchive -exportPath /tmp/scheme.ipa -exportFormat ipa -exportArchive -exportWithOriginalSigningIdentity")
27
+ expect_any_instance_of(Tug::BuildToolExport).to receive(:system).with("xcodebuild -archivePath /tmp/scheme.xcarchive -exportPath /tmp/scheme.ipa -exportFormat ipa -exportArchive -exportWithOriginalSigningIdentity")
28
28
  @command.execute(@config)
29
29
  end
30
30
 
@@ -45,4 +45,4 @@ describe Tug::IpaCommand do
45
45
  @command.execute(@config)
46
46
  end
47
47
  end
48
- end
48
+ end
metadata CHANGED
@@ -1,97 +1,97 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tug
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alex Fish
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-09-04 00:00:00.000000000 Z
11
+ date: 2016-09-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: thor
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - '>='
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
19
  version: '0'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - '>='
24
+ - - ">="
25
25
  - !ruby/object:Gem::Version
26
26
  version: '0'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: bundler
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - ~>
31
+ - - "~>"
32
32
  - !ruby/object:Gem::Version
33
33
  version: '1.3'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - ~>
38
+ - - "~>"
39
39
  - !ruby/object:Gem::Version
40
40
  version: '1.3'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: rake
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - '>='
45
+ - - ">="
46
46
  - !ruby/object:Gem::Version
47
47
  version: '0'
48
48
  type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - '>='
52
+ - - ">="
53
53
  - !ruby/object:Gem::Version
54
54
  version: '0'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: rspec
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - '>='
59
+ - - ">="
60
60
  - !ruby/object:Gem::Version
61
61
  version: '0'
62
62
  type: :development
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - '>='
66
+ - - ">="
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0'
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: guard-rspec
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
- - - '>='
73
+ - - ">="
74
74
  - !ruby/object:Gem::Version
75
75
  version: '0'
76
76
  type: :development
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
- - - '>='
80
+ - - ">="
81
81
  - !ruby/object:Gem::Version
82
82
  version: '0'
83
83
  - !ruby/object:Gem::Dependency
84
84
  name: codeclimate-test-reporter
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
- - - '>='
87
+ - - ">="
88
88
  - !ruby/object:Gem::Version
89
89
  version: '0'
90
90
  type: :development
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
- - - '>='
94
+ - - ">="
95
95
  - !ruby/object:Gem::Version
96
96
  version: '0'
97
97
  description: Build and deploy iOS project
@@ -102,8 +102,9 @@ executables:
102
102
  extensions: []
103
103
  extra_rdoc_files: []
104
104
  files:
105
- - .gitignore
106
- - .travis.yml
105
+ - ".gitignore"
106
+ - ".ruby-version"
107
+ - ".travis.yml"
107
108
  - Gemfile
108
109
  - Gemfile.lock
109
110
  - Guardfile
@@ -129,12 +130,13 @@ files:
129
130
  - lib/tug/keychain/keychain.rb
130
131
  - lib/tug/notify/slack.rb
131
132
  - lib/tug/project/project.rb
132
- - lib/tug/tool/xcode_build.rb
133
- - lib/tug/tool/xctool.rb
134
- - lib/tug/tool/xctool_archive.rb
135
- - lib/tug/tool/xctool_build.rb
133
+ - lib/tug/tool/buildtool.rb
134
+ - lib/tug/tool/buildtool_archive.rb
135
+ - lib/tug/tool/buildtool_build.rb
136
+ - lib/tug/tool/buildtool_export.rb
136
137
  - lib/tug/version.rb
137
138
  - spec/build_command_spec.rb
139
+ - spec/buildtool_spec.rb
138
140
  - spec/command_spec.rb
139
141
  - spec/config_file_spec.rb
140
142
  - spec/deployer_spec.rb
@@ -148,7 +150,6 @@ files:
148
150
  - spec/slack_spec.rb
149
151
  - spec/spec_helper.rb
150
152
  - spec/testflight_spec.rb
151
- - spec/xctool_spec.rb
152
153
  - tug.gemspec
153
154
  homepage: https://github.com/alexfish/tug
154
155
  licenses:
@@ -160,22 +161,23 @@ require_paths:
160
161
  - lib
161
162
  required_ruby_version: !ruby/object:Gem::Requirement
162
163
  requirements:
163
- - - '>='
164
+ - - ">="
164
165
  - !ruby/object:Gem::Version
165
166
  version: '0'
166
167
  required_rubygems_version: !ruby/object:Gem::Requirement
167
168
  requirements:
168
- - - '>='
169
+ - - ">="
169
170
  - !ruby/object:Gem::Version
170
171
  version: '0'
171
172
  requirements: []
172
173
  rubyforge_project:
173
- rubygems_version: 2.0.14
174
+ rubygems_version: 2.5.1
174
175
  signing_key:
175
176
  specification_version: 4
176
177
  summary: iOS project builder and depoloyer
177
178
  test_files:
178
179
  - spec/build_command_spec.rb
180
+ - spec/buildtool_spec.rb
179
181
  - spec/command_spec.rb
180
182
  - spec/config_file_spec.rb
181
183
  - spec/deployer_spec.rb
@@ -189,4 +191,3 @@ test_files:
189
191
  - spec/slack_spec.rb
190
192
  - spec/spec_helper.rb
191
193
  - spec/testflight_spec.rb
192
- - spec/xctool_spec.rb
@@ -1,25 +0,0 @@
1
- require 'spec_helper'
2
-
3
- describe Tug::XCTool do
4
- describe "when returning an xctool" do
5
- it "should return a build tool" do
6
- xctool = Tug::XCTool.tool_for_config("Debug")
7
- expect(xctool).to be_kind_of(Tug::XCToolBuild)
8
- end
9
-
10
- it "should return an archive tool" do
11
- xctool = Tug::XCTool.tool_for_config("InHouse")
12
- expect(xctool).to be_kind_of(Tug::XCToolArchive)
13
- end
14
-
15
- it "should return an archive tool when release is in the config" do
16
- xctool = Tug::XCTool.tool_for_config("TestRelease")
17
- expect(xctool).to be_kind_of(Tug::XCToolArchive)
18
- end
19
-
20
- it "should return an archive tool when inhouse is in the config" do
21
- xctool = Tug::XCTool.tool_for_config("TestInHouse")
22
- expect(xctool).to be_kind_of(Tug::XCToolArchive)
23
- end
24
- end
25
- end