pod_updater 0.3.5 → 0.3.6

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ed7154a556bdefabea065826c71acd8ca3394526
4
- data.tar.gz: 6b5ea5a2d20b95b9ebaea78ff667d7da7ba719d4
3
+ metadata.gz: 75cf69415a2df85630924d213e101b8a989d229e
4
+ data.tar.gz: 8dcb3be1122d28522425eae9504e7824e9e3eb37
5
5
  SHA512:
6
- metadata.gz: 073622a1997a4cb128190e66d3a86ed25d7c3e7bae5017bce30d5ad70c7d9ef094ca11e589d6b5f69f59694116f9eaff8d2dfe85d869ecdd0b3b3d3794b369c5
7
- data.tar.gz: 0edf73328287676aef11e1b99b0997c22cdb9a021af3c1c5c05443669226de2c2da5c40c05f68717afb6ccae3dd1ce2b9d71cce1372c1fcd699488786dd8a07e
6
+ metadata.gz: 75af531c04d9c5166a080010bfc15ef61ae19286d5d4d8bbabad6c59d7cb743314ad11632aaa40122ca61525d479176a067d6ea584bc0339082dfb030a2e9d06
7
+ data.tar.gz: 758b518cade1dec7b75ef15cdeb1b9c39c4d825cbfd762a8cea09f36090168e12445b4b0a686d792352f6f87b8b5ac350335002348e4cb44c7c3cf7bdb7eb875
data/.DS_Store CHANGED
Binary file
data/README.md CHANGED
@@ -1,8 +1,7 @@
1
1
  # PodUpdater
2
2
 
