podspecpush 0.4.0 → 0.5.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: 6b20d74ec8bf7ddadb76f07072286895a8441d44
4
- data.tar.gz: b9f86df68e5d4aab8b86ae8fd4a7c3b9bd5795a6
3
+ metadata.gz: d3faa15aa12076b7850a59b1414ca8d0a516caa4
4
+ data.tar.gz: eac72308586de8ff936dfcd20b12c389396e8d68
5
5
  SHA512:
6
- metadata.gz: ef3369cd43994a300880ccf87a15c49eb0675413c3a6f46dc890df2213924923e2e6c0c24813f2f1d8b873ca5bf56cd261a08e726cbbf0358b4d4af22e9e0243
7
- data.tar.gz: 943496a551621a41406894d41136ef65735537795da3f7acad9ebc6f0fd5100d42cdd1c82ebb952ec59d53bca7cde7fc7847bc4a74371abe352193af367a7929
6
+ metadata.gz: 63d36c6148bd38b85ef99ff5b4bbbb462b1a0968390885073a4139e4751f8a1519afafe608702528833884a7ca594f252c120a249b7b2dd2642d59f94efff9e8
7
+ data.tar.gz: a98f338180959ca2b261e3d98989ce8ec601ac69f0f81a8c3d523e48fd6bf83a22055ece9f150a90b8c304980254359f53b1f5c895a39286a0200e20ba63bb56
@@ -1,3 +1,3 @@
1
1
  module Podspecpush
2
- VERSION = "0.4.0"
2
+ VERSION = "0.5.0"
3
3
  end
data/lib/podspecpush.rb CHANGED
@@ -47,15 +47,20 @@ module Podspecpush
47
47
  end
48
48
 
49
49
  File.open(podspecName, 'w') { |file| file.write(newFile) }
50
+
51
+ isPrivateFlag = (privateRepo == true ? ' --private' : '')
52
+ sourcesFlag = (sources == nil ? '' : " --sources=#{sources},https://github.com/CocoaPods/Specs.git")
53
+ disallowWarningsLint = "pod spec lint #{podspecName}" + isPrivateFlag + sourcesFlag
54
+ allowWarningsLint = disallowWarningsLint + " --allow-warnings"
50
55
 
51
- lintCmd = "pod spec lint #{podspecName}" + (force == true ? ' --allow-warnings' : '') + (privateRepo == true ? ' --private' : '') + (sources == nil ? '' : " --sources=#{sources}")
56
+ lintCmd = (force == true ? allowWarningsLint : disallowWarningsLint)
52
57
  lint = system(lintCmd)
53
58
 
54
59
  if lint == false
55
60
  puts "Linting failed, try again by allowing warnings? [Y/n]"
56
61
  decision = gets.chomp.downcase
57
62
  if decision == "y"
58
- tryAgainCmd = "pod spec lint #{podspecName} --allow-warnings" + (privateRepo == true ? ' --private' : '') + (sources == nil ? '' : " --sources=#{sources}")
63
+ tryAgainCmd = allowWarningsLint
59
64
  tryAgain = system(tryAgainCmd)
60
65
 
61
66
  if tryAgain == false
@@ -63,14 +68,13 @@ module Podspecpush
63
68
  exit
64
69
  else
65
70
  puts "Proceeding by allowing warnings"
66
- force = true
67
71
  end
68
72
  else
69
73
  exit
70
74
  end
71
75
  end
72
76
 
73
- pushCmd = "pod repo push #{repoName} #{podspecName}" + (force == true ? ' --allow-warnings' : '')
77
+ pushCmd = "pod repo push #{repoName} #{podspecName} --allow-warnings"
74
78
  repoPush = system(pushCmd)
75
79
 
76
80
  if repoPush == false
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: podspecpush
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0
4
+ version: 0.5.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Joe Carroll
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-08-03 00:00:00.000000000 Z
11
+ date: 2017-11-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: trollop