xcode-install 1.2.4 → 1.2.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/xcode/install.rb +9 -4
- data/lib/xcode/install/install.rb +3 -1
- data/lib/xcode/install/simulators.rb +1 -1
- data/lib/xcode/install/version.rb +1 -1
- data/xcode-install.gemspec +1 -1
- metadata +21 -15
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c0cb5346a3d13b6710a60b68ca9099b0f2a55a8f
|
4
|
+
data.tar.gz: 99e5071dcd26f18f76d8d82c52e1bb46f5a4a161
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3c547031019e7cd391bb33cebe55298204ad3494bc36f2a1e9bf88d58986fc009645d6671285db7f862d3b3e2a1a997e080f9c948128bd0ecb22de97a3f04a4c
|
7
|
+
data.tar.gz: 6108652858c7e60ba5d25d19ef9b974ecaf117175ecf754d545a2a19461f13bf97e18ed41937b907bf1bd9bde1d118d82f3400bdd7614db0b0bc3ae81f8bcc57
|
data/lib/xcode/install.rb
CHANGED
@@ -127,14 +127,20 @@ HELP
|
|
127
127
|
`open #{xcode.release_notes_url}` unless xcode.nil? || xcode.release_notes_url.nil?
|
128
128
|
end
|
129
129
|
|
130
|
+
def list_annotated(xcodes_list)
|
131
|
+
installed = installed_versions.map(&:version)
|
132
|
+
xcodes_list.map { |x| installed.include?(x) ? "#{x} (installed)" : x }.join("\n")
|
133
|
+
end
|
134
|
+
|
130
135
|
def list_current
|
131
136
|
stable_majors = list_versions.reject { |v| /beta/i =~ v }.map { |v| v.split('.')[0] }.map { |v| v.split(' ')[0] }
|
132
137
|
latest_stable_major = stable_majors.select { |v| v.length == 1 }.uniq.sort.last.to_i
|
133
|
-
list_versions.select { |v| v.split('.')[0].to_i >= latest_stable_major }.sort
|
138
|
+
current_versions = list_versions.select { |v| v.split('.')[0].to_i >= latest_stable_major }.sort
|
139
|
+
list_annotated(current_versions)
|
134
140
|
end
|
135
141
|
|
136
142
|
def list
|
137
|
-
list_versions.
|
143
|
+
list_annotated(list_versions.sort)
|
138
144
|
end
|
139
145
|
|
140
146
|
def rm_list_cache
|
@@ -248,8 +254,7 @@ HELP
|
|
248
254
|
end
|
249
255
|
|
250
256
|
def list_versions
|
251
|
-
|
252
|
-
seedlist.map(&:name).reject { |x| installed.include?(x) }
|
257
|
+
seedlist.map(&:name)
|
253
258
|
end
|
254
259
|
|
255
260
|
def prereleases
|
@@ -12,6 +12,7 @@ module XcodeInstall
|
|
12
12
|
|
13
13
|
def self.options
|
14
14
|
[['--url', 'Custom Xcode DMG file path or HTTP URL.'],
|
15
|
+
['--force', 'Install even if the same version is already installed.'],
|
15
16
|
['--no-switch', 'Don’t switch to this version after installation'],
|
16
17
|
['--no-install', 'Only download DMG, but do not install it.'],
|
17
18
|
['--no-progress', 'Don’t show download progress.'],
|
@@ -22,6 +23,7 @@ module XcodeInstall
|
|
22
23
|
@installer = Installer.new
|
23
24
|
@version = argv.shift_argument
|
24
25
|
@url = argv.option('url')
|
26
|
+
@force = argv.flag?('force', false)
|
25
27
|
@should_clean = argv.flag?('clean', true)
|
26
28
|
@should_install = argv.flag?('install', true)
|
27
29
|
@should_switch = argv.flag?('switch', true)
|
@@ -33,7 +35,7 @@ module XcodeInstall
|
|
33
35
|
super
|
34
36
|
|
35
37
|
help! 'A VERSION argument is required.' unless @version
|
36
|
-
fail Informative, "Version #{@version} already installed." if @installer.installed?(@version)
|
38
|
+
fail Informative, "Version #{@version} already installed." if @installer.installed?(@version) && !@force
|
37
39
|
fail Informative, "Version #{@version} doesn't exist." unless @installer.exist?(@version)
|
38
40
|
fail Informative, "Invalid URL: `#{@url}`" unless !@url || @url =~ /\A#{URI.regexp}\z/
|
39
41
|
end
|
@@ -41,7 +41,7 @@ module XcodeInstall
|
|
41
41
|
puts "[!] More than one simulator matching #{@install} was found. Please specify the full version.".ansi.red
|
42
42
|
filtered_simulators.each do |candidate|
|
43
43
|
puts "Xcode #{candidate.xcode.bundle_version} (#{candidate.xcode.path})".ansi.green
|
44
|
-
puts "xcversion simulators --install=#{candidate.
|
44
|
+
puts "xcversion simulators --install=#{candidate.name}"
|
45
45
|
end
|
46
46
|
exit 1
|
47
47
|
end
|
data/xcode-install.gemspec
CHANGED
@@ -20,7 +20,7 @@ Gem::Specification.new do |spec|
|
|
20
20
|
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
21
21
|
spec.require_paths = ['lib']
|
22
22
|
|
23
|
-
spec.add_dependency 'claide', '
|
23
|
+
spec.add_dependency 'claide', '>= 0.9.1', '< 1.1.0'
|
24
24
|
# spec.add_dependency 'spaceship', '>= 0.16.0', '< 1.0.0'
|
25
25
|
spec.add_dependency 'spaceship', '= 0.15.1'
|
26
26
|
|
metadata
CHANGED
@@ -1,29 +1,35 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: xcode-install
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Boris Bügling
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2016-01-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: claide
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- -
|
17
|
+
- - '>='
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: 0.9.1
|
20
|
+
- - <
|
21
|
+
- !ruby/object:Gem::Version
|
22
|
+
version: 1.1.0
|
20
23
|
type: :runtime
|
21
24
|
prerelease: false
|
22
25
|
version_requirements: !ruby/object:Gem::Requirement
|
23
26
|
requirements:
|
24
|
-
- -
|
27
|
+
- - '>='
|
25
28
|
- !ruby/object:Gem::Version
|
26
29
|
version: 0.9.1
|
30
|
+
- - <
|
31
|
+
- !ruby/object:Gem::Version
|
32
|
+
version: 1.1.0
|
27
33
|
- !ruby/object:Gem::Dependency
|
28
34
|
name: spaceship
|
29
35
|
requirement: !ruby/object:Gem::Requirement
|
@@ -42,28 +48,28 @@ dependencies:
|
|
42
48
|
name: bundler
|
43
49
|
requirement: !ruby/object:Gem::Requirement
|
44
50
|
requirements:
|
45
|
-
- -
|
51
|
+
- - ~>
|
46
52
|
- !ruby/object:Gem::Version
|
47
53
|
version: '1.7'
|
48
54
|
type: :development
|
49
55
|
prerelease: false
|
50
56
|
version_requirements: !ruby/object:Gem::Requirement
|
51
57
|
requirements:
|
52
|
-
- -
|
58
|
+
- - ~>
|
53
59
|
- !ruby/object:Gem::Version
|
54
60
|
version: '1.7'
|
55
61
|
- !ruby/object:Gem::Dependency
|
56
62
|
name: rake
|
57
63
|
requirement: !ruby/object:Gem::Requirement
|
58
64
|
requirements:
|
59
|
-
- -
|
65
|
+
- - ~>
|
60
66
|
- !ruby/object:Gem::Version
|
61
67
|
version: '10.0'
|
62
68
|
type: :development
|
63
69
|
prerelease: false
|
64
70
|
version_requirements: !ruby/object:Gem::Requirement
|
65
71
|
requirements:
|
66
|
-
- -
|
72
|
+
- - ~>
|
67
73
|
- !ruby/object:Gem::Version
|
68
74
|
version: '10.0'
|
69
75
|
description: Download, install and upgrade Xcodes with ease.
|
@@ -75,11 +81,11 @@ executables:
|
|
75
81
|
extensions: []
|
76
82
|
extra_rdoc_files: []
|
77
83
|
files:
|
78
|
-
-
|
79
|
-
-
|
80
|
-
-
|
81
|
-
-
|
82
|
-
-
|
84
|
+
- .gitattributes
|
85
|
+
- .gitignore
|
86
|
+
- .rubocop.yml
|
87
|
+
- .rubocop_todo.yml
|
88
|
+
- .travis.yml
|
83
89
|
- Gemfile
|
84
90
|
- LICENSE.txt
|
85
91
|
- README.md
|
@@ -129,12 +135,12 @@ require_paths:
|
|
129
135
|
- lib
|
130
136
|
required_ruby_version: !ruby/object:Gem::Requirement
|
131
137
|
requirements:
|
132
|
-
- -
|
138
|
+
- - '>='
|
133
139
|
- !ruby/object:Gem::Version
|
134
140
|
version: 2.0.0
|
135
141
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
136
142
|
requirements:
|
137
|
-
- -
|
143
|
+
- - '>='
|
138
144
|
- !ruby/object:Gem::Version
|
139
145
|
version: '0'
|
140
146
|
requirements: []
|