slowlane 0.0.5 → 0.0.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (5) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +17 -6
  3. data/bin/slowlane-ipa +80 -0
  4. data/slowlane.gemspec +4 -1
  5. metadata +45 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 996343b2a57956f5100f61500678e87e2dbe9c75
4
- data.tar.gz: fb77f22fc606a9bb76929b3993507a78dd13888b
3
+ metadata.gz: 8e2c3e1c9c65dd882a5088daf22bf155a937e9f9
4
+ data.tar.gz: 4a5b74477034b1b94b3422a2565c0c2a56c86cea
5
5
  SHA512:
6
- metadata.gz: 5824f0339b803eb797697d722841160778d3bf551caedc034219787ae8457da899ba2b2cf0bb1667f1696261c87bc83ea268b3401eb74208b994c096b785f496
7
- data.tar.gz: d6d08faed6f369f4934c265ed820239eb420e5fefebf5746eb873a9c1da831dbcbbdbe9c96ac743add3dc6fa775fa8443e29b0a146cf9d2d19b9d83a348db185
6
+ metadata.gz: 6d5e4a8a55b60ad99fcfdea6d6494938f64aba75af1dc0a895373246465a2696c8bdd12cc03ea1a4c5633f8b64e61d230d5ef40510f845ae319a4a8d06500a2c
7
+ data.tar.gz: 475ca8666a5efa6e4116e509ff0ef123685cb26ba2ecf9d1c433e8e04d81864872ac9255073b48433dc1d1d08718ded8afa77ffb995f0ae219efe7ec952a8a58
data/README.md CHANGED
@@ -18,14 +18,21 @@ Don't get us wrong, we think fastlane is **great** , but we are one of those wh
18
18
  We leverage 'spaceship' library and will continue to work on that to have a shared
19
19
 
20
20
  ## Love feedback!
