cocoapods-coding-ar 1.0.0 → 1.0.1
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 +4 -4
- data/lib/cocoapods_coding_ar.rb +1 -1
- data/lib/coding_ar_command.rb +10 -2
- data/lib/coding_ar_util.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 421539e01379b218c146b8ed2b3a3d1ef0ee945a7b4d606014130457e55aa0ae
|
4
|
+
data.tar.gz: 1d8e2f6ce82a444be1f679f5b2fee6180873c7694c72e4bb7499b0edf50568bf
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: af2a1dedba291a95857da3d7f9b1e6ecf10184f5f6fc576a7d79d93f9248f2061793e08474b5ecaed9c596da60803908c7912b9bd410b5ff574918148ba435fb
|
7
|
+
data.tar.gz: 2ec006f926f07ac148bafa50235732eec8ce0beea8417c53fec33923a7f5067976441e742446577a18ccfe67f377fe9c740401a06532adf5f724d8062ca31857
|
data/lib/cocoapods_coding_ar.rb
CHANGED
data/lib/coding_ar_command.rb
CHANGED
@@ -75,7 +75,6 @@ module Pod
|
|
75
75
|
end
|
76
76
|
|
77
77
|
def validate!
|
78
|
-
super
|
79
78
|
super
|
80
79
|
unless @repo && @podspec
|
81
80
|
help! 'This command requires both a repo and a podspec.'
|
@@ -83,6 +82,10 @@ module Pod
|
|
83
82
|
end
|
84
83
|
|
85
84
|
def run
|
85
|
+
unless File.file? File.join(Config.instance.repos_dir, @repo, ".coding_ar_url")
|
86
|
+
raise Informative, "`#@repo` is not a CODING-AR repo.".red
|
87
|
+
end
|
88
|
+
|
86
89
|
FileUtils.mkdir_p tmp_dir
|
87
90
|
begin
|
88
91
|
UI.section("Pushing pod `#{spec.name} #{spec.version.to_s}`` to CODING-AR repo `#@repo`") do
|
@@ -99,6 +102,7 @@ module Pod
|
|
99
102
|
|
100
103
|
def create_pod_tar_gz
|
101
104
|
require 'digest/sha1'
|
105
|
+
require 'find'
|
102
106
|
|
103
107
|
pod_dir = File.join(tmp_dir, "pod")
|
104
108
|
FileUtils.mkdir_p(pod_dir)
|
@@ -110,7 +114,11 @@ module Pod
|
|
110
114
|
Pod::Sandbox::FileAccessor.new(path_list, spec.consumer(platform))
|
111
115
|
end
|
112
116
|
|
113
|
-
Pod::Sandbox::FileAccessor.all_files(file_accessors).
|
117
|
+
pod_files = Pod::Sandbox::FileAccessor.all_files(file_accessors).map do |path|
|
118
|
+
Find.find(path).select { |path| File.file? path}
|
119
|
+
end
|
120
|
+
|
121
|
+
pod_files.flatten.each do |source|
|
114
122
|
target = File.join(pod_dir, Pathname(source).relative_path_from(pod_root))
|
115
123
|
FileUtils.mkdir_p(File.dirname(target))
|
116
124
|
FileUtils.copy_file(source, target)
|
data/lib/coding_ar_util.rb
CHANGED
@@ -7,7 +7,7 @@ module Pod
|
|
7
7
|
class CodingArUtil
|
8
8
|
CODING_AR_NETRC_PATH_ENV = 'COCOAPODS_CODING_AR_NETRC_PATH'
|
9
9
|
JSON_CONTENT_TYPE = 'application/json; charset=utf-8'
|
10
|
-
USER_AGENT = "cocoapods-coding-ar/#{CocoapodsCodingAr::VERSION}"
|
10
|
+
USER_AGENT = "cocoapods-coding-ar/#{CocoapodsCodingAr::VERSION} cocoapods/#{Pod::VERSION} #{RUBY_ENGINE}/#{RUBY_VERSION}-p#{RUBY_PATCHLEVEL} (#{IO.popen('uname -v').gets.strip})"
|
11
11
|
|
12
12
|
def self.coding_ar_service?(url)
|
13
13
|
request = Typhoeus::Request.new(
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cocoapods-coding-ar
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- huangmingxin
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-11-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|