milestoner 0.4.0 → 0.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +2 -2
- data.tar.gz.sig +4 -2
- data/lib/milestoner.rb +1 -0
- data/lib/milestoner/aids/git.rb +4 -0
- data/lib/milestoner/cli.rb +5 -11
- data/lib/milestoner/identity.rb +1 -1
- data/lib/milestoner/publisher.rb +20 -0
- data/lib/milestoner/pusher.rb +1 -0
- data/lib/milestoner/tagger.rb +3 -1
- metadata +5 -4
- metadata.gz.sig +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6db913cce4d7f76264021448bd432d2567bdff6e
|
4
|
+
data.tar.gz: b898d30b6c7a9fbb4abae5faf8702cab53f4d829
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e3eb38029c7bb71f797fcbe218a5ad254d811739941a0efd92ea264a2cf040e871f25672949041b0d92beb447d1e3b4bc8233f39f37de1015673e74e9aa8abfc
|
7
|
+
data.tar.gz: 1b245772463afde2da6cd849961b51db56f14cd082b3cf3f4a2ea737d88d3f77725bbe83179646a72c62bd6501acaa357d8da1dd045b151241521abcfb9de974
|
checksums.yaml.gz.sig
CHANGED
@@ -1,2 +1,2 @@
|
|
1
|
-
|
2
|
-
|
1
|
+
S�f,N�HE��$#Eٲ,������Zay��T(���K�r$���&̝�1{�D6<�T�
|
2
|
+
����644�uj��/���e �1���_w�،�I� ���rrg,ý��S>j�����|�)T��)�%�������Y,��BE�~�h�}�<�i1��FL[�k�(�=��5N �N����S8��M�M���ɞ8��ì�H@2.��7�+ԤQ��f@�,0�
|
data.tar.gz.sig
CHANGED
@@ -1,2 +1,4 @@
|
|
1
|
-
|
2
|
-
Q
|
1
|
+
��,u0{\Ӎ
|
2
|
+
/�� �Q��� ��9k!Y
|
3
|
+
��J.\���|���:9I|Ք��Fw���1J{1)S�ֽb��fO�%����
|
4
|
+
+���w�J�~�u�(;f�|(1G���"gt���p��b����)�<=���/e���2���橉��=b�z�`��(�V�ʾw����_:���v-��N��`�!��^{E$�#��D��/͙I��$�^i�@�^��В�$̩Η��� ��=���^�
|
data/lib/milestoner.rb
CHANGED
data/lib/milestoner/aids/git.rb
CHANGED
data/lib/milestoner/cli.rb
CHANGED
@@ -17,6 +17,7 @@ module Milestoner
|
|
17
17
|
@tagger = Milestoner::Tagger.new configuration.settings[:version],
|
18
18
|
commit_prefixes: configuration.settings[:git_commit_prefixes]
|
19
19
|
@pusher = Milestoner::Pusher.new
|
20
|
+
@publisher = Milestoner::Publisher.new tagger, pusher
|
20
21
|
end
|
21
22
|
|
22
23
|
desc "-c, [--commits]", "Show commits for next milestone."
|
@@ -50,7 +51,9 @@ module Milestoner
|
|
50
51
|
map %w(-P --publish) => :publish
|
51
52
|
method_option :sign, aliases: "-s", desc: "Sign tag with GPG key.", type: :boolean, default: false
|
52
53
|
def publish version = configuration.settings[:version]
|
53
|
-
|
54
|
+
publisher.publish version, sign: sign_tag?(options[:sign])
|
55
|
+
info "Repository tagged and pushed: #{tagger.version_label}."
|
56
|
+
info "Milestone published!"
|
54
57
|
rescue Milestoner::Errors::Base => base_error
|
55
58
|
error base_error.message
|
56
59
|
end
|
@@ -76,7 +79,7 @@ module Milestoner
|
|
76
79
|
|
77
80
|
private
|
78
81
|
|
79
|
-
attr_reader :configuration, :tagger, :pusher
|
82
|
+
attr_reader :configuration, :tagger, :pusher, :publisher
|
80
83
|
|
81
84
|
def defaults
|
82
85
|
{
|
@@ -89,14 +92,5 @@ module Milestoner
|
|
89
92
|
def sign_tag? sign
|
90
93
|
sign | configuration.settings[:git_tag_sign]
|
91
94
|
end
|
92
|
-
|
93
|
-
def tag_and_push version, options
|
94
|
-
if tagger.create(version, sign: sign_tag?(options[:sign])) && pusher.push
|
95
|
-
info "Repository tagged and pushed: #{tagger.version_label}."
|
96
|
-
info "Milestone published!"
|
97
|
-
else
|
98
|
-
tagger.destroy
|
99
|
-
end
|
100
|
-
end
|
101
95
|
end
|
102
96
|
end
|
data/lib/milestoner/identity.rb
CHANGED
@@ -0,0 +1,20 @@
|
|
1
|
+
module Milestoner
|
2
|
+
# Handles the tagging and pushing of a milestone to a remote repository.
|
3
|
+
class Publisher
|
4
|
+
def initialize tagger, pusher
|
5
|
+
@tagger = tagger
|
6
|
+
@pusher = pusher
|
7
|
+
end
|
8
|
+
|
9
|
+
def publish version, sign: false
|
10
|
+
tagger.create version, sign: sign
|
11
|
+
pusher.push
|
12
|
+
ensure
|
13
|
+
tagger.destroy
|
14
|
+
end
|
15
|
+
|
16
|
+
private
|
17
|
+
|
18
|
+
attr_reader :tagger, :pusher
|
19
|
+
end
|
20
|
+
end
|
data/lib/milestoner/pusher.rb
CHANGED
data/lib/milestoner/tagger.rb
CHANGED
@@ -1,3 +1,5 @@
|
|
1
|
+
require "open3"
|
2
|
+
|
1
3
|
module Milestoner
|
2
4
|
# Handles the tagging of a project repository.
|
3
5
|
class Tagger
|
@@ -59,7 +61,7 @@ module Milestoner
|
|
59
61
|
|
60
62
|
def destroy
|
61
63
|
fail(Errors::Git) unless git_supported?
|
62
|
-
|
64
|
+
Open3.capture3 "git tag --delete #{version_label}" if duplicate?
|
63
65
|
end
|
64
66
|
|
65
67
|
private
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: milestoner
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.5.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brooke Kuhlmann
|
@@ -30,7 +30,7 @@ cert_chain:
|
|
30
30
|
aSif+qBc6oHD7EQWPF5cZkzkIURuwNwPBngZGxIKaMAgRhjGFXzUMAaq++r59cS9
|
31
31
|
xTfQ4k6fglKEgpnLAXiKdo2c8Ym+X4rIKFfedQ==
|
32
32
|
-----END CERTIFICATE-----
|
33
|
-
date: 2015-09-
|
33
|
+
date: 2015-09-17 00:00:00.000000000 Z
|
34
34
|
dependencies:
|
35
35
|
- !ruby/object:Gem::Dependency
|
36
36
|
name: thor
|
@@ -298,7 +298,7 @@ dependencies:
|
|
298
298
|
- - ">="
|
299
299
|
- !ruby/object:Gem::Version
|
300
300
|
version: '0'
|
301
|
-
description: A
|
301
|
+
description: A command line interface for releasing Git repository milestones.
|
302
302
|
email:
|
303
303
|
- brooke@alchemists.io
|
304
304
|
executables:
|
@@ -321,6 +321,7 @@ files:
|
|
321
321
|
- lib/milestoner/errors/git.rb
|
322
322
|
- lib/milestoner/errors/version.rb
|
323
323
|
- lib/milestoner/identity.rb
|
324
|
+
- lib/milestoner/publisher.rb
|
324
325
|
- lib/milestoner/pusher.rb
|
325
326
|
- lib/milestoner/tagger.rb
|
326
327
|
- lib/milestoner/tasks/rspec.rake
|
@@ -348,5 +349,5 @@ rubyforge_project:
|
|
348
349
|
rubygems_version: 2.4.8
|
349
350
|
signing_key:
|
350
351
|
specification_version: 4
|
351
|
-
summary: A
|
352
|
+
summary: A command line interface for releasing Git repository milestones.
|
352
353
|
test_files: []
|
metadata.gz.sig
CHANGED
@@ -1,2 +1,3 @@
|
|
1
|
-
|
2
|
-
|
1
|
+
��y�RN�K�k��@�j(R(�I�$�F�\iPyJ���PsH��+���p��ʫm�oT�0��_�����f�r[ڸ��3G��ـ��/D=-���ú���~�S���25u
|
2
|
+
Q���`JqX;���i���p{D�:�"
|
3
|
+
��y���^�f����<����_sR꒜U�@�@|i��ϛj=�����^и�$�Y�i;�Z�
|