21
- Let us know if you like this! [We're only one tweet away!](http://twitter.com/slowlane)
21
+ Let us know if you like this! [We're only one tweet away!](http://twitter.com/slowlanetools)
22
+
23
+ ## Kudos
24
+ - [Fastlane](https://github.com/fastlane/fastlane)
25
+ - [Shenzhen](https://github.com/nomad/shenzhen)
22
26
 
23
27
  ## Status
24
28
  Current able to list most items, moving on to create & delete
25
29
 
26
30
  `gem install slowlane`
27
31
 
28
- results in two binaries: `slowlane-itunes` & `slowlane-portal`
32
+ results in binaries:
33
+ - `slowlane-itunes`
34
+ - `slowlane-portal`
35
+ - `slowlane-ipa` (NOTE: this might change to a more generic `slowlane-ios` command)
29
36
 
30
37
  ### Working
31
38
  #### environment vars
@@ -51,8 +58,12 @@ results in two binaries: `slowlane-itunes` & `slowlane-portal`
51
58
  - `slowlane-itunes tester list`
52
59
  - `slowlane-itunes build list`
53
60
 
61
+ #### Ipa
62
+ - `slowlane-ipa info`
63
+
54
64
  ### Todo
55
- #### Overall options
65
+ #### Overall
66
+ A lot is still focusing on the happy path , we need to catch better the errors and deal with it
56
67
  - output-format=csv
57
68
  - output-file
58
69
  - sort-field :
@@ -79,9 +90,9 @@ results in two binaries: `slowlane-itunes` & `slowlane-portal`
79
90
  - build upload
80
91
  - all other commands
81
92
 
93
+ #### Ipa
94
+ - ipa upload
95
+
82
96
  #### Playstore
83
97
  - all commands
84
98
 
85
- #### Crashlytics
86
- - ipa check
87
- - upload
data/bin/slowlane-ipa ADDED
@@ -0,0 +1,80 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require 'rubygems'
4
+ require "thor"
5
+ require 'plist'
6
+ require 'tempfile'
7
+ require 'zip'
8
+ require 'zip/filesystem'
9
+ require 'terminal-table'
10
+
11
+ class SlowlaneIpa < Thor
12
+
13
+ # Currently Ripped from shenzhen rubygem, will cleanup later
14
+ # I did not want dependencies on shenzhen too much as they might conflict with fastlane and it is not maintained anymore
15
+ desc "info <filename>", "get info from ipa file"
16
+ def info(filename)
17
+ Zip::File.open(filename) do |zipfile|
18
+ app_entry = zipfile.find_entry("Payload/#{File.basename(filename, File.extname(filename))}.app")
19
+ provisioning_profile_entry = zipfile.find_entry("#{app_entry.name}embedded.mobileprovision") if app_entry
20
+
21
+ if (!provisioning_profile_entry)
22
+ zipfile.dir.entries("Payload").each do |dir_entry|
23
+ if dir_entry =~ /.app$/
24
+ #say "Using .app: #{dir_entry}"
25
+ app_entry = zipfile.find_entry("Payload/#{dir_entry}")
26
+ provisioning_profile_entry = zipfile.find_entry("#{app_entry.name}embedded.mobileprovision") if app_entry
27
+ break
28
+ end
29
+ end
30
+ end
31
+
32
+ #say_error "Embedded mobile provisioning file not found in #{@file}" and abort unless provisioning_profile_entry
33
+
34
+ tempdir = ::File.new(Dir.mktmpdir)
35
+ begin
36
+ zipfile.each do |zip_entry|
37
+ temp_entry_path = ::File.join(tempdir.path, zip_entry.name)
38
+
39
+ FileUtils.mkdir_p(::File.dirname(temp_entry_path))
40
+ zipfile.extract(zip_entry, temp_entry_path) unless ::File.exist?(temp_entry_path)
41
+ end
42
+
43
+ temp_provisioning_profile = ::File.new(::File.join(tempdir.path, provisioning_profile_entry.name))
44
+ temp_app_directory = ::File.new(::File.join(tempdir.path, app_entry.name))
45
+
46
+ plist = Plist::parse_xml(`security cms -D -i #{temp_provisioning_profile.path}`)
47
+
48
+ codesign = `codesign -dv "#{temp_app_directory.path}" 2>&1`
49
+ codesigned = /Signed Time/ === codesign
50
+
51
+ table = Terminal::Table.new do |t|
52
+ plist.each do |key, value|
53
+ next if key == "DeveloperCertificates"
54
+
55
+ columns = []
56
+ columns << key
57
+ columns << case value
58
+ when Hash
59
+ value.collect{|k, v| "#{k}: #{v}"}.join("\n")
60
+ when Array
61
+ value.join("\n")
62
+ else
63
+ value.to_s
64
+ end
65
+
66
+ t << columns
67
+ end
68
+
69
+ t << ["Codesigned", codesigned.to_s.capitalize]
70
+ end
71
+
72
+ puts table
73
+
74
+ end
75
+
76
+ end
77
+ end
78
+ end
79
+
80
+ SlowlaneIpa.start(ARGV)
data/slowlane.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = "slowlane"
5
- s.version = "0.0.5"
5
+ s.version = "0.0.6"
6
6
  s.platform = Gem::Platform::RUBY
7
7
  s.license = 'MIT'
8
8
  s.authors = ["Patrick Debois"]
@@ -18,6 +18,9 @@ Gem::Specification.new do |s|
18
18
  s.add_dependency "spaceship"
19
19
  s.add_dependency "fastlane_core"
20
20
  s.add_dependency "terminal-table"
21
+ s.add_dependency 'rubyzip', '~> 1.1'
22
+ s.add_dependency 'zip-zip'
23
+ s.add_dependency 'CFPropertyList'
21
24
 
22
25
  s.files = `git ls-files`.split("\n")
23
26
  s.executables = `git ls-files`.split("\n").map { |f| f =~ /^bin\/(.*)/ ? $1 : nil }.compact
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: slowlane
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.5
4
+ version: 0.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Patrick Debois
@@ -66,10 +66,53 @@ dependencies:
66
66
  - - '>='
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: rubyzip
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - ~>
74
+ - !ruby/object:Gem::Version
75
+ version: '1.1'
76
+ type: :runtime
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - ~>
81
+ - !ruby/object:Gem::Version
82
+ version: '1.1'
83
+ - !ruby/object:Gem::Dependency
84
+ name: zip-zip
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - '>='
88
+ - !ruby/object:Gem::Version
89
+ version: '0'
90
+ type: :runtime
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - '>='
95
+ - !ruby/object:Gem::Version
96
+ version: '0'
97
+ - !ruby/object:Gem::Dependency
98
+ name: CFPropertyList
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - '>='
102
+ - !ruby/object:Gem::Version
103
+ version: '0'
104
+ type: :runtime
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - '>='
109
+ - !ruby/object:Gem::Version
110
+ version: '0'
69
111
  description: Cli version without supprises
70
112
  email:
71
113
  - patrick.debois@jedi.be
72
114
  executables:
115
+ - slowlane-ipa
73
116
  - slowlane-itunes
74
117
  - slowlane-portal
75
118
  extensions: []
@@ -79,6 +122,7 @@ files:
79
122
  - Gemfile
80
123
  - README.md
81
124
  - Rakefile
125
+ - bin/slowlane-ipa
82
126
  - bin/slowlane-itunes
83
127
  - bin/slowlane-portal
84
128
  - lib/slowlane/itunes/app.rb