3
- Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/pod_updater`. To experiment with that code, run `bin/console` for an interactive prompt.
4
-
5
- TODO: Delete this and the text above, and describe your gem
3
+ iOS开发中帮助您快速的将自己的开发的pod库代码上传到git,并帮你push到podspec repo库去
4
+ 使用方式:cd到你的pod库代码目录,然后执行'pod_updater -v [new_version]',然后就可以去喝杯茶了
6
5
 
7
6
  ## Installation
8
7
 
@@ -22,7 +21,27 @@ Or install it yourself as:
22
21
 
23
22
  ## Usage
24
23
 
25
- TODO: Write usage instructions here
24
+ cd to the path where your podspec project.
25
+
26
+ ```
27
+ cd ~/Desktop/my_private_pod/my_first_pod
28
+
29
+ ```
30
+ then , run 'pod_updater -v 1.0.1'
31
+
32
+ ```
33
+ pod_updater -v 1.0.1
34
+ ```
35
+
36
+ There are some shell commands in my shell.
37
+
38
+ ```
39
+ qwkdeMacBook-Pro-2:~ qwk$ cd ~/Documents/WZ_GitHub/WZ_HelloKit
40
+
41
+ qwkdeMacBook-Pro-2:WZ_HelloKit qwk$ pod_updater -v 3.0.0
42
+
43
+ ```
44
+
26
45
 
27
46
  ## Development
28
47
 
@@ -41,3 +60,5 @@ The gem is available as open source under the terms of the [MIT License](https:/
41
60
  ## Code of Conduct
42
61
 
43
62
  Everyone interacting in the PodUpdater project’s codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/[USERNAME]/pod_updater/blob/master/CODE_OF_CONDUCT.md).
63
+
64
+
data/bin/pod_updater CHANGED
@@ -7,18 +7,17 @@ options = {}
7
7
  option_parser = OptionParser.new do |opts|
8
8
 
9
9
  opts.banner = 'here is help messages of the command line tool'
10
-
11
10
  options[:version] = nil
12
11
  opts.on('-v', '--version [version]', String, 'the podspec\'s version') do |version|
13
- options[:version] = version
12
+ options[:version] = version
14
13
  end
15
14
 
16
15
  end.parse!
17
16
 
18
17
  unless options[:version]
19
18
 
20
- abort("ABORTED! You forgot pass a version value with command \'-v [version]\'")
21
- exit
19
+ abort("ABORTED! You forgot pass a version value with command \'-v [version]\'")
20
+ exit
22
21
  end
23
22
 
24
23
  PodUpdater.run(options[:version])
@@ -1,3 +1,4 @@
1
+ require 'pod_updater/ui'
1
2
 
2
3
  module PodUpdater
3
4
 
@@ -16,7 +17,7 @@ module PodUpdater
16
17
  # TODO: 尝试在每次即将执行该命令时,打印出这次的命令
17
18
  IO.popen(cmd.join(" && ")) do |io|
18
19
  io.each do |line|
19
- puts line
20
+ UI.msg line
20
21
  end
21
22
  io.close
22
23
  end
@@ -1,3 +1,4 @@
1
+ require 'pod_updater/ui'
1
2
 
2
3
  module PodUpdater
3
4
 
@@ -5,11 +6,11 @@ module PodUpdater
5
6
  def modifyPodspec(path:"",version:"0.0.0")
6
7
 
7
8
  if version == "0.0.0"
8
- puts "请指定版本好的值,如 modifyPodspec version:#{version}"
9
+ UI.msg "请指定版本好的值,如 modifyPodspec version:#{version}"
9
10
  return
10
11
  end
11
12
  unless version =~ /^\d{1,}.\d.\d$|^\d{1,}.\d$|^\d{1,}$/
12
- puts "version:#{version}的格式不对"
13
+ UI.msg "version:#{version}的格式不对"
13
14
  return 
14
15
  end
15
16
 
@@ -18,11 +19,11 @@ module PodUpdater
18
19
  # END
19
20
 
20
21
  unless File.exist?path
21
- puts "路径不存在"
22
+ UI.err "路径不存在"
22
23
  return
23
24
  end
24
25
 
25
- puts "***修改podspec文件***"
26
+ UI.msg "***修改podspec文件***"
26
27
  File.open(path, "r+") do |f|
27
28
  s = ""
28
29
  f.each_line do |line|
@@ -36,7 +37,7 @@ module PodUpdater
36
37
  end
37
38
  s += line
38
39
  end
39
- puts "#{s}"
40
+ UI.msg "#{s}"
40
41
  File.open(path, "w+") do |f| f.write(s) end
41
42
  end
42
43
 
@@ -53,26 +54,26 @@ module PodUpdater
53
54
 
54
55
  if File.directory?(path)
55
56
  podfiles = Dir.glob("#{path}/*.podspec")
56
- puts "#{podfiles}"
57
+ UI.msg "#{podfiles}"
57
58
  if podfiles.length == 0
58
- puts %('#{path}'下无法找到'.podspec'文件)
59
+ UI.err %('#{path}'下无法找到'.podspec'文件)
59
60
  return nil
60
61
  elsif podfiles.length == 1
61
62
  path = podfiles.first
62
63
  else
63
- puts "目录下找到多个podspec文件!"
64
+ UI.msg "目录下找到多个podspec文件!"
64
65
  podfiles.each_with_index do |elem, index|
65
66
  basename = File.basename(elem)
66
67
  puts %(#{index}.#{basename} )
67
68
  end
68
- puts "请指定您当前需要的操作的文件,输入它的序号:"
69
+ UI.msg "请指定您当前需要的操作的文件,输入它的序号:"
69
70
  i = gets.to_i
70
71
 
71
72
  case i
72
73
  when 0 .. (podfiles.length-1)
73
74
  path = podfiles[i.to_i]
74
75
  else
75
- puts "输入错误❌"
76
+ UI.err "输入错误❌"
76
77
  path = nil
77
78
  end
78
79
 
@@ -1,5 +1,6 @@
1
1
  require "pod_updater/git_tag_flow"
2
2
  require "pod_updater/modify_podspec"
3
+ require 'pod_updater/ui'
3
4
 
4
5
  module PodUpdater
5
6
 
@@ -12,7 +13,7 @@ module PodUpdater
12
13
  podFilePath = pathWithPodspecSuffix(path)
13
14
 
14
15
  unless podFilePath
15
- puts "未找到相应的podspec文件"
16
+ UI.err("未找到相应的podspec文件")
16
17
  return
17
18
  end
18
19
 
@@ -27,7 +28,7 @@ module PodUpdater
27
28
 
28
29
  IO.popen(cmd.join('')) do |io|
29
30
  io.each do |line|
30
- puts line
31
+ UI.msg(line)
31
32
  end
32
33
  end
33
34
 
@@ -1,3 +1,3 @@
1
1
  module PodUpdater
2
- VERSION = "0.3.5"
2
+ VERSION = "0.3.6"
3
3
  end
data/lib/pod_updater.rb CHANGED
@@ -1,7 +1,10 @@
1
+
2
+ lib = File.expand_path("../lib", __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+
1
5
  require "pod_updater/version"
2
6
  require "pod_updater/pod_push"
3
7
 
4
-
5
8
  module PodUpdater
6
9
 
7
10
  def self.run(version)
@@ -9,5 +12,7 @@ module PodUpdater
9
12
  pushPodToSevice(path,version)
10
13
  end
11
14
 
15
+
12
16
  end
13
17
 
18
+ PodUpdater.run(1.0)
data/pod_updater.gemspec CHANGED
@@ -17,7 +17,7 @@ Gem::Specification.new do |spec|
17
17
  # Prevent pushing this gem to RubyGems.org. To allow pushes either set the 'allowed_push_host'
18
18
  # to allow pushing to a single host or delete this section to allow pushing to any host.
19
19
  if spec.respond_to?(:metadata)
20
- spec.metadata["allowed_push_host"] = "TODO: Set to 'http://mygemserver.com'"
20
+ # spec.metadata["allowed_push_host"] = "TODO: Set to 'http://mygemserver.com'"
21
21
  else
22
22
  raise "RubyGems 2.0 or newer is required to protect against " \
23
23
  "public gem pushes."
metadata CHANGED
@@ -1,41 +1,41 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pod_updater
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.5
4
+ version: 0.3.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - hwzss
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-12-15 00:00:00.000000000 Z
11
+ date: 2017-12-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ~>
17
+ - - "~>"
18
18
  - !ruby/object:Gem::Version
19
19
  version: '1.16'
20
20
  type: :development
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: '1.16'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rake
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - ~>
31
+ - - "~>"
32
32
  - !ruby/object:Gem::Version
33
33
  version: '10.0'
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: '10.0'
41
41
  description: iOS开发中帮助您快速的将自己的开发的pod库代码上传到git,并帮你push到podspec repo库去\n 使用方式:cd到你的pod库代码目录,然后执行'pod_updater
@@ -47,8 +47,8 @@ executables:
47
47
  extensions: []
48
48
  extra_rdoc_files: []
49
49
  files:
50
- - .DS_Store
51
- - .gitignore
50
+ - ".DS_Store"
51
+ - ".gitignore"
52
52
  - CODE_OF_CONDUCT.md
53
53
  - Gemfile
54
54
  - LICENSE.txt
@@ -68,25 +68,24 @@ files:
68
68
  homepage: https://github.com/hwzss/pod_updater
69
69
  licenses:
70
70
  - MIT
71
- metadata:
72
- allowed_push_host: 'TODO: Set to ''http://mygemserver.com'''
71
+ metadata: {}
73
72
  post_install_message:
74
73
  rdoc_options: []
75
74
  require_paths:
76
75
  - lib
77
76
  required_ruby_version: !ruby/object:Gem::Requirement
78
77
  requirements:
79
- - - '>='
78
+ - - ">="
80
79
  - !ruby/object:Gem::Version
81
80
  version: '0'
82
81
  required_rubygems_version: !ruby/object:Gem::Requirement
83
82
  requirements:
84
- - - '>='
83
+ - - ">="
85
84
  - !ruby/object:Gem::Version
86
85
  version: '0'
87
86
  requirements: []
88
87
  rubyforge_project:
89
- rubygems_version: 2.0.14.1
88
+ rubygems_version: 2.4.6
90
89
  signing_key:
91
90
  specification_version: 4
92
91
  summary: iOS开发中帮助您快速的将自己的开发的pod库代码上传到git,并帮你push到podspec repo